Skip to content

Commit 1a255cb

Browse files
committed
Merge branch 'ksimpson/cuda_core_linker_155' of https://github.com/NVIDIA/cuda-python into ksimpson/cuda_core_linker_155
2 parents a7f8c30 + 14b9c67 commit 1a255cb

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

cuda_core/tests/test_linker.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,24 +4,24 @@
44
from cuda.core.experimental._module import ObjectCode
55

66
ARCH = "sm_80" # use sm_80 for testing the oop nvJitLink wrapper
7-
empty_entrypoint_kernel = "__global__ void A() {}"
8-
empty_kernel = "__device__ void B() {}"
7+
empty_kernel = "__device__ void A() {}"
8+
basic_kernel = "__device__ int B() { return 0; }"
99
addition_kernel = "__device__ int C(int a, int b) { return a + b; }"
1010

1111

1212
@pytest.fixture(scope="function")
1313
def compile_ptx_functions(init_cuda):
14-
object_code_a_ptx = Program(empty_entrypoint_kernel, "c++").compile("ptx")
15-
object_code_b_ptx = Program(empty_kernel, "c++").compile("ptx")
14+
object_code_a_ptx = Program(empty_kernel, "c++").compile("ptx")
15+
object_code_b_ptx = Program(basic_kernel, "c++").compile("ptx")
1616
object_code_c_ptx = Program(addition_kernel, "c++").compile("ptx")
1717

1818
return object_code_a_ptx, object_code_b_ptx, object_code_c_ptx
1919

2020

2121
@pytest.fixture(scope="function")
2222
def compile_ltoir_functions(init_cuda):
23-
object_code_a_ltoir = Program(empty_entrypoint_kernel, "c++").compile("ltoir", options=("-dlto",))
24-
object_code_b_ltoir = Program(empty_kernel, "c++").compile("ltoir", options=("-dlto",))
23+
object_code_a_ltoir = Program(empty_kernel, "c++").compile("ltoir", options=("-dlto",))
24+
object_code_b_ltoir = Program(basic_kernel, "c++").compile("ltoir", options=("-dlto",))
2525
object_code_c_ltoir = Program(addition_kernel, "c++").compile("ltoir", options=("-dlto",))
2626

2727
return object_code_a_ltoir, object_code_b_ltoir, object_code_c_ltoir

0 commit comments

Comments
 (0)