From 97c46dd57c65ff596087c8b341926d1d2cbb6440 Mon Sep 17 00:00:00 2001 From: jsmall-nvidia Date: Fri, 9 Aug 2019 12:40:35 -0400 Subject: Fix TeamCity CI issues (#1013) * Added CPU_REFLECTION test option - that has two versions of the reflection output depending on ptr size. * Added 'shared-library' test category. This category is disabled on CI targets that have issues. --- tests/cpp-compiler/c-compile-shared-library.c | 2 +- tests/cpp-compiler/cpp-compile-shared-library.cpp | 4 +- tests/cross-compile/cpp-resource-reflection.slang | 2 +- .../cpp-resource-reflection.slang.32.expected | 163 +++++++++++++++++++++ .../cpp-resource-reflection.slang.64.expected | 163 +++++++++++++++++++++ .../cpp-resource-reflection.slang.expected | 163 --------------------- 6 files changed, 329 insertions(+), 168 deletions(-) create mode 100644 tests/cross-compile/cpp-resource-reflection.slang.32.expected create mode 100644 tests/cross-compile/cpp-resource-reflection.slang.64.expected delete mode 100644 tests/cross-compile/cpp-resource-reflection.slang.expected (limited to 'tests') diff --git a/tests/cpp-compiler/c-compile-shared-library.c b/tests/cpp-compiler/c-compile-shared-library.c index 8b6be6115..5ae61d65b 100644 --- a/tests/cpp-compiler/c-compile-shared-library.c +++ b/tests/cpp-compiler/c-compile-shared-library.c @@ -1,4 +1,4 @@ -//TEST(smoke):CPP_COMPILER_SHARED_LIBRARY: +//TEST(smoke,shared-library):CPP_COMPILER_SHARED_LIBRARY: #include #include diff --git a/tests/cpp-compiler/cpp-compile-shared-library.cpp b/tests/cpp-compiler/cpp-compile-shared-library.cpp index 8b70f258d..5341cd2fb 100644 --- a/tests/cpp-compiler/cpp-compile-shared-library.cpp +++ b/tests/cpp-compiler/cpp-compile-shared-library.cpp @@ -1,6 +1,4 @@ -//TEST(smoke):CPP_COMPILER_SHARED_LIBRARY: - -//#include +//TEST(smoke,shared-library):CPP_COMPILER_SHARED_LIBRARY: #include #include diff --git a/tests/cross-compile/cpp-resource-reflection.slang b/tests/cross-compile/cpp-resource-reflection.slang index 122e7b4de..52884fe03 100644 --- a/tests/cross-compile/cpp-resource-reflection.slang +++ b/tests/cross-compile/cpp-resource-reflection.slang @@ -1,4 +1,4 @@ -//TEST:REFLECTION: -profile cs_5_0 -entry computeMain -target cpp +//TEST:CPU_REFLECTION: -profile cs_5_0 -entry computeMain -target cpp struct Thing diff --git a/tests/cross-compile/cpp-resource-reflection.slang.32.expected b/tests/cross-compile/cpp-resource-reflection.slang.32.expected new file mode 100644 index 000000000..7f88c134e --- /dev/null +++ b/tests/cross-compile/cpp-resource-reflection.slang.32.expected @@ -0,0 +1,163 @@ +result code = 0 +standard error = { +} +standard output = { +{ + "parameters": [ + { + "name": "thing3", + "binding": {"kind": "uniform", "offset": 0, "size": 4}, + "type": { + "kind": "constantBuffer", + "elementType": { + "kind": "struct", + "name": "Thing", + "fields": [ + { + "name": "a", + "type": { + "kind": "scalar", + "scalarType": "int32" + }, + "binding": {"kind": "uniform", "offset": 0, "size": 4} + }, + { + "name": "b", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 4, "size": 4} + }, + { + "name": "c", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 8, "size": 4} + } + ] + } + } + }, + { + "name": "outputBuffer", + "binding": {"kind": "uniform", "offset": 4, "size": 8}, + "type": { + "kind": "resource", + "baseShape": "structuredBuffer", + "access": "readWrite", + "resultType": { + "kind": "scalar", + "scalarType": "int32" + } + } + }, + { + "name": "tex", + "binding": {"kind": "uniform", "offset": 12, "size": 4}, + "type": { + "kind": "resource", + "baseShape": "texture2D" + } + }, + { + "name": "sampler", + "binding": {"kind": "uniform", "offset": 16, "size": 4}, + "type": { + "kind": "samplerState" + } + } + ], + "entryPoints": [ + { + "name": "computeMain", + "stage:": "compute", + "parameters": [ + { + "name": "dispatchThreadID", + "semanticName": "SV_DISPATCHTHREADID", + "type": { + "kind": "vector", + "elementCount": 3, + "elementType": { + "kind": "scalar", + "scalarType": "uint32" + } + } + }, + { + "name": "thing", + "binding": {"kind": "uniform", "offset": 0, "size": 12}, + "type": { + "kind": "struct", + "name": "Thing", + "fields": [ + { + "name": "a", + "type": { + "kind": "scalar", + "scalarType": "int32" + }, + "binding": {"kind": "uniform", "offset": 0, "size": 4} + }, + { + "name": "b", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 4, "size": 4} + }, + { + "name": "c", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 8, "size": 4} + } + ] + } + }, + { + "name": "thing2", + "binding": {"kind": "uniform", "offset": 12, "size": 12}, + "type": { + "kind": "struct", + "name": "Thing", + "fields": [ + { + "name": "a", + "type": { + "kind": "scalar", + "scalarType": "int32" + }, + "binding": {"kind": "uniform", "offset": 0, "size": 4} + }, + { + "name": "b", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 4, "size": 4} + }, + { + "name": "c", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 8, "size": 4} + } + ] + } + } + ], + "threadGroupSize": [4, 1, 1] + } + ] +} +} diff --git a/tests/cross-compile/cpp-resource-reflection.slang.64.expected b/tests/cross-compile/cpp-resource-reflection.slang.64.expected new file mode 100644 index 000000000..a0e5241f0 --- /dev/null +++ b/tests/cross-compile/cpp-resource-reflection.slang.64.expected @@ -0,0 +1,163 @@ +result code = 0 +standard error = { +} +standard output = { +{ + "parameters": [ + { + "name": "thing3", + "binding": {"kind": "uniform", "offset": 0, "size": 8}, + "type": { + "kind": "constantBuffer", + "elementType": { + "kind": "struct", + "name": "Thing", + "fields": [ + { + "name": "a", + "type": { + "kind": "scalar", + "scalarType": "int32" + }, + "binding": {"kind": "uniform", "offset": 0, "size": 4} + }, + { + "name": "b", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 4, "size": 4} + }, + { + "name": "c", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 8, "size": 4} + } + ] + } + } + }, + { + "name": "outputBuffer", + "binding": {"kind": "uniform", "offset": 8, "size": 16}, + "type": { + "kind": "resource", + "baseShape": "structuredBuffer", + "access": "readWrite", + "resultType": { + "kind": "scalar", + "scalarType": "int32" + } + } + }, + { + "name": "tex", + "binding": {"kind": "uniform", "offset": 24, "size": 8}, + "type": { + "kind": "resource", + "baseShape": "texture2D" + } + }, + { + "name": "sampler", + "binding": {"kind": "uniform", "offset": 32, "size": 8}, + "type": { + "kind": "samplerState" + } + } + ], + "entryPoints": [ + { + "name": "computeMain", + "stage:": "compute", + "parameters": [ + { + "name": "dispatchThreadID", + "semanticName": "SV_DISPATCHTHREADID", + "type": { + "kind": "vector", + "elementCount": 3, + "elementType": { + "kind": "scalar", + "scalarType": "uint32" + } + } + }, + { + "name": "thing", + "binding": {"kind": "uniform", "offset": 0, "size": 12}, + "type": { + "kind": "struct", + "name": "Thing", + "fields": [ + { + "name": "a", + "type": { + "kind": "scalar", + "scalarType": "int32" + }, + "binding": {"kind": "uniform", "offset": 0, "size": 4} + }, + { + "name": "b", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 4, "size": 4} + }, + { + "name": "c", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 8, "size": 4} + } + ] + } + }, + { + "name": "thing2", + "binding": {"kind": "uniform", "offset": 12, "size": 12}, + "type": { + "kind": "struct", + "name": "Thing", + "fields": [ + { + "name": "a", + "type": { + "kind": "scalar", + "scalarType": "int32" + }, + "binding": {"kind": "uniform", "offset": 0, "size": 4} + }, + { + "name": "b", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 4, "size": 4} + }, + { + "name": "c", + "type": { + "kind": "scalar", + "scalarType": "float32" + }, + "binding": {"kind": "uniform", "offset": 8, "size": 4} + } + ] + } + } + ], + "threadGroupSize": [4, 1, 1] + } + ] +} +} diff --git a/tests/cross-compile/cpp-resource-reflection.slang.expected b/tests/cross-compile/cpp-resource-reflection.slang.expected deleted file mode 100644 index a0e5241f0..000000000 --- a/tests/cross-compile/cpp-resource-reflection.slang.expected +++ /dev/null @@ -1,163 +0,0 @@ -result code = 0 -standard error = { -} -standard output = { -{ - "parameters": [ - { - "name": "thing3", - "binding": {"kind": "uniform", "offset": 0, "size": 8}, - "type": { - "kind": "constantBuffer", - "elementType": { - "kind": "struct", - "name": "Thing", - "fields": [ - { - "name": "a", - "type": { - "kind": "scalar", - "scalarType": "int32" - }, - "binding": {"kind": "uniform", "offset": 0, "size": 4} - }, - { - "name": "b", - "type": { - "kind": "scalar", - "scalarType": "float32" - }, - "binding": {"kind": "uniform", "offset": 4, "size": 4} - }, - { - "name": "c", - "type": { - "kind": "scalar", - "scalarType": "float32" - }, - "binding": {"kind": "uniform", "offset": 8, "size": 4} - } - ] - } - } - }, - { - "name": "outputBuffer", - "binding": {"kind": "uniform", "offset": 8, "size": 16}, - "type": { - "kind": "resource", - "baseShape": "structuredBuffer", - "access": "readWrite", - "resultType": { - "kind": "scalar", - "scalarType": "int32" - } - } - }, - { - "name": "tex", - "binding": {"kind": "uniform", "offset": 24, "size": 8}, - "type": { - "kind": "resource", - "baseShape": "texture2D" - } - }, - { - "name": "sampler", - "binding": {"kind": "uniform", "offset": 32, "size": 8}, - "type": { - "kind": "samplerState" - } - } - ], - "entryPoints": [ - { - "name": "computeMain", - "stage:": "compute", - "parameters": [ - { - "name": "dispatchThreadID", - "semanticName": "SV_DISPATCHTHREADID", - "type": { - "kind": "vector", - "elementCount": 3, - "elementType": { - "kind": "scalar", - "scalarType": "uint32" - } - } - }, - { - "name": "thing", - "binding": {"kind": "uniform", "offset": 0, "size": 12}, - "type": { - "kind": "struct", - "name": "Thing", - "fields": [ - { - "name": "a", - "type": { - "kind": "scalar", - "scalarType": "int32" - }, - "binding": {"kind": "uniform", "offset": 0, "size": 4} - }, - { - "name": "b", - "type": { - "kind": "scalar", - "scalarType": "float32" - }, - "binding": {"kind": "uniform", "offset": 4, "size": 4} - }, - { - "name": "c", - "type": { - "kind": "scalar", - "scalarType": "float32" - }, - "binding": {"kind": "uniform", "offset": 8, "size": 4} - } - ] - } - }, - { - "name": "thing2", - "binding": {"kind": "uniform", "offset": 12, "size": 12}, - "type": { - "kind": "struct", - "name": "Thing", - "fields": [ - { - "name": "a", - "type": { - "kind": "scalar", - "scalarType": "int32" - }, - "binding": {"kind": "uniform", "offset": 0, "size": 4} - }, - { - "name": "b", - "type": { - "kind": "scalar", - "scalarType": "float32" - }, - "binding": {"kind": "uniform", "offset": 4, "size": 4} - }, - { - "name": "c", - "type": { - "kind": "scalar", - "scalarType": "float32" - }, - "binding": {"kind": "uniform", "offset": 8, "size": 4} - } - ] - } - } - ], - "threadGroupSize": [4, 1, 1] - } - ] -} -} -- cgit v1.2.3