mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-11-02 07:17:36 +00:00
Never use .lcomm on platforms where it does not accept an alignment
argument. Instead, use a pair of .local and .comm directives. This avoids spurious differences between binaries built by the integrated assembler vs. those built by the external assembler, since the external assembler may impose alignment requirements on .lcomm symbols where the integrated assembler does not. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168704 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -10,7 +10,8 @@
|
||||
@STRIDE = internal global i32 8
|
||||
|
||||
; ASM: .type array00,%object @ @array00
|
||||
; ASM-NEXT: .lcomm array00,80
|
||||
; ASM-NEXT: .local array00
|
||||
; ASM-NEXT: .comm array00,80,1
|
||||
; ASM-NEXT: .type _MergedGlobals,%object @ @_MergedGlobals
|
||||
|
||||
|
||||
|
||||
@@ -4,8 +4,9 @@
|
||||
@c = internal global i8 0, align 1
|
||||
@x = internal global i32 0, align 4
|
||||
|
||||
; CHECK: .lcomm c,1
|
||||
; .lcomm doesn't support alignment.
|
||||
; .lcomm doesn't support alignment, so we always use .local/.comm.
|
||||
; CHECK: .local c
|
||||
; CHECK-NEXT: .comm c,1,1
|
||||
; CHECK: .local x
|
||||
; CHECK-NEXT: .comm x,4,4
|
||||
|
||||
|
||||
Reference in New Issue
Block a user