summaryrefslogtreecommitdiff
path: root/tests/ir
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2023-11-14 17:46:05 -0800
committerGitHub <noreply@github.com>2023-11-14 17:46:05 -0800
commit12f7237e4060388494c549623f4a640327b7ca08 (patch)
tree407c0f8d20b4ccd49ae5df57f84c8f9a310f7055 /tests/ir
parentc71b12775c8b13ea2b181e42c04b8db55b10fb2f (diff)
Add GLSL Compatibility. (#3321)
* Parse glsl buffer blocks to GLSLInterfaceBlockDecl * Parse glsl local size layout declarations * Parse (and ignore) glsl version directives * spelling * Better l-value interpretation for glsl interface blocks * Better l-value interpretation for glsl interface blocks * Add compile flag for enabling glsl * Parse and ignore precision modifiers. * Automatically import `glsl` module for compatiblity. * Complete vector and matrix types for glsl * Remove generated file from repo * Bump .gitignore * do not mark out globals as params * Synthesize entrypoint layout from global inout vars. * update test result. * Allow HLSL semantic on global variables. * Fix. * Fix test. * Fix win32 compile error. * Add more builtin input/output and texture intrinsics. * Add struct/array constructor syntax. * Skip `#extension` lines. * overide operator * for matrix/vector multiplication. * Add `matrixCompMult`. * Parse modifiers in for loop init var declr. * Add more glsl intrinsics, add stage into to var layout. * Allow `int[3] x` syntax. * Fix array type syntax. --------- Co-authored-by: Ellie Hermaszewska <ellieh@nvidia.com> Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'tests/ir')
-rw-r--r--tests/ir/string-literal.slang3
-rw-r--r--tests/ir/string-literal.slang.expected20
2 files changed, 2 insertions, 21 deletions
diff --git a/tests/ir/string-literal.slang b/tests/ir/string-literal.slang
index 224d64b7a..be05f6a8d 100644
--- a/tests/ir/string-literal.slang
+++ b/tests/ir/string-literal.slang
@@ -1,5 +1,6 @@
-//TEST(compute):SIMPLE:-dump-ir -stage compute -entry main
+//TEST(compute):SIMPLE(filecheck=CHECK):-dump-ir -stage compute -entry main
+// CHECK: global_hashed_string_literals("Hello \t\n\0x083 World")
[numthreads(1, 1, 1)]
void main(
uint tid : SV_DispatchThreadIndex)
diff --git a/tests/ir/string-literal.slang.expected b/tests/ir/string-literal.slang.expected
deleted file mode 100644
index 6f414b0da..000000000
--- a/tests/ir/string-literal.slang.expected
+++ /dev/null
@@ -1,20 +0,0 @@
-result code = 0
-standard error = {
-### LOWER-TO-IR:
-undefined
-[entryPoint(6 : Int, "main", "string-literal")]
-[numThreads(1 : Int, 1 : Int, 1 : Int)]
-[export("_S3tu04mainp1puV")]
-[nameHint("main")]
-func %main : Func(Void, UInt)
-{
-block %1(
- [nameHint("tid")]
- param %tid : UInt):
- return_val(void_constant)
-}
-global_hashed_string_literals("Hello \t\n\0x083 World")
-###
-}
-standard output = {
-}