Optimize the size of epilogue sequences by replacing common cases with a single branch to __mspabi_func_epilog_<N> function described in MSP430 EABI document, part 3.8.
As part of that, the patch adjust handling of MSP430::Bi instruction.
Paths
| Differential D84397
[MSP430] Replace known epilogues with branches to __mspabi_func_epilog_N Needs RevisionPublic Authored by atrosinenko on Jul 23 2020, 5:22 AM.
Details
Diff Detail
Event TimelineComment Actions Will you please switch to iterators here? Thanks!
This revision now requires changes to proceed.Aug 7 2020, 2:52 AM
Comment Actions analyzeBranch should probably be a separate patch
This revision now requires changes to proceed.Nov 16 2022, 3:51 PM
Revision Contents
Diff 284281 llvm/lib/Target/MSP430/CMakeLists.txt
llvm/lib/Target/MSP430/MSP430.h
llvm/lib/Target/MSP430/MSP430CommonEpilogueOptimizer.cpp
llvm/lib/Target/MSP430/MSP430InstrInfo.cpp
llvm/lib/Target/MSP430/MSP430TargetMachine.cpp
llvm/test/CodeGen/MSP430/asm-clobbers.ll
llvm/test/CodeGen/MSP430/mspabi-func-epilog-multi-terminators.mir
llvm/test/CodeGen/MSP430/mspabi-func-epilog-special-cases.ll
llvm/test/CodeGen/MSP430/mspabi-func-epilog.ll
|
I would not use low-level list-manipulating stuff here. Can we just use iterators here?
So we would have iterator to Begin, to End. In the for loop do something like this: