summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorJessica Paquette <jpaquette@apple.com>2018-06-26 20:57:19 +0000
committerJessica Paquette <jpaquette@apple.com>2018-06-26 20:57:19 +0000
commit0a80af07618a0afe20df39cd8692a1d29876507d (patch)
treecc3b2f04e6a129149dc01a62dd27a5ce976a5104 /llvm/lib
parent504be7916806b1c1bd37b7dfd690425a8cc595e3 (diff)
downloadbcm5719-llvm-0a80af07618a0afe20df39cd8692a1d29876507d.tar.gz
bcm5719-llvm-0a80af07618a0afe20df39cd8692a1d29876507d.zip
Revert "[X86][AsmParser] Emit an error when RIP-relative instructions are used in 32-bit mode"
This reverts commit 4850a9aae8b38c7deadc103d634ec7397e6c323b. It caused MC/X86/x86_errors.s to fail. Will fix and recommit shortly. llvm-svn: 335660
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp7
1 files changed, 0 insertions, 7 deletions
diff --git a/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp b/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp
index 6bb82da9402..a7dbdee5243 100644
--- a/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp
+++ b/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp
@@ -974,13 +974,6 @@ static unsigned MatchRegisterName(StringRef Name);
static bool CheckBaseRegAndIndexRegAndScale(unsigned BaseReg, unsigned IndexReg,
unsigned Scale, bool Is64BitMode,
StringRef &ErrMsg) {
- // RIP/EIP-relative addressing is only supported in 64-bit mode.
- if (!Is64BitMode && BaseReg != 0 &&
- (BaseReg == X86::RIP || BaseReg == X86::EIP)) {
- ErrMsg = "RIP-relative addressing requires 64-bit mode";
- return true;
- }
-
// If we have both a base register and an index register make sure they are
// both 64-bit or 32-bit registers.
// To support VSIB, IndexReg can be 128-bit or 256-bit registers.
OpenPOWER on IntegriCloud