mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-26 11:50:59 +00:00
DXIL Control Flow added a simple if/then test case
This commit is contained in:
@@ -358,6 +358,27 @@ TEST_CASE("DXIL Control Flow", "[dxil]")
|
||||
REQUIRE(outputs.contains(4U));
|
||||
}
|
||||
|
||||
{
|
||||
// Simple branch
|
||||
// 0 -> 1
|
||||
// 0 -> 2
|
||||
// 1 -> 2
|
||||
// 2 -> 3
|
||||
// 2 -> 4
|
||||
// 3 -> 4
|
||||
rdcarray<BlockLink> inputs;
|
||||
inputs.push_back({0, 1});
|
||||
inputs.push_back({0, 2});
|
||||
inputs.push_back({1, 2});
|
||||
inputs.push_back({2, 3});
|
||||
inputs.push_back({2, 4});
|
||||
inputs.push_back({3, 4});
|
||||
DXIL::FindUniformBlocks(inputs, outputs);
|
||||
REQUIRE(3 == outputs.count());
|
||||
REQUIRE(outputs.contains(0U));
|
||||
REQUIRE(outputs.contains(2U));
|
||||
REQUIRE(outputs.contains(4U));
|
||||
}
|
||||
{
|
||||
// Finite loop (3 -> 4 -> 5 -> 3)
|
||||
// 0 -> 1 -> 3
|
||||
|
||||
Reference in New Issue
Block a user