mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-24 23:28:41 +00:00
[ARMv8] Prevent generation of deprecated IT blocks on ARMv8 in Thumb mode.
IT blocks can only be one instruction lonf, and can only contain a subset of the 16 instructions. Patch by Artyom Skrobov! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190309 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -196,8 +196,13 @@ bool ARMPassConfig::addPreSched2() {
|
||||
addPass(createARMExpandPseudoPass());
|
||||
|
||||
if (getOptLevel() != CodeGenOpt::None) {
|
||||
if (!getARMSubtarget().isThumb1Only())
|
||||
if (!getARMSubtarget().isThumb1Only()) {
|
||||
// in v8, IfConversion depends on Thumb instruction widths
|
||||
if (getARMSubtarget().hasV8Ops() &&
|
||||
!getARMSubtarget().prefers32BitThumb())
|
||||
addPass(createThumb2SizeReductionPass());
|
||||
addPass(&IfConverterID);
|
||||
}
|
||||
}
|
||||
if (getARMSubtarget().isThumb2())
|
||||
addPass(createThumb2ITBlockPass());
|
||||
|
Reference in New Issue
Block a user