1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 12:02:58 +02:00

fix rdar://8456389 - llvm-mc mismatch with 'as' on 'fstp'

-This line, and those below, will be ignored--

M    test/MC/AsmParser/X86/x86_instructions.s
M    lib/Target/X86/AsmParser/X86AsmParser.cpp

llvm-svn: 114527
This commit is contained in:
Chris Lattner 2010-09-22 04:04:03 +00:00
parent f43f09693e
commit 2d350c46e2
2 changed files with 14 additions and 0 deletions

View File

@ -1015,6 +1015,14 @@ ParseInstruction(StringRef Name, SMLoc NameLoc,
Operands[0] = X86Operand::CreateToken("movsl", NameLoc);
}
// fstp <mem> -> fstps <mem>. Without this, we'll default to fstpl due to
// suffix searching.
if (Name == "fstp" && Operands.size() == 2 &&
static_cast<X86Operand*>(Operands[1])->isMem()) {
delete Operands[0];
Operands[0] = X86Operand::CreateToken("fstps", NameLoc);
}
return false;
}

View File

@ -310,3 +310,9 @@ enter $0x7ace,$0
enter $0x7ace,$1
enter $0x7ace,$0x7f
// rdar://8456389
// CHECK: fstps (%eax)
// CHECK: encoding: [0xd9,0x18]
fstp (%eax)