[PATCH] D118607: [InstCombine] Remove weaker fence adjacent to a stronger fence
Roman Lebedev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 31 08:26:11 PST 2022
lebedev.ri added inline comments.
================
Comment at: llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp:2471-2472
Instruction *InstCombinerImpl::visitFenceInst(FenceInst &FI) {
- // Remove identical consecutive fences.
Instruction *Next = FI.getNextNonDebugInstruction();
- if (auto *NFI = dyn_cast<FenceInst>(Next))
- if (FI.isIdenticalTo(NFI))
+ if (auto *NFI = dyn_cast<FenceInst>(Next)) {
+ // Remove identical consecutive fences.
----------------
Would it go past 80col if `Next` is inlined?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D118607/new/
https://reviews.llvm.org/D118607
More information about the llvm-commits
mailing list