mirror of
https://github.com/KhronosGroup/SPIRV-Tools
synced 2024-11-26 21:30:07 +00:00
Add DISABLED failing test for ext inst import confusion
Currently, the assembler does not track external import IDs when there are two or more. TODO(dneto): Fix this functionality.
This commit is contained in:
parent
b6a43383e7
commit
e5e99b57cc
@ -34,6 +34,7 @@ namespace {
|
||||
using spvtest::Concatenate;
|
||||
using spvtest::MakeInstruction;
|
||||
using spvtest::MakeVector;
|
||||
using spvtest::TextToBinaryTest;
|
||||
using testing::Eq;
|
||||
|
||||
struct InstructionCase {
|
||||
@ -382,4 +383,26 @@ INSTANTIATE_TEST_CASE_P(
|
||||
#undef CASE2Lit
|
||||
#undef CASE3Round
|
||||
|
||||
// TODO(dneto): Fix this functionality.
|
||||
TEST_F(TextToBinaryTest, DISABLED_ExtInstFromTwoDifferentImports) {
|
||||
const std::string input =
|
||||
R"(%1 = OpExtInstImport "OpenCL.std"
|
||||
%2 = OpExtInstImport "GLSL.std.450"
|
||||
%4 = OpExtInst %3 %1 native_sqrt %5
|
||||
%7 = OpExtInst %6 %2 MatrixInverse %8
|
||||
)";
|
||||
EXPECT_THAT(
|
||||
CompiledInstructions(input),
|
||||
Eq(Concatenate({
|
||||
MakeInstruction(spv::OpExtInstImport, {1}, MakeVector("OpenCL.std")),
|
||||
MakeInstruction(spv::OpExtInstImport, {2},
|
||||
MakeVector("GLSL.std.450")),
|
||||
MakeInstruction(
|
||||
spv::OpExtInst,
|
||||
{3, 4, 1, uint32_t(OpenCLLIB::Entrypoints::Native_sqrt), 5}),
|
||||
MakeInstruction(spv::OpExtInst,
|
||||
{6, 7, 2, uint32_t(GLSLstd450MatrixInverse), 8}),
|
||||
})));
|
||||
}
|
||||
|
||||
} // anonymous namespace
|
||||
|
Loading…
Reference in New Issue
Block a user