Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
d7f58ed
CUDA Dispatcher: inherit from _DispatcherBase
gmarkall Feb 4, 2022
31c1a64
[WIP] Fix CUDA target tests
gmarkall Feb 4, 2022
d9649f8
Some tidy-up
gmarkall Feb 4, 2022
70dbacd
[WIP] CUDA Dispatcher inherits from uber_Dispatcher
gmarkall Feb 4, 2022
922624f
Wire in target options in CUDA dispatcher
gmarkall Feb 4, 2022
ed2e17a
Delete some dead code
gmarkall Feb 4, 2022
8238610
Remove sigs from cuda dispatcher
gmarkall Feb 4, 2022
53e98fb
Some refactoring
gmarkall Feb 4, 2022
e307e9a
Some renaming to closer align ForAll with reality
gmarkall Feb 4, 2022
703d222
Delete _search_new_conversions and nopython_signatures from CUDA disp…
gmarkall Feb 4, 2022
13aa50b
Remove CUDA Dispatchers disable_compile and add a note to get_call_te…
gmarkall Feb 4, 2022
a11269e
Clarify comment on CUDA Compile Result
gmarkall Feb 4, 2022
18c553f
Remove duplication in compile_result functions
gmarkall Feb 4, 2022
3ebcf26
Refactor / tidy up decorators.py
gmarkall Feb 4, 2022
4f5b361
Rename CUDA dispatcher to CUDADispatcher
gmarkall Feb 4, 2022
078f2d9
Clarify some comments
gmarkall Feb 4, 2022
778f7e2
Fix ref to CUDADispatcher in docs
gmarkall Feb 4, 2022
5d6384c
CUDA Dispatcher: use default finalizer
gmarkall Feb 4, 2022
4d9cff7
Add test for Issue #5902
gmarkall Feb 4, 2022
c136220
Merge remote-tracking branch 'numba/main' into cuda-dispatcher-base-2…
gmarkall Feb 8, 2022
ef5b4dc
Fix typos (PR #7815 review)
gmarkall Feb 11, 2022
499623f
Fix line length in cuda/compiler.py
gmarkall Feb 11, 2022
17f9585
Merge remote-tracking branch 'numba/main' into cuda-dispatcher-base-2…
gmarkall Feb 17, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Delete _search_new_conversions and nopython_signatures from CUDA disp…
…atcher
  • Loading branch information
gmarkall committed Feb 4, 2022
commit 703d22255ebc9a15ba5e79b9819bd66da67b6481
20 changes: 4 additions & 16 deletions numba/cuda/dispatcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ def __init__(self, py_func, argtypes, link=None, debug=False,

super().__init__()

# Emulate a CompileResult so that _DispatcherBase.nopython_signatures
# can be used as-is
self.objectmode = False

self.py_func = py_func
self.argtypes = argtypes
self.debug = debug
Expand Down Expand Up @@ -559,17 +563,6 @@ def _compile_for_args(self, *args, **kws):
argtypes = [self.typeof_pyval(a) for a in args]
return self.compile(tuple(argtypes))

def _search_new_conversions(self, *args, **kws):
# Based on _DispatcherBase._search_new_conversions
assert not kws
args = [self.typeof_pyval(a) for a in args]
found = False
for sig in self.nopython_signatures:
conv = self.typingctx.install_possible_conversions(args, sig.args)
if conv:
found = True
return found

def typeof_pyval(self, val):
# Based on _DispatcherBase.typeof_pyval, but differs from it to support
# the CUDA Array Interface.
Expand All @@ -584,11 +577,6 @@ def typeof_pyval(self, val):
else:
raise

@property
def nopython_signatures(self):
# Based on _DispatcherBase.nopython_signatures
return [kernel.signature for kernel in self.overloads.values()]

def specialize(self, *args):
'''
Create a new instance of this dispatcher specialized for the given
Expand Down