mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
[mips] Support 9-bit offsets for the 'R' inline assembly memory constraint.
Summary: The 'R' constraint is actually supposed to be much more complicated than this and is defined in terms of whether it will cause macro expansion in the assembler. 'R' is getting less useful due to architecture changes and ought to be replaced by other constraints. We therefore implement 9-bit offsets which will work for all subtargets and all instructions. Reviewers: vkalintiris Reviewed By: vkalintiris Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D8440 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@233537 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -51,14 +51,5 @@ entry:
|
||||
; CHECK: #NO_APP
|
||||
tail call i32 asm sideeffect "addiu $0,$1,$2", "=r,r,P"(i32 7, i32 65535) nounwind
|
||||
|
||||
; Now R Which takes the address of c
|
||||
%c = alloca i32, align 4
|
||||
store i32 -4469539, i32* %c, align 4
|
||||
%8 = call i32 asm sideeffect "lw $0, 1 + $1\0A\09lw $0, 2 + $1\0A\09", "=r,*R"(i32* %c) #1
|
||||
; CHECK: #APP
|
||||
; CHECK: lw ${{[0-9]+}}, 1 + 0(${{[0-9]+}})
|
||||
; CHECK: lw ${{[0-9]+}}, 2 + 0(${{[0-9]+}})
|
||||
; CHECK: #NO_APP
|
||||
|
||||
ret i32 0
|
||||
}
|
||||
|
Reference in New Issue
Block a user