Commit df5f65d
authored
[SPIR-V] Only emit __spirv__ when targeting HLSL (#142401)
OpenCL translator has a `__spirv` namespace, and defining the
`__spirv__` macro causes issues downstream on the OpenCL side. This
macro is needed to keep compatibility with HLSL/DXC, but can be avoided
for other targets/languages.1 parent 847e403 commit df5f65d
File tree
2 files changed
+5
-1
lines changed- clang
- lib/Basic/Targets
- test/Preprocessor
2 files changed
+5
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
87 | 87 | | |
88 | 88 | | |
89 | 89 | | |
90 | | - | |
| 90 | + | |
| 91 | + | |
91 | 92 | | |
92 | 93 | | |
93 | 94 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
228 | 228 | | |
229 | 229 | | |
230 | 230 | | |
| 231 | + | |
231 | 232 | | |
232 | 233 | | |
233 | 234 | | |
234 | 235 | | |
235 | 236 | | |
236 | 237 | | |
237 | 238 | | |
| 239 | + | |
238 | 240 | | |
239 | 241 | | |
240 | 242 | | |
| |||
245 | 247 | | |
246 | 248 | | |
247 | 249 | | |
| 250 | + | |
248 | 251 | | |
249 | 252 | | |
250 | 253 | | |
| |||
0 commit comments