mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 04:30:23 +00:00
ARM asm parser wasn't able to parse a "mov" instruction while in Thumb
mode (only the "mov.w" variant). Now, when parsing "mov" in thumb mode, default to the Thumb 1 versions/encodings. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132233 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
157371f376
commit
be64b39431
@ -1830,10 +1830,11 @@ GetMnemonicAcceptInfo(StringRef Mnemonic, bool &CanAcceptCarrySet,
|
||||
Mnemonic == "rrx" || Mnemonic == "ror" || Mnemonic == "sub" ||
|
||||
Mnemonic == "smull" || Mnemonic == "add" || Mnemonic == "adc" ||
|
||||
Mnemonic == "mul" || Mnemonic == "bic" || Mnemonic == "asr" ||
|
||||
Mnemonic == "umlal" || Mnemonic == "orr" || Mnemonic == "mov" ||
|
||||
Mnemonic == "umlal" || Mnemonic == "orr" || Mnemonic == "mvn" ||
|
||||
Mnemonic == "rsb" || Mnemonic == "rsc" || Mnemonic == "orn" ||
|
||||
Mnemonic == "sbc" || Mnemonic == "mla" || Mnemonic == "umull" ||
|
||||
Mnemonic == "eor" || Mnemonic == "smlal" || Mnemonic == "mvn") {
|
||||
Mnemonic == "eor" || Mnemonic == "smlal" ||
|
||||
(Mnemonic == "mov" && !isThumb)) {
|
||||
CanAcceptCarrySet = true;
|
||||
} else {
|
||||
CanAcceptCarrySet = false;
|
||||
@ -1852,7 +1853,8 @@ GetMnemonicAcceptInfo(StringRef Mnemonic, bool &CanAcceptCarrySet,
|
||||
|
||||
if (isThumb)
|
||||
if (Mnemonic == "bkpt" || Mnemonic == "mcr" || Mnemonic == "mcrr" ||
|
||||
Mnemonic == "mrc" || Mnemonic == "mrrc" || Mnemonic == "cdp")
|
||||
Mnemonic == "mrc" || Mnemonic == "mrrc" || Mnemonic == "cdp" ||
|
||||
Mnemonic == "mov")
|
||||
CanAcceptPredicationCode = false;
|
||||
}
|
||||
|
||||
|
@ -70,3 +70,6 @@
|
||||
|
||||
@ CHECK: cpsie aif @ encoding: [0x67,0xb6]
|
||||
cpsie aif
|
||||
|
||||
@ CHECK: mov r0, pc @ encoding: [0x78,0x46]
|
||||
mov r0, pc
|
||||
|
Loading…
Reference in New Issue
Block a user