mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-11-28 08:02:08 +00:00
[X86] Create extra prolog/epilog for stack realignment [part 2]
This patch is to support D145650 for elf target as well. Differential Revision: https://reviews.llvm.org/D146489
This commit is contained in:
parent
aead502b11
commit
614c63bec6
@ -114,7 +114,7 @@ bool X86ArgumentStackSlotPass::runOnMachineFunction(MachineFunction &MF) {
|
||||
if (F.hasFnAttribute(Attribute::Naked))
|
||||
return false;
|
||||
// Only support Linux
|
||||
if (!STI.isTargetLinux())
|
||||
if (!STI.isTargetLinux() && !STI.isTargetELF())
|
||||
return false;
|
||||
if (!TRI->hasBasePointer(MF))
|
||||
return false;
|
||||
|
@ -1,5 +1,6 @@
|
||||
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
|
||||
; RUN: llc -mtriple=i386-pc-linux -stackrealign < %s | FileCheck %s
|
||||
; RUN: llc -mtriple=i386-pc-none-elf -stackrealign < %s | FileCheck %s
|
||||
|
||||
declare i32 @helper() nounwind
|
||||
define void @base() #0 {
|
||||
|
Loading…
Reference in New Issue
Block a user