Skip to content

Commit 1d2d0cf

Browse files
fftzengigcbot
authored andcommitted
update llvm stats after all the optimzations for cos dumping
update llvm stats after all the optimizations for cos dumping
1 parent b5a7610 commit 1d2d0cf

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

IGC/Compiler/CISACodeGen/ShaderCodeGen.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -357,6 +357,9 @@ static void AddAnalysisPasses(CodeGenContext& ctx, IGCPassManager& mpm)
357357
}
358358
mpm.add(createFixInvalidFuncNamePass());
359359

360+
// collect stats after all the optimization. This info can be dumped to the cos file
361+
mpm.add(new CheckInstrTypes(&(ctx.m_instrTypesAfterOpts), nullptr));
362+
360363
//
361364
// Generally, passes that change IR should be prior to this place!
362365
//

IGC/Compiler/CodeGenPublic.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1067,6 +1067,7 @@ namespace IGC
10671067
PushConstantMode m_pushConstantMode = PushConstantMode::DEFAULT;
10681068

10691069
SInstrTypes m_instrTypes;
1070+
SInstrTypes m_instrTypesAfterOpts;
10701071

10711072
///// used for instruction statistic before/after pass
10721073
int instrStat[TOTAL_TYPES][TOTAL_STAGE];

0 commit comments

Comments
 (0)