34 lines · plain
1; RUN: llc -mtriple powerpc64-ibm-aix-xcoff -mxcoff-roptr < %s | FileCheck %s2; RUN: llc -mtriple powerpc64-ibm-aix-xcoff -mxcoff-roptr -filetype=obj -o %t.o < %s3; RUN: llvm-objdump -t --symbol-description %t.o | FileCheck %s --check-prefix=OBJ4 5; RUN: not llc -mtriple powerpc64-ibm-aix-xcoff -mxcoff-roptr -data-sections=false \6; RUN: < %s 2>&1 | FileCheck %s --check-prefix=DS_ERR7; RUN: not llc -mtriple powerpc64le-unknown-linux-gnu -mxcoff-roptr \8; RUN: < %s 2>&1 | FileCheck %s --check-prefix=OS_ERR9 10; DS_ERR: -mxcoff-roptr option must be used with -data-sections11; OS_ERR: -mxcoff-roptr option is only supported on AIX12 13%union.U = type { %"struct.U::A" }14%"struct.U::A" = type { ptr }15 16@_ZL1p = internal constant i64 ptrtoint (ptr @_ZL1p to i64), align 817; CHECK: .csect _ZL1p[RO],318; CHECK-NEXT: .lglobl _ZL1p[RO]19; CHECK-NEXT: .align 320; CHECK-NEXT: .vbyte 8, _ZL1p[RO]21; OBJ-DAG: {{([[:xdigit:]]{16})}} l .text {{([[:xdigit:]]{16})}} (idx: [[#]]) _ZL1p[RO]22@q = thread_local constant ptr @_ZL1p, align 823; CHECK: .csect q[TL],324; CHECK-NEXT: .globl q[TL]25; CHECK-NEXT: .align 326; CHECK-NEXT: .vbyte 8, _ZL1p[RO]27; OBJ-DAG: {{([[:xdigit:]]{16})}} g O .tdata {{([[:xdigit:]]{16})}} (idx: [[#]]) q[TL]28@u = local_unnamed_addr constant [1 x %union.U] [%union.U { %"struct.U::A" { ptr @_ZL1p } }], align 829; CHECK: .csect u[RO],330; CHECK-NEXT: .globl u[RO]31; CHECK-NEXT: .align 332; CHECK-NEXT: .vbyte 8, _ZL1p[RO]33; OBJ-DAG: {{([[:xdigit:]]{16})}} g .text {{([[:xdigit:]]{16})}} (idx: [[#]]) u[RO]34