Commit 503bfac
committed
cuda.core: simplify runtime error naming path
`_check_error()` only routes `runtime.cudaError_t` instances into
`_check_runtime_error()`, so consulting `cudaGetErrorName()` and keeping a
fallback for unknown values does not improve the normal `cuda.core` path. The
Windows hybrid cudart issue is that the runtime name table can lag the
generated enum table, so using `error.name` directly is both simpler and a
better match for the values the code already has.
With the runtime path now relying on enum members, the runtime-side tests no
longer need to account for `UNEXPECTED ERROR CODE` in this loop or keep a
separate monkeypatch test for avoiding the runtime name lookup.
Made-with: Cursor1 parent 82c35fd commit 503bfac
2 files changed
Lines changed: 4 additions & 38 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
149 | 149 | | |
150 | 150 | | |
151 | 151 | | |
152 | | - | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | 152 | | |
160 | 153 | | |
161 | 154 | | |
| |||
178 | 171 | | |
179 | 172 | | |
180 | 173 | | |
181 | | - | |
182 | | - | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | | - | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
187 | 177 | | |
188 | 178 | | |
189 | 179 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
52 | 51 | | |
53 | 52 | | |
54 | 53 | | |
55 | 54 | | |
56 | 55 | | |
57 | 56 | | |
58 | 57 | | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
| 58 | + | |
67 | 59 | | |
68 | 60 | | |
69 | 61 | | |
| |||
179 | 171 | | |
180 | 172 | | |
181 | 173 | | |
182 | | - | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | | - | |
187 | | - | |
188 | | - | |
189 | | - | |
190 | | - | |
191 | | - | |
192 | | - | |
193 | | - | |
194 | | - | |
195 | | - | |
196 | | - | |
197 | | - | |
198 | 174 | | |
199 | 175 | | |
200 | 176 | | |
| |||
0 commit comments