xref: /aosp_15_r20/external/llvm/test/MC/MachO/PowerPC/coal-sections-powerpc.s (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker// RUN: llvm-mc -triple powerpc-apple-darwin8 -arch=ppc32 -filetype=obj %s -o - | llvm-readobj -sections | FileCheck %s
2*9880d681SAndroid Build Coastguard Worker
3*9880d681SAndroid Build Coastguard Worker// CHECK: Section {
4*9880d681SAndroid Build Coastguard Worker// CHECK-NEXT: Index: 0
5*9880d681SAndroid Build Coastguard Worker
6*9880d681SAndroid Build Coastguard Worker// CHECK: Section {
7*9880d681SAndroid Build Coastguard Worker// CHECK-NEXT: Index: 1
8*9880d681SAndroid Build Coastguard Worker// CHECK-NEXT: Name: __textcoal_nt (
9*9880d681SAndroid Build Coastguard Worker
10*9880d681SAndroid Build Coastguard Worker// CHECK: Section {
11*9880d681SAndroid Build Coastguard Worker// CHECK-NEXT: Index: 2
12*9880d681SAndroid Build Coastguard Worker
13*9880d681SAndroid Build Coastguard Worker// CHECK: Section {
14*9880d681SAndroid Build Coastguard Worker// CHECK-NEXT: Index: 3
15*9880d681SAndroid Build Coastguard Worker// CHECK-NEXT: Name: __const_coal (
16*9880d681SAndroid Build Coastguard Worker
17*9880d681SAndroid Build Coastguard Worker// CHECK: Section {
18*9880d681SAndroid Build Coastguard Worker// CHECK-NEXT: Index: 4
19*9880d681SAndroid Build Coastguard Worker// CHECK-NEXT: Name: __datacoal_nt (
20*9880d681SAndroid Build Coastguard Worker
21*9880d681SAndroid Build Coastguard Worker  .section  __TEXT,__text,regular,pure_instructions
22*9880d681SAndroid Build Coastguard Worker  .machine ppc
23*9880d681SAndroid Build Coastguard Worker  .section  __TEXT,__textcoal_nt,coalesced,pure_instructions
24*9880d681SAndroid Build Coastguard Worker  .section  __TEXT,__symbol_stub1,symbol_stubs,pure_instructions,16
25*9880d681SAndroid Build Coastguard Worker  .section  __TEXT,__text,regular,pure_instructions
26*9880d681SAndroid Build Coastguard Worker  .section  __TEXT,__textcoal_nt,coalesced,pure_instructions
27*9880d681SAndroid Build Coastguard Worker  .globl  _foo
28*9880d681SAndroid Build Coastguard Worker  .weak_definition  _foo
29*9880d681SAndroid Build Coastguard Worker  .align  4
30*9880d681SAndroid Build Coastguard Worker_foo:
31*9880d681SAndroid Build Coastguard Worker	blr
32*9880d681SAndroid Build Coastguard Worker
33*9880d681SAndroid Build Coastguard Worker.subsections_via_symbols
34*9880d681SAndroid Build Coastguard Worker	.section	__TEXT,__const_coal,coalesced
35*9880d681SAndroid Build Coastguard Worker	.globl	_a                      ; @a
36*9880d681SAndroid Build Coastguard Worker	.weak_definition	_a
37*9880d681SAndroid Build Coastguard Worker	.align	4
38*9880d681SAndroid Build Coastguard Worker_a:
39*9880d681SAndroid Build Coastguard Worker	.long	1                       ; 0x1
40*9880d681SAndroid Build Coastguard Worker
41*9880d681SAndroid Build Coastguard Worker	.section	__DATA,__datacoal_nt,coalesced
42*9880d681SAndroid Build Coastguard Worker	.globl	_b                      ; @b
43*9880d681SAndroid Build Coastguard Worker	.weak_definition	_b
44*9880d681SAndroid Build Coastguard Worker	.align	2
45*9880d681SAndroid Build Coastguard Worker_b:
46*9880d681SAndroid Build Coastguard Worker	.long	5                       ; 0x5
47