Commit d6d26db
committed
[Sema] Requires nointerpolation on GetAttributeAtVertex param #0
This commit adds new sema checks to restrict the scope of the feature:
the `nointerpolation` attribute is now required on all parameters used
in GetAttributeAtVertex, and doesn't propagage magically to parent/child
functions.
Those issues are mostly caused by the feature which is badly designed
at the language/spec level. The SPIR-V side crashes during validation,
which is a bit unfortunate as the error message is not trivial to
understand. For this reason, I moved some restriction further up.
As for DXIL, we leave it unchanged, as DXIL validation will catch those
cases with a good-enough error message.
The current accepted cases this now blocks were mostly broken later in the
codegen, so this should be an acceptable 'regression'.
Related to #6384, #6220
Fixed #6383, #6382
Signed-off-by: Nathan Gauër <[email protected]>1 parent 8de82c9 commit d6d26db
File tree
13 files changed
+208
-8
lines changed- tools/clang
- include/clang
- Basic
- Sema
- lib/Sema
- test
- CodeGenSPIRV
- SemaHLSL
13 files changed
+208
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7732 | 7732 | | |
7733 | 7733 | | |
7734 | 7734 | | |
| 7735 | + | |
| 7736 | + | |
7735 | 7737 | | |
7736 | 7738 | | |
7737 | 7739 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8828 | 8828 | | |
8829 | 8829 | | |
8830 | 8830 | | |
| 8831 | + | |
| 8832 | + | |
8831 | 8833 | | |
8832 | 8834 | | |
8833 | 8835 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
522 | 522 | | |
523 | 523 | | |
524 | 524 | | |
525 | | - | |
526 | 525 | | |
527 | 526 | | |
528 | 527 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5288 | 5288 | | |
5289 | 5289 | | |
5290 | 5290 | | |
5291 | | - | |
| 5291 | + | |
| 5292 | + | |
| 5293 | + | |
| 5294 | + | |
5292 | 5295 | | |
5293 | 5296 | | |
5294 | 5297 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15176 | 15176 | | |
15177 | 15177 | | |
15178 | 15178 | | |
| 15179 | + | |
| 15180 | + | |
| 15181 | + | |
| 15182 | + | |
| 15183 | + | |
| 15184 | + | |
| 15185 | + | |
| 15186 | + | |
| 15187 | + | |
| 15188 | + | |
| 15189 | + | |
| 15190 | + | |
| 15191 | + | |
| 15192 | + | |
| 15193 | + | |
| 15194 | + | |
| 15195 | + | |
| 15196 | + | |
| 15197 | + | |
| 15198 | + | |
| 15199 | + | |
| 15200 | + | |
| 15201 | + | |
| 15202 | + | |
| 15203 | + | |
| 15204 | + | |
| 15205 | + | |
| 15206 | + | |
| 15207 | + | |
| 15208 | + | |
| 15209 | + | |
| 15210 | + | |
| 15211 | + | |
| 15212 | + | |
| 15213 | + | |
| 15214 | + | |
| 15215 | + | |
| 15216 | + | |
| 15217 | + | |
| 15218 | + | |
| 15219 | + | |
| 15220 | + | |
| 15221 | + | |
| 15222 | + | |
| 15223 | + | |
| 15224 | + | |
| 15225 | + | |
| 15226 | + | |
| 15227 | + | |
| 15228 | + | |
| 15229 | + | |
| 15230 | + | |
| 15231 | + | |
| 15232 | + | |
| 15233 | + | |
| 15234 | + | |
| 15235 | + | |
| 15236 | + | |
| 15237 | + | |
| 15238 | + | |
| 15239 | + | |
| 15240 | + | |
| 15241 | + | |
| 15242 | + | |
| 15243 | + | |
| 15244 | + | |
| 15245 | + | |
| 15246 | + | |
| 15247 | + | |
| 15248 | + | |
| 15249 | + | |
| 15250 | + | |
| 15251 | + | |
| 15252 | + | |
| 15253 | + | |
| 15254 | + | |
| 15255 | + | |
15179 | 15256 | | |
15180 | 15257 | | |
15181 | 15258 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| |||
Lines changed: 6 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
14 | 17 | | |
15 | | - | |
16 | | - | |
| |||
Lines changed: 41 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
Lines changed: 16 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
Lines changed: 12 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
0 commit comments