From 650b0ee53b738d8e11370ac5baf9fc2c7d0cede3 Mon Sep 17 00:00:00 2001 From: Tim Northover Date: Thu, 13 Nov 2014 17:58:48 +0000 Subject: ARM: add @llvm.arm.space intrinsic for testing ConstantIslands. Creating tests for the ConstantIslands pass is very difficult, since it depends on precise layout details. Having the ability to precisely inject a number of bytes into the stream helps greatly. llvm-svn: 221903 --- llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp') diff --git a/llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp b/llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp index 4ab05f910ff..7a315c4b2ef 100644 --- a/llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp +++ b/llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp @@ -674,6 +674,8 @@ unsigned ARMBaseInstrInfo::GetInstSizeInBytes(const MachineInstr *MI) const { ++NumEntries; return NumEntries * EntrySize + InstSize; } + case ARM::SPACE: + return MI->getOperand(1).getImm(); } } -- cgit v1.2.3