@@ -248,49 +248,49 @@ generateDXContainer(StringRef Yaml, SmallVectorImpl<char> &BinaryData) {
248248
249249TEST (DXCFile, PSVResourceIterators) {
250250 const char *Yaml = R"(
251- --- !dxcontainer
252- Header:
253- Hash: [ 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
254- 0x0, 0x0, 0x0, 0x0, 0x0, 0x0 ]
255- Version:
256- Major: 1
257- Minor: 0
258- PartCount: 2
259- Parts:
260- - Name: PSV0
261- Size: 144
262- PSVInfo:
263- Version: 0
264- ShaderStage: 14
265- PayloadSizeInBytes: 4092
266- MinimumWaveLaneCount: 0
267- MaximumWaveLaneCount: 4294967295
268- ResourceStride: 16
269- Resources:
270- - Type: Sampler
271- Space: 1
272- LowerBound: 1
273- UpperBound: 1
274- - Type: CBV
275- Space: 2
276- LowerBound: 2
277- UpperBound: 2
278- - Type: SRVTyped
279- Space: 3
280- LowerBound: 3
281- UpperBound: 3
282- - Name: DXIL
283- Size: 24
284- Program:
285- MajorVersion: 6
286- MinorVersion: 0
287- ShaderKind: 14
288- Size: 6
289- DXILMajorVersion: 1
290- DXILMinorVersion: 0
291- DXILSize: 0
292- ...
293- )" ;
251+ --- !dxcontainer
252+ Header:
253+ Hash: [ 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
254+ 0x0, 0x0, 0x0, 0x0, 0x0, 0x0 ]
255+ Version:
256+ Major: 1
257+ Minor: 0
258+ PartCount: 2
259+ Parts:
260+ - Name: PSV0
261+ Size: 144
262+ PSVInfo:
263+ Version: 0
264+ ShaderStage: 14
265+ PayloadSizeInBytes: 4092
266+ MinimumWaveLaneCount: 0
267+ MaximumWaveLaneCount: 4294967295
268+ ResourceStride: 16
269+ Resources:
270+ - Type: Sampler
271+ Space: 1
272+ LowerBound: 1
273+ UpperBound: 1
274+ - Type: CBV
275+ Space: 2
276+ LowerBound: 2
277+ UpperBound: 2
278+ - Type: SRVTyped
279+ Space: 3
280+ LowerBound: 3
281+ UpperBound: 3
282+ - Name: DXIL
283+ Size: 24
284+ Program:
285+ MajorVersion: 6
286+ MinorVersion: 0
287+ ShaderKind: 14
288+ Size: 6
289+ DXILMajorVersion: 1
290+ DXILMinorVersion: 0
291+ DXILSize: 0
292+ ...
293+ )" ;
294294
295295 SmallVector<char , 256 > BinaryData;
296296 auto C = generateDXContainer (Yaml, BinaryData);
@@ -560,20 +560,23 @@ TEST(DXCFile, MaliciousFiles) {
560560// ...
561561TEST (DXCFile, PSVResourceIteratorsStride) {
562562 uint8_t Buffer[] = {
563- 0x44 , 0x58 , 0x42 , 0x43 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
564- 0x00 , 0x00 , 0x00 , 0x00 , 0x01 , 0x00 , 0x00 , 0x00 , 0xB0 , 0x00 , 0x00 , 0x00 , 0x02 , 0x00 , 0x00 , 0x00 ,
565- 0x28 , 0x00 , 0x00 , 0x00 , 0x48 , 0x00 , 0x00 , 0x00 , 0x44 , 0x58 , 0x49 , 0x4C , 0x18 , 0x00 , 0x00 , 0x00 ,
566- 0x60 , 0x00 , 0x0E , 0x00 , 0x06 , 0x00 , 0x00 , 0x00 , 0x44 , 0x58 , 0x49 , 0x4C , 0x00 , 0x01 , 0x00 , 0x00 ,
567- 0x10 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x50 , 0x53 , 0x56 , 0x30 , 0x64 , 0x00 , 0x00 , 0x00 ,
568- 0x18 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
569- 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x02 , 0x00 , 0x00 , 0x00 ,
570- 0x20 , 0x00 , 0x00 , 0x00 , 0x01 , 0x00 , 0x00 , 0x00 , 0x02 , 0x00 , 0x00 , 0x00 , 0x03 , 0x00 , 0x00 , 0x00 ,
571- 0x04 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
572- 0x00 , 0x00 , 0x00 , 0x00 , 0x05 , 0x00 , 0x00 , 0x00 , 0x06 , 0x00 , 0x00 , 0x00 , 0x07 , 0x00 , 0x00 , 0x00 ,
573- 0x08 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
574- 0x00 , 0x00 , 0x00 , 0x00 ,
575- };
576- DXContainer C =
563+ 0x44 , 0x58 , 0x42 , 0x43 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
564+ 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x01 , 0x00 , 0x00 , 0x00 ,
565+ 0xB0 , 0x00 , 0x00 , 0x00 , 0x02 , 0x00 , 0x00 , 0x00 , 0x28 , 0x00 , 0x00 , 0x00 ,
566+ 0x48 , 0x00 , 0x00 , 0x00 , 0x44 , 0x58 , 0x49 , 0x4C , 0x18 , 0x00 , 0x00 , 0x00 ,
567+ 0x60 , 0x00 , 0x0E , 0x00 , 0x06 , 0x00 , 0x00 , 0x00 , 0x44 , 0x58 , 0x49 , 0x4C ,
568+ 0x00 , 0x01 , 0x00 , 0x00 , 0x10 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
569+ 0x50 , 0x53 , 0x56 , 0x30 , 0x64 , 0x00 , 0x00 , 0x00 , 0x18 , 0x00 , 0x00 , 0x00 ,
570+ 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
571+ 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
572+ 0x02 , 0x00 , 0x00 , 0x00 , 0x20 , 0x00 , 0x00 , 0x00 , 0x01 , 0x00 , 0x00 , 0x00 ,
573+ 0x02 , 0x00 , 0x00 , 0x00 , 0x03 , 0x00 , 0x00 , 0x00 , 0x04 , 0x00 , 0x00 , 0x00 ,
574+ 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
575+ 0x00 , 0x00 , 0x00 , 0x00 , 0x05 , 0x00 , 0x00 , 0x00 , 0x06 , 0x00 , 0x00 , 0x00 ,
576+ 0x07 , 0x00 , 0x00 , 0x00 , 0x08 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
577+ 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 , 0x00 ,
578+ };
579+ DXContainer C =
577580 llvm::cantFail (DXContainer::create (getMemoryBuffer<180 >(Buffer)));
578581
579582 const auto &PSVInfo = C.getPSVInfo ();
@@ -625,8 +628,8 @@ TEST(DXCFile, PSVResourceIteratorsStride) {
625628 EXPECT_EQ (Binding.Type , dxbc::PSV::ResourceType::SRVStructured);
626629 EXPECT_EQ (Binding.Space , 6u );
627630 EXPECT_EQ (Binding.LowerBound , 7u );
628- EXPECT_EQ (Binding.UpperBound , 8u );;
629-
631+ EXPECT_EQ (Binding.UpperBound , 8u );
632+ ;
630633
631634 EXPECT_FALSE (It == PSVInfo->getResources ().end ());
632635
@@ -1086,8 +1089,7 @@ TEST(RootSignature, ParseDescriptorTable) {
10861089 ASSERT_THAT_ERROR (ParamView.takeError (), Succeeded ());
10871090
10881091 auto *DescriptorTableView =
1089- dyn_cast<DirectX::DescriptorTableView>(
1090- &*ParamView);
1092+ dyn_cast<DirectX::DescriptorTableView>(&*ParamView);
10911093 ASSERT_TRUE (DescriptorTableView != nullptr );
10921094 auto Table = DescriptorTableView->read (2 );
10931095
@@ -1139,8 +1141,7 @@ TEST(RootSignature, ParseDescriptorTable) {
11391141 ASSERT_THAT_ERROR (ParamView.takeError (), Succeeded ());
11401142
11411143 auto *DescriptorTableView =
1142- dyn_cast<DirectX::DescriptorTableView>(
1143- &*ParamView);
1144+ dyn_cast<DirectX::DescriptorTableView>(&*ParamView);
11441145 ASSERT_TRUE (DescriptorTableView != nullptr );
11451146 auto Table = DescriptorTableView->read (1 );
11461147
0 commit comments