Commit 1d5bd28
authored
[Matrix][Clang][HLSL] Move MaxMatrixDimension to a LangOpt (#163307)
fixes #160190
fixes #116710
This change just makes MaxMatrixDimension configurable by language mode.
It was previously introduced in
94b4311
when there was not a need to make dimensions configurable.
Current testing to this effect exists in:
- clang/test/Sema/matrix-type-builtins.c
- clang/test/SemaCXX/matrix-type-builtins.cpp
- clang/test/SemaHLSL/BuiltIns/matrix-basic_types-errors.hlsl
New Tests to confirm configurability by language mode:
- clang/unittests/Frontend/CompilerInvocationTest.cpp
I considered adding a driver flag to
`clang/include/clang/Driver/Options.td` but HLSL matrix max dim is
always 4 so we don't need this configurable beyond that size for our use
case.1 parent 22a2a82 commit 1d5bd28
File tree
10 files changed
+65
-21
lines changed- clang
- include/clang
- AST
- Basic
- lib
- AST
- Basic
- Sema
- test
- SemaCXX
- SemaHLSL/BuiltIns
- unittests/Frontend
10 files changed
+65
-21
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4378 | 4378 | | |
4379 | 4379 | | |
4380 | 4380 | | |
4381 | | - | |
4382 | | - | |
4383 | 4381 | | |
4384 | 4382 | | |
4385 | 4383 | | |
| |||
4398 | 4396 | | |
4399 | 4397 | | |
4400 | 4398 | | |
4401 | | - | |
4402 | | - | |
4403 | | - | |
4404 | | - | |
4405 | | - | |
4406 | | - | |
4407 | | - | |
4408 | | - | |
4409 | | - | |
4410 | | - | |
4411 | 4399 | | |
4412 | 4400 | | |
4413 | 4401 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
433 | 433 | | |
434 | 434 | | |
435 | 435 | | |
| 436 | + | |
436 | 437 | | |
437 | 438 | | |
438 | 439 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4712 | 4712 | | |
4713 | 4713 | | |
4714 | 4714 | | |
4715 | | - | |
4716 | | - | |
| 4715 | + | |
| 4716 | + | |
4717 | 4717 | | |
4718 | 4718 | | |
4719 | 4719 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
132 | 132 | | |
133 | 133 | | |
134 | 134 | | |
135 | | - | |
136 | | - | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
137 | 141 | | |
138 | 142 | | |
139 | 143 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
159 | 159 | | |
160 | 160 | | |
161 | 161 | | |
162 | | - | |
| 162 | + | |
| 163 | + | |
163 | 164 | | |
164 | 165 | | |
165 | 166 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16239 | 16239 | | |
16240 | 16240 | | |
16241 | 16241 | | |
16242 | | - | |
| 16242 | + | |
16243 | 16243 | | |
16244 | | - | |
| 16244 | + | |
16245 | 16245 | | |
16246 | 16246 | | |
16247 | 16247 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2517 | 2517 | | |
2518 | 2518 | | |
2519 | 2519 | | |
2520 | | - | |
| 2520 | + | |
| 2521 | + | |
| 2522 | + | |
| 2523 | + | |
| 2524 | + | |
| 2525 | + | |
| 2526 | + | |
2521 | 2527 | | |
2522 | 2528 | | |
2523 | 2529 | | |
2524 | 2530 | | |
2525 | | - | |
| 2531 | + | |
2526 | 2532 | | |
2527 | 2533 | | |
2528 | 2534 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
17 | 18 | | |
18 | 19 | | |
19 | 20 | | |
| |||
Lines changed: 23 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
732 | 732 | | |
733 | 733 | | |
734 | 734 | | |
| 735 | + | |
| 736 | + | |
| 737 | + | |
| 738 | + | |
| 739 | + | |
| 740 | + | |
| 741 | + | |
| 742 | + | |
| 743 | + | |
| 744 | + | |
| 745 | + | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
| 749 | + | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
| 753 | + | |
| 754 | + | |
735 | 755 | | |
736 | 756 | | |
737 | 757 | | |
| |||
0 commit comments