add device name to device, all are constructed (#3221)

This commit is contained in:
George Hotz
2024-01-23 20:34:56 -08:00
committed by GitHub
parent 91a1b2bd7a
commit 23b084e70a
10 changed files with 22 additions and 21 deletions

View File

@@ -83,7 +83,7 @@ class CUDADevice(Compiled):
self.arch = f"sm_{major.value}{minor.value}" if not CUDACPU else "sm_35"
from tinygrad.runtime.graph.cuda import CUDAGraph
super().__init__(CUDAAllocator(self) if not CUDACPU else MallocAllocator,
super().__init__(device, CUDAAllocator(self) if not CUDACPU else MallocAllocator,
LinearizerOptions("CUDA", supports_float4_alu=False, global_max=[65535, 65535, 2147483647], local_max=[64, 1024, 1024]),
CUDARenderer, functools.partial(compile_cuda,arch=self.arch), f"compile_cuda_{self.arch}", functools.partial(CUDAProgram, self),
graph=CUDAGraph if not CUDACPU else None)