mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-15 19:24:33 +00:00
XCore target: return error for unsupported alignment
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194463 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -93,6 +93,10 @@ void XCoreFrameLowering::emitPrologue(MachineFunction &MF) const {
|
|||||||
XCoreFunctionInfo *XFI = MF.getInfo<XCoreFunctionInfo>();
|
XCoreFunctionInfo *XFI = MF.getInfo<XCoreFunctionInfo>();
|
||||||
DebugLoc dl = MBBI != MBB.end() ? MBBI->getDebugLoc() : DebugLoc();
|
DebugLoc dl = MBBI != MBB.end() ? MBBI->getDebugLoc() : DebugLoc();
|
||||||
|
|
||||||
|
if (MFI->getMaxAlignment() > getStackAlignment())
|
||||||
|
report_fatal_error("emitPrologue unsupported alignment: "
|
||||||
|
+ Twine(MFI->getMaxAlignment()));
|
||||||
|
|
||||||
bool FP = hasFP(MF);
|
bool FP = hasFP(MF);
|
||||||
const AttributeSet &PAL = MF.getFunction()->getAttributes();
|
const AttributeSet &PAL = MF.getFunction()->getAttributes();
|
||||||
|
|
||||||
|
9
test/CodeGen/XCore/alignment.ll
Normal file
9
test/CodeGen/XCore/alignment.ll
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
; RUN: not llc < %s -march=xcore 2>&1 | FileCheck %s
|
||||||
|
|
||||||
|
; CHECK: emitPrologue unsupported alignment: 8
|
||||||
|
define void @f() nounwind {
|
||||||
|
entry:
|
||||||
|
%BadAlignment = alloca i64, align 8
|
||||||
|
ret void
|
||||||
|
}
|
||||||
|
|
Reference in New Issue
Block a user