mirror of
https://github.com/KhronosGroup/SPIRV-Tools
synced 2024-11-25 04:50:04 +00:00
Add dead function elimination to -O (#4015)
Fixes #4003 Both legalization and size formulae already run dead function elimination after inlining. This change does the same for performance passes.
This commit is contained in:
parent
c2b2b57885
commit
0c036df288
@ -161,6 +161,7 @@ Optimizer& Optimizer::RegisterPerformancePasses() {
|
||||
.RegisterPass(CreateDeadBranchElimPass())
|
||||
.RegisterPass(CreateMergeReturnPass())
|
||||
.RegisterPass(CreateInlineExhaustivePass())
|
||||
.RegisterPass(CreateEliminateDeadFunctionsPass())
|
||||
.RegisterPass(CreateAggressiveDCEPass())
|
||||
.RegisterPass(CreatePrivateToLocalPass())
|
||||
.RegisterPass(CreateLocalSingleBlockLoadStoreElimPass())
|
||||
|
@ -149,6 +149,7 @@ class TestPerformanceOptimizationPasses(expect.ValidObjectFile1_5,
|
||||
'eliminate-dead-branches',
|
||||
'merge-return',
|
||||
'inline-entry-points-exhaustive',
|
||||
'eliminate-dead-functions',
|
||||
'eliminate-dead-code-aggressive',
|
||||
'private-to-local',
|
||||
'eliminate-local-single-block',
|
||||
|
Loading…
Reference in New Issue
Block a user