[PATCH] D116819: [AMDGPU] Disable optimizeEndCf at -O0
Stanislav Mekhanoshin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 7 11:34:58 PST 2022
rampitec added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/SILowerControlFlow.cpp:813
TRI = &TII->getRegisterInfo();
+ EnableOptimizeEndCf =
+ RemoveRedundantEndcf && MF.getTarget().getOptLevel() > CodeGenOpt::None;
----------------
You can just check it where optimizeEndCf is called below.
================
Comment at: llvm/lib/Target/AMDGPU/SILowerControlFlow.cpp:814
+ EnableOptimizeEndCf =
+ RemoveRedundantEndcf && MF.getTarget().getOptLevel() > CodeGenOpt::None;
----------------
There is skipFunction() method, it will check optnone attribute. Just checking -O0 does not check this.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D116819/new/
https://reviews.llvm.org/D116819
More information about the llvm-commits
mailing list