llvm.org GIT mirror llvm / a60f216
[llvm-readobj] Change -long-option to --long-option in tests. NFC We use both -long-option and --long-option in tests. Switch to --long-option for consistency. In the "llvm-readelf" mode, -long-option is discouraged as it conflicts with grouped short options and it is not accepted by GNU readelf. While updating the tests, change llvm-readobj -s to llvm-readobj -S to reduce confusion ("s" is --section-headers in llvm-readobj but --symbols in llvm-readelf). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@359649 91177308-0d34-0410-b5e6-96231b3b80d8 Fangrui Song 3 months ago
672 changed file(s) with 1164 addition(s) and 1162 deletion(s). Raw diff Collapse all Expand all
19311931 * Testing MSVC's output::
19321932
19331933 $ cl -c -Z7 foo.cpp # Use /Z7 to keep types in the object file
1934 $ llvm-readobj -codeview foo.obj
1934 $ llvm-readobj --codeview foo.obj
19351935
19361936 * Getting LLVM IR debug info out of Clang::
19371937
19421942 * Generate and dump CodeView from LLVM IR metadata::
19431943
19441944 $ llc foo.ll -filetype=obj -o foo.obj
1945 $ llvm-readobj -codeview foo.obj > foo.txt
1945 $ llvm-readobj --codeview foo.obj > foo.txt
19461946
19471947 Use this pattern in lit test cases and FileCheck the output of llvm-readobj
19481948
0 ; RUN: llc < %s -exception-model=wineh -mtriple=aarch64-pc-mingw32 | FileCheck %s -check-prefix=WINEH
1 ; RUN: llc < %s -exception-model=wineh -mtriple=aarch64-pc-mingw32 -filetype=obj | llvm-readobj -s | FileCheck %s -check-prefix=WINEH-SECTIONS
1 ; RUN: llc < %s -exception-model=wineh -mtriple=aarch64-pc-mingw32 -filetype=obj | llvm-readobj -S | FileCheck %s -check-prefix=WINEH-SECTIONS
22
33 ; Check emission of eh handler and handler data
44 declare i32 @_d_eh_personality(i32, i32, i64, i8*, i8*)
0 ; RUN: llc -o - %s -mtriple=aarch64-windows -verify-machineinstrs | FileCheck %s
11 ; RUN: llc -o %t -filetype=obj %s -mtriple=aarch64-windows
2 ; RUN: llvm-readobj -unwind %t | FileCheck %s -check-prefix=UNWIND
2 ; RUN: llvm-readobj --unwind %t | FileCheck %s -check-prefix=UNWIND
33
44 ; We test the following
55 ; 1) That the unwind help object is created and that its offset from the stack
0 # RUN: llc -o - %s -mtriple=aarch64-windows -start-after=prologepilog -filetype=obj \
1 # RUN: | llvm-readobj -unwind | FileCheck %s
1 # RUN: | llvm-readobj --unwind | FileCheck %s
22 # This test case checks the basic validity of the .xdata section. It's
33 # documented at:
44 # https://docs.microsoft.com/en-us/cpp/build/arm64-exception-handling
0 # RUN: llc -o - %s -mtriple=aarch64-windows -start-after=prologepilog \
1 # RUN: -filetype=obj | llvm-readobj -unwind | FileCheck %s
1 # RUN: -filetype=obj | llvm-readobj --unwind | FileCheck %s
22 # Test that the pre/post increment save of a flating point register is correct.
33
44 # CHECK: ExceptionData {
0 # RUN: llc -o - %s -mtriple=aarch64-windows -start-after=prologepilog \
1 # RUN: -filetype=obj | llvm-readobj -unwind | FileCheck %s
1 # RUN: -filetype=obj | llvm-readobj --unwind | FileCheck %s
22 # Test that the register pairing of both general purpose and floating point
33 # registers is correctly saved in the .xdata section, as well as the pre/post
44 # increment of floating point register pairs.
0 # RUN: llc -o - %s -mtriple=aarch64-windows -start-after=prologepilog \
11 # RUN: -disable-branch-fold -filetype=obj \
2 # RUN: | llvm-readobj -unwind | FileCheck %s
2 # RUN: | llvm-readobj --unwind | FileCheck %s
33 # Check that identical multiple epilgoues are correctly shared in .xdata.
44
55 # CHECK: ExceptionData {
0 # RUN: llc -o - %s -mtriple=aarch64-windows -start-after=prologepilog \
1 # RUN: -filetype=obj | llvm-readobj -unwind | FileCheck %s
1 # RUN: -filetype=obj | llvm-readobj --unwind | FileCheck %s
22
33 # Check that that the large stack allocation is correctly represented in .xdata.
44
0 # RUN: llc -o - %s -mtriple=aarch64-windows -start-after=prologepilog \
1 # RUN: -filetype=obj | llvm-readobj -unwind | FileCheck %s
1 # RUN: -filetype=obj | llvm-readobj --unwind | FileCheck %s
22 # Check save_fplr_x, set_fp, alloc_s
33
44 # CHECK: ExceptionData {
0 # RUN: llc -o - %s -mtriple=aarch64-windows -start-after=prologepilog \
1 # RUN: -filetype=obj | llvm-readobj -unwind | FileCheck %s
1 # RUN: -filetype=obj | llvm-readobj --unwind | FileCheck %s
22 # Check AddFP
33
44 # CHECK: ExceptionData {
0 # RUN: llc -o - %s -mtriple=aarch64-windows -start-after=prologepilog \
11 # RUN: -disable-branch-fold -filetype=obj \
2 # RUN: | llvm-readobj -unwind | FileCheck %s
2 # RUN: | llvm-readobj --unwind | FileCheck %s
33 # Check that non-identical multiple epilgoues are correctly shared in .xdata.
44
55 # CHECK: ExceptionData {
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 < %s | FileCheck --check-prefix=CHECK %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=HSAMD %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=HSAMD %s
22
33 ; CHECK-LABEL: {{^}}min_64_max_64:
44 ; CHECK: SGPRBlocks: 0
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=+code-object-v3 < %s | FileCheck --check-prefixes=ALL-ASM,OSABI-AMDHSA-ASM %s
1 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=+code-object-v3 < %s | llvm-readobj -elf-output-style=GNU -notes -relocations -sections -symbols | FileCheck --check-prefixes=ALL-ELF,OSABI-AMDHSA-ELF %s
1 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=+code-object-v3 < %s | llvm-readelf --notes -relocations -sections -symbols | FileCheck --check-prefixes=ALL-ELF,OSABI-AMDHSA-ELF %s
22
33 ; ALL-ASM-LABEL: {{^}}fadd:
44
0 ; RUN: llc -mtriple amdgcn-amd-amdhsa -filetype=obj <%s \
1 ; RUN: | llvm-readobj -symbols - | FileCheck %s
1 ; RUN: | llvm-readobj --symbols - | FileCheck %s
22
33 ; CHECK: Name: func1
44 ; CHECK: Section: .text.func1
None ; RUN: llc -filetype=obj -march=r600 -mcpu=r600 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,R600 %s
1 ; RUN: llc -filetype=obj -march=r600 -mcpu=r630 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,R630 %s
2 ; RUN: llc -filetype=obj -march=r600 -mcpu=rs880 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RS880 %s
3 ; RUN: llc -filetype=obj -march=r600 -mcpu=rv670 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV670 %s
4 ; RUN: llc -filetype=obj -march=r600 -mcpu=rv710 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV710 %s
5 ; RUN: llc -filetype=obj -march=r600 -mcpu=rv730 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV730 %s
6 ; RUN: llc -filetype=obj -march=r600 -mcpu=rv770 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV770 %s
7 ; RUN: llc -filetype=obj -march=r600 -mcpu=cedar < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CEDAR %s
8 ; RUN: llc -filetype=obj -march=r600 -mcpu=cypress < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CYPRESS %s
9 ; RUN: llc -filetype=obj -march=r600 -mcpu=juniper < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,JUNIPER %s
10 ; RUN: llc -filetype=obj -march=r600 -mcpu=redwood < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,REDWOOD %s
11 ; RUN: llc -filetype=obj -march=r600 -mcpu=sumo < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,SUMO %s
12 ; RUN: llc -filetype=obj -march=r600 -mcpu=barts < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,BARTS %s
13 ; RUN: llc -filetype=obj -march=r600 -mcpu=caicos < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CAICOS %s
14 ; RUN: llc -filetype=obj -march=r600 -mcpu=cayman < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CAYMAN %s
15 ; RUN: llc -filetype=obj -march=r600 -mcpu=turks < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,TURKS %s
16 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx600 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX600 %s
17 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=tahiti < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX600 %s
18 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx601 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
19 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=hainan < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
20 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=oland < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
21 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=pitcairn < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
22 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=verde < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
23 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx700 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX700 %s
24 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=kaveri < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX700 %s
25 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx701 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX701 %s
26 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=hawaii < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX701 %s
27 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx702 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX702 %s
28 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx703 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
29 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=kabini < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
30 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=mullins < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
31 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx704 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX704 %s
32 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=bonaire < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX704 %s
33 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX801 %s
34 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=carrizo < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX801 %s
35 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx802 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
36 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=iceland < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
37 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=tonga < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
38 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx803 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
39 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=fiji < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
40 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=polaris10 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
41 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=polaris11 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
42 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx810 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX810 %s
43 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=stoney < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX810 %s
44 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx900 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX900 %s
45 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX902 %s
46 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx904 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX904 %s
47 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX906 %s
48 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx909 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX909 %s
49 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1010 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1010 %s
0 ; RUN: llc -filetype=obj -march=r600 -mcpu=r600 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,R600 %s
1 ; RUN: llc -filetype=obj -march=r600 -mcpu=r630 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,R630 %s
2 ; RUN: llc -filetype=obj -march=r600 -mcpu=rs880 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RS880 %s
3 ; RUN: llc -filetype=obj -march=r600 -mcpu=rv670 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV670 %s
4 ; RUN: llc -filetype=obj -march=r600 -mcpu=rv710 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV710 %s
5 ; RUN: llc -filetype=obj -march=r600 -mcpu=rv730 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV730 %s
6 ; RUN: llc -filetype=obj -march=r600 -mcpu=rv770 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV770 %s
7 ; RUN: llc -filetype=obj -march=r600 -mcpu=cedar < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CEDAR %s
8 ; RUN: llc -filetype=obj -march=r600 -mcpu=cypress < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CYPRESS %s
9 ; RUN: llc -filetype=obj -march=r600 -mcpu=juniper < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,JUNIPER %s
10 ; RUN: llc -filetype=obj -march=r600 -mcpu=redwood < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,REDWOOD %s
11 ; RUN: llc -filetype=obj -march=r600 -mcpu=sumo < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,SUMO %s
12 ; RUN: llc -filetype=obj -march=r600 -mcpu=barts < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,BARTS %s
13 ; RUN: llc -filetype=obj -march=r600 -mcpu=caicos < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CAICOS %s
14 ; RUN: llc -filetype=obj -march=r600 -mcpu=cayman < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CAYMAN %s
15 ; RUN: llc -filetype=obj -march=r600 -mcpu=turks < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,TURKS %s
16 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx600 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX600 %s
17 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=tahiti < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX600 %s
18 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx601 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
19 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=hainan < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
20 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=oland < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
21 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=pitcairn < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
22 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=verde < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
23 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx700 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX700 %s
24 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=kaveri < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX700 %s
25 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx701 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX701 %s
26 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=hawaii < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX701 %s
27 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx702 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX702 %s
28 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx703 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
29 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=kabini < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
30 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=mullins < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
31 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx704 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX704 %s
32 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=bonaire < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX704 %s
33 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX801 %s
34 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=carrizo < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX801 %s
35 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx802 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
36 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=iceland < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
37 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=tonga < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
38 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx803 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
39 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=fiji < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
40 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=polaris10 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
41 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=polaris11 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
42 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx810 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX810 %s
43 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=stoney < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX810 %s
44 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx900 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX900 %s
45 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX902 %s
46 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx904 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX904 %s
47 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX906 %s
48 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx909 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX909 %s
49 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1010 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1010 %s
5050
5151 ; ARCH-R600: Arch: r600
5252 ; ARCH-GCN: Arch: amdgcn
None ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=NO-SRAM-ECC-GFX902 %s
1 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 -mattr=-sram-ecc < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=NO-SRAM-ECC-GFX902 %s
2 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 -mattr=+sram-ecc < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=SRAM-ECC-GFX902 %s
0 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=NO-SRAM-ECC-GFX902 %s
1 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 -mattr=-sram-ecc < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=NO-SRAM-ECC-GFX902 %s
2 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 -mattr=+sram-ecc < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=SRAM-ECC-GFX902 %s
33
4 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=NO-SRAM-ECC-GFX906 %s
5 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 -mattr=-sram-ecc < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=NO-SRAM-ECC-GFX906 %s
6 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 -mattr=+sram-ecc < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=SRAM-ECC-GFX906 %s
7 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 -mattr=+sram-ecc,+xnack < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=SRAM-ECC-XNACK-GFX906 %s
4 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=NO-SRAM-ECC-GFX906 %s
5 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 -mattr=-sram-ecc < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=NO-SRAM-ECC-GFX906 %s
6 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 -mattr=+sram-ecc < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=SRAM-ECC-GFX906 %s
7 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 -mattr=+sram-ecc,+xnack < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=SRAM-ECC-XNACK-GFX906 %s
88
99 ; NO-SRAM-ECC-GFX902: Flags [
1010 ; NO-SRAM-ECC-GFX902-NEXT: EF_AMDGPU_MACH_AMDGCN_GFX902 (0x2D)
None ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx801 -mattr=-xnack < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=NO-XNACK-GFX801 %s
1 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx802 -mattr=+xnack < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=XNACK-GFX802 %s
0 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx801 -mattr=-xnack < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=NO-XNACK-GFX801 %s
1 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx802 -mattr=+xnack < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=XNACK-GFX802 %s
22
33 ; NO-XNACK-GFX801: Flags [
44 ; NO-XNACK-GFX801-NEXT: EF_AMDGPU_MACH_AMDGCN_GFX801 (0x28)
None ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=NONE %s
1 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd- -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=NONE %s
2 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-unknown -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=NONE %s
3 ; RUN: llc -filetype=obj -mtriple=amdgcn--amdhsa -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=HSA %s
4 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-amdhsa -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=HSA %s
5 ; RUN: llc -filetype=obj -mtriple=amdgcn-unknown-amdhsa -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=HSA %s
6 ; RUN: llc -filetype=obj -mtriple=amdgcn--amdpal -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=PAL %s
7 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-amdpal -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=PAL %s
8 ; RUN: llc -filetype=obj -mtriple=amdgcn-unknown-amdpal -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=PAL %s
9 ; RUN: llc -filetype=obj -mtriple=amdgcn--mesa3d -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=MESA3D %s
10 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-mesa3d -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=MESA3D %s
11 ; RUN: llc -filetype=obj -mtriple=amdgcn-unknown-mesa3d -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=MESA3D %s
0 ; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=NONE %s
1 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd- -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=NONE %s
2 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-unknown -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=NONE %s
3 ; RUN: llc -filetype=obj -mtriple=amdgcn--amdhsa -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=HSA %s
4 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-amdhsa -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=HSA %s
5 ; RUN: llc -filetype=obj -mtriple=amdgcn-unknown-amdhsa -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=HSA %s
6 ; RUN: llc -filetype=obj -mtriple=amdgcn--amdpal -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=PAL %s
7 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-amdpal -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=PAL %s
8 ; RUN: llc -filetype=obj -mtriple=amdgcn-unknown-amdpal -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=PAL %s
9 ; RUN: llc -filetype=obj -mtriple=amdgcn--mesa3d -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=MESA3D %s
10 ; RUN: llc -filetype=obj -mtriple=amdgcn-amd-mesa3d -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=MESA3D %s
11 ; RUN: llc -filetype=obj -mtriple=amdgcn-unknown-mesa3d -mcpu=gfx801 < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=MESA3D %s
1212
1313 ; NONE: OS/ABI: SystemV (0x0)
1414 ; HSA: OS/ABI: AMDGPU_HSA (0x40)
0 ; RUN: llc -mtriple=amdgcn-amd-unknown -mcpu=gfx802 -mattr=-code-object-v3 < %s | FileCheck --check-prefix=GCN --check-prefix=OSABI-UNK --check-prefix=GFX802 %s
11 ; RUN: llc -mtriple=amdgcn-amd-unknown -mcpu=iceland -mattr=-code-object-v3 < %s | FileCheck --check-prefix=GCN --check-prefix=OSABI-UNK --check-prefix=GFX802 %s
2 ; RUN: llc -mtriple=amdgcn-amd-unknown -mcpu=gfx802 -filetype=obj -mattr=-code-object-v3 < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=GCN --check-prefix=OSABI-UNK-ELF --check-prefix=GFX802 %s
2 ; RUN: llc -mtriple=amdgcn-amd-unknown -mcpu=gfx802 -filetype=obj -mattr=-code-object-v3 < %s | llvm-readelf --notes | FileCheck --check-prefix=GCN --check-prefix=OSABI-UNK-ELF --check-prefix=GFX802 %s
33 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -mattr=-code-object-v3 < %s | FileCheck --check-prefix=GCN --check-prefix=OSABI-HSA --check-prefix=GFX802 %s
44 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=iceland -mattr=-code-object-v3 < %s | FileCheck --check-prefix=GCN --check-prefix=OSABI-HSA --check-prefix=GFX802 %s
5 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -filetype=obj -mattr=-code-object-v3 < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=GCN --check-prefix=OSABI-HSA-ELF --check-prefix=GFX802 %s
5 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -filetype=obj -mattr=-code-object-v3 < %s | llvm-readelf --notes | FileCheck --check-prefix=GCN --check-prefix=OSABI-HSA-ELF --check-prefix=GFX802 %s
66 ; RUN: llc -mtriple=amdgcn-amd-amdpal -mcpu=gfx802 -mattr=-code-object-v3 < %s | FileCheck --check-prefix=GCN --check-prefix=OSABI-PAL --check-prefix=GFX802 %s
77 ; RUN: llc -mtriple=amdgcn-amd-amdpal -mcpu=iceland -mattr=-code-object-v3 < %s | FileCheck --check-prefix=GCN --check-prefix=OSABI-PAL --check-prefix=GFX802 %s
8 ; RUN: llc -mtriple=amdgcn-amd-amdpal -mcpu=gfx802 -filetype=obj -mattr=-code-object-v3 < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=GCN --check-prefix=OSABI-PAL-ELF --check-prefix=GFX802 %s
8 ; RUN: llc -mtriple=amdgcn-amd-amdpal -mcpu=gfx802 -filetype=obj -mattr=-code-object-v3 < %s | llvm-readelf --notes | FileCheck --check-prefix=GCN --check-prefix=OSABI-PAL-ELF --check-prefix=GFX802 %s
99 ; RUN: llc -march=r600 < %s | FileCheck --check-prefix=R600 %s
1010
1111 ; OSABI-UNK-NOT: .hsa_code_object_version
None ; RUN: llc < %s -march=amdgcn -verify-machineinstrs -filetype=obj | llvm-readobj -s -symbols -file-headers - | FileCheck --check-prefix=ELF %s
0 ; RUN: llc < %s -march=amdgcn -verify-machineinstrs -filetype=obj | llvm-readobj -S --symbols --file-headers - | FileCheck --check-prefix=ELF %s
11 ; RUN: llc < %s -march=amdgcn -verify-machineinstrs -o - | FileCheck --check-prefix=CONFIG --check-prefix=TYPICAL %s
2 ; RUN: llc < %s -march=amdgcn -mcpu=tonga -mattr=-flat-for-global -verify-machineinstrs -filetype=obj | llvm-readobj -s -symbols -file-headers - | FileCheck --check-prefix=ELF %s
2 ; RUN: llc < %s -march=amdgcn -mcpu=tonga -mattr=-flat-for-global -verify-machineinstrs -filetype=obj | llvm-readobj -S --symbols --file-headers - | FileCheck --check-prefix=ELF %s
33 ; RUN: llc < %s -march=amdgcn -mcpu=tonga -mattr=-flat-for-global -verify-machineinstrs -o - | FileCheck --check-prefix=CONFIG --check-prefix=TONGA %s
4 ; RUN: llc < %s -march=amdgcn -mcpu=carrizo -mattr=-flat-for-global -verify-machineinstrs -filetype=obj | llvm-readobj -s -symbols -file-headers - | FileCheck --check-prefix=ELF %s
4 ; RUN: llc < %s -march=amdgcn -mcpu=carrizo -mattr=-flat-for-global -verify-machineinstrs -filetype=obj | llvm-readobj -S --symbols --file-headers - | FileCheck --check-prefix=ELF %s
55 ; RUN: llc < %s -march=amdgcn -mcpu=carrizo -mattr=-flat-for-global -verify-machineinstrs -o - | FileCheck --check-prefix=CONFIG --check-prefix=TYPICAL %s
66
77 ; Test that we don't try to produce a COFF file on windows
8 ; RUN: llc < %s -mtriple=amdgcn-pc-mingw -verify-machineinstrs -filetype=obj | llvm-readobj -s -symbols -file-headers - | FileCheck --check-prefix=ELF %s
8 ; RUN: llc < %s -mtriple=amdgcn-pc-mingw -verify-machineinstrs -filetype=obj | llvm-readobj -S --symbols --file-headers - | FileCheck --check-prefix=ELF %s
99
1010 ; ELF: Format: ELF64-amdgpu
1111 ; ELF: OS/ABI: SystemV (0x0)
None ; RUN: llc < %s -march=amdgcn -mcpu=fiji -filetype=obj | llvm-readobj -symbols -s -sd - | FileCheck %s
0 ; RUN: llc < %s -march=amdgcn -mcpu=fiji -filetype=obj | llvm-readobj --symbols -S --sd - | FileCheck %s
11
22 ; CHECK: Section {
33 ; CHECK: Name: .AMDGPU.comment.info_1
None ; RUN: llc < %s -march=r600 -mcpu=redwood -filetype=obj | llvm-readobj -s - | FileCheck --check-prefix=ELF %s
0 ; RUN: llc < %s -march=r600 -mcpu=redwood -filetype=obj | llvm-readobj -S - | FileCheck --check-prefix=ELF %s
11 ; RUN: llc < %s -march=r600 -mcpu=redwood -o - | FileCheck --check-prefix=CONFIG %s
22
33 ; ELF: Format: ELF32-amdgpu
0 ; RUN: llc -mtriple=amdgcn--amdhsa -mcpu=kaveri < %s | FileCheck -check-prefix=HSA %s
1 ; RUN: llc -mtriple=amdgcn--amdhsa -mcpu=kaveri -filetype=obj < %s | llvm-readobj -symbols -s -sd | FileCheck -check-prefix=ELF %s
1 ; RUN: llc -mtriple=amdgcn--amdhsa -mcpu=kaveri -filetype=obj < %s | llvm-readobj --symbols -S --sd | FileCheck -check-prefix=ELF %s
22
33 ; ELF: Section {
44 ; ELF: Name: .text
11 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mattr=-code-object-v3 -mcpu=kaveri | FileCheck --check-prefix=HSA-CI %s
22 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mattr=-code-object-v3 -mcpu=carrizo | FileCheck --check-prefix=HSA %s
33 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mattr=-code-object-v3 -mcpu=carrizo | FileCheck --check-prefix=HSA-VI %s
4 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mattr=-code-object-v3 -mcpu=kaveri -filetype=obj | llvm-readobj -symbols -s -sd | FileCheck --check-prefix=ELF %s
5 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mattr=-code-object-v3 -mcpu=kaveri | llvm-mc -filetype=obj -triple amdgcn--amdhsa -mattr=-code-object-v3 -mcpu=kaveri | llvm-readobj -symbols -s -sd | FileCheck %s --check-prefix=ELF
4 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mattr=-code-object-v3 -mcpu=kaveri -filetype=obj | llvm-readobj --symbols -S --sd | FileCheck --check-prefix=ELF %s
5 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mattr=-code-object-v3 -mcpu=kaveri | llvm-mc -filetype=obj -triple amdgcn--amdhsa -mattr=-code-object-v3 -mcpu=kaveri | llvm-readobj --symbols -S --sd | FileCheck %s --check-prefix=ELF
66
77 ; The SHT_NOTE section contains the output from the .hsa_code_object_*
88 ; directives.
None ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck %s
0 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck %s
11
22 ; CHECK: - .args:
33 ; CHECK-NEXT: - .access: read_only
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck %s
11
22 ; CHECK: - Name: test_ro_arg
33 ; CHECK-NEXT: SymbolName: 'test_ro_arg@kd'
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mattr=+code-object-v3 -mcpu=gfx900 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mattr=+code-object-v3 -mcpu=gfx900 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
11 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mattr=+code-object-v3 -mcpu=gfx900 -amdgpu-dump-hsa-metadata -amdgpu-verify-hsa-metadata -filetype=obj -o - < %s 2>&1 | FileCheck --check-prefix=PARSER %s
22
33 ; CHECK: ---
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mattr=-code-object-v3 -mcpu=gfx900 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mattr=-code-object-v3 -mcpu=gfx900 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
11 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mattr=-code-object-v3 -mcpu=gfx900 -amdgpu-dump-hsa-metadata -amdgpu-verify-hsa-metadata -filetype=obj -o - < %s 2>&1 | FileCheck --check-prefix=PARSER %s
22
33 ; CHECK: ---
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX802 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX802 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
33 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=+code-object-v3 -amdgpu-dump-hsa-metadata -amdgpu-verify-hsa-metadata -filetype=obj -o - < %s 2>&1 | FileCheck --check-prefix=PARSER %s
44 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -mattr=+code-object-v3 -amdgpu-dump-hsa-metadata -amdgpu-verify-hsa-metadata -filetype=obj -o - < %s 2>&1 | FileCheck --check-prefix=PARSER %s
55 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=+code-object-v3 -amdgpu-dump-hsa-metadata -amdgpu-verify-hsa-metadata -filetype=obj -o - < %s 2>&1 | FileCheck --check-prefix=PARSER %s
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX802 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX802 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
33 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=-code-object-v3 -amdgpu-dump-hsa-metadata -amdgpu-verify-hsa-metadata -filetype=obj -o - < %s 2>&1 | FileCheck --check-prefix=PARSER %s
44 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -mattr=-code-object-v3 -amdgpu-dump-hsa-metadata -amdgpu-verify-hsa-metadata -filetype=obj -o - < %s 2>&1 | FileCheck --check-prefix=PARSER %s
55 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=-code-object-v3 -amdgpu-dump-hsa-metadata -amdgpu-verify-hsa-metadata -filetype=obj -o - < %s 2>&1 | FileCheck --check-prefix=PARSER %s
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX803 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX803 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=+code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
33
44 ; CHECK: ---
55 ; CHECK: amdhsa.kernels:
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX803 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX803 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
33
44 ; CHECK: ---
55 ; CHECK: Version: [ 1, 0 ]
None ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX802 --check-prefix=NOTES %s
2 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX802 --check-prefix=NOTES %s
2 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
33
44 %opencl.image1d_t = type opaque
55 %opencl.image1d_array_t = type opaque
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX802 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX802 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=-code-object-v3 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
33
44 %opencl.image1d_t = type opaque
55 %opencl.image1d_array_t = type opaque
None ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck %s
0 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck %s
11
22 ; Make sure llc does not crash for invalid opencl version metadata.
33
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck %s
11
22 ; Make sure llc does not crash for invalid opencl version metadata.
33
None ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck %s
0 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck %s
11
22 ; Make sure llc does not crash for invalid opencl version metadata.
33
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck %s
11
22 ; Make sure llc does not crash for invalid opencl version metadata.
33
None ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck %s
0 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck %s
11
22 ; Make sure llc does not crash for invalid opencl version metadata.
33
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck %s
11
22 ; Make sure llc does not crash for invalid opencl version metadata.
33
None ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX803 --check-prefix=NOTES %s
2 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX803 --check-prefix=NOTES %s
2 ; RUN: llc -mattr=+code-object-v3 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
33
44 @var = addrspace(1) global float 0.0
55
None ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=-code-object-v3 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=-code-object-v3 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX803 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=-code-object-v3 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
0 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -mattr=-code-object-v3 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
1 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 -mattr=-code-object-v3 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX803 --check-prefix=NOTES %s
2 ; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -mattr=-code-object-v3 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
33
44 @var = addrspace(1) global float 0.0
55
11 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3,-flat-for-global | FileCheck --check-prefix=HSA-CI %s
22 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mcpu=carrizo -mattr=-code-object-v3 | FileCheck --check-prefix=HSA %s
33 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mcpu=carrizo -mattr=-code-object-v3,-flat-for-global | FileCheck --check-prefix=HSA-VI %s
4 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mcpu=kaveri -filetype=obj -mattr=-code-object-v3 | llvm-readobj -symbols -s -sd | FileCheck --check-prefix=ELF %s
5 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 | llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 | llvm-readobj -symbols -s -sd | FileCheck %s --check-prefix=ELF
4 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mcpu=kaveri -filetype=obj -mattr=-code-object-v3 | llvm-readobj --symbols -S --sd | FileCheck --check-prefix=ELF %s
5 ; RUN: llc < %s -mtriple=amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 | llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 | llvm-readobj --symbols -S --sd | FileCheck %s --check-prefix=ELF
66
77 ; The SHT_NOTE section contains the output from the .hsa_code_object_*
88 ; directives.
None ; RUN: llc -march=amdgcn -mcpu=tahiti -filetype=obj < %s | llvm-readobj -relocations -symbols | FileCheck %s -check-prefix=GCN
1 ; RUN: llc -march=amdgcn -mcpu=tonga -filetype=obj < %s | llvm-readobj -relocations -symbols | FileCheck %s -check-prefix=GCN
2 ; RUN: llc -march=r600 -mcpu=cypress -filetype=obj < %s | llvm-readobj -relocations -symbols | FileCheck %s -check-prefix=EG
0 ; RUN: llc -march=amdgcn -mcpu=tahiti -filetype=obj < %s | llvm-readobj -r --symbols | FileCheck %s -check-prefix=GCN
1 ; RUN: llc -march=amdgcn -mcpu=tonga -filetype=obj < %s | llvm-readobj -r --symbols | FileCheck %s -check-prefix=GCN
2 ; RUN: llc -march=r600 -mcpu=cypress -filetype=obj < %s | llvm-readobj -r --symbols | FileCheck %s -check-prefix=EG
33
44 ; GCN: R_AMDGPU_REL32 extern_const_addrspace
55 ; EG: R_AMDGPU_ABS32 extern_const_addrspace
None ; RUN: llc -filetype=obj -march=r600 -mcpu=cypress -verify-machineinstrs < %s | llvm-readobj -relocations -symbols | FileCheck %s
0 ; RUN: llc -filetype=obj -march=r600 -mcpu=cypress -verify-machineinstrs < %s | llvm-readobj -r --symbols | FileCheck %s
11
22 @arr = internal unnamed_addr addrspace(4) constant [4 x i32] [i32 4, i32 5, i32 6, i32 7], align 4
33
0 ; RUN: llc -march=amdgcn -mtriple=amdgcn-- -mcpu=verde -verify-machineinstrs < %s | FileCheck --check-prefix=GCN --check-prefix=SI %s
11 ; RUN: llc -march=amdgcn -mtriple=amdgcn-- -mcpu=gfx803 -mattr=-flat-for-global -verify-machineinstrs < %s | FileCheck --check-prefix=GCN --check-prefix=SI %s
22 ; RUN: llc -march=amdgcn -mtriple=amdgcn-- -mcpu=gfx900 -mattr=-flat-for-global -verify-machineinstrs < %s | FileCheck --check-prefix=GCN --check-prefix=GFX9 %s
3 ; RUN: llc -march=amdgcn -mtriple=amdgcn-- -mcpu=gfx900 -filetype=obj < %s | llvm-readobj -relocations | FileCheck --check-prefix=RELS %s
3 ; RUN: llc -march=amdgcn -mtriple=amdgcn-- -mcpu=gfx900 -filetype=obj < %s | llvm-readobj -r | FileCheck --check-prefix=RELS %s
44
55 ; RELS: R_AMDGPU_ABS32_LO SCRATCH_RSRC_DWORD0 0x0
66 ; RELS: R_AMDGPU_ABS32_LO SCRATCH_RSRC_DWORD1 0x0
0 ; RUN: llc %s -mtriple=armv7-linux-gnueabi -o - | \
11 ; RUN: FileCheck -check-prefix=ELFASM %s
22 ; RUN: llc %s -mtriple=armv7-linux-gnueabi -filetype=obj -o - | \
3 ; RUN: llvm-readobj -s -sd | FileCheck -check-prefix=ELFOBJ %s
3 ; RUN: llvm-readobj -S --sd | FileCheck -check-prefix=ELFOBJ %s
44
55 ;; Make sure that bl __aeabi_read_tp is materialized and fixed up correctly
66 ;; in the obj case.
0 ; RUN: llc %s -mtriple=armv7-linux-gnueabi -filetype=obj -o - | \
1 ; RUN: llvm-readobj -s -t | FileCheck -check-prefix=OBJ %s
1 ; RUN: llvm-readobj -S -t | FileCheck -check-prefix=OBJ %s
22 ; RUN: llc %s -mtriple=armv7-linux-gnueabi -o - | \
33 ; RUN: FileCheck -check-prefix=ASM %s
44
0 ; Check that MachO ARM CPU Subtypes are respected
11
22 ; RUN: llc -mtriple=armv4t-apple-darwin -filetype=obj -o - < %s \
3 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V4T
3 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V4T
44
55 ; RUN: llc -mtriple=armv5-apple-darwin -filetype=obj -o - < %s \
6 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V5
6 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V5
77 ; RUN: llc -mtriple=armv5e-apple-darwin -filetype=obj -o - < %s \
8 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V5
8 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V5
99 ; RUN: llc -mtriple=armv5t-apple-darwin -filetype=obj -o - < %s \
10 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V5
10 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V5
1111 ; RUN: llc -mtriple=armv5te-apple-darwin -filetype=obj -o - < %s \
12 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V5
12 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V5
1313 ; RUN: llc -mtriple=armv5tej-apple-darwin -filetype=obj -o - < %s \
14 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V5
14 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V5
1515
1616 ; RUN: llc -mtriple=armv6-apple-darwin -filetype=obj -o - < %s \
17 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V6
17 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V6
1818 ; RUN: llc -mtriple=armv6k-apple-darwin -filetype=obj -o - < %s \
19 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V6
19 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V6
2020 ; RUN: llc -mtriple=thumbv6-apple-darwin -filetype=obj -o - < %s \
21 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V6
21 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V6
2222 ; RUN: llc -mtriple=thumbv6k-apple-darwin -filetype=obj -o - < %s \
23 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V6
23 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V6
2424
2525 ; RUN: llc -mtriple=armv6m-apple-darwin -filetype=obj -o - < %s \
26 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V6M
26 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V6M
2727 ; RUN: llc -mtriple=thumbv6m-apple-darwin -filetype=obj -o - < %s \
28 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V6M
28 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V6M
2929
3030 ; RUN: llc -mtriple=armv7-apple-darwin -filetype=obj -o - < %s \
31 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7
31 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7
3232 ; RUN: llc -mtriple=thumbv7-apple-darwin -filetype=obj -o - < %s \
33 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7
33 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7
3434
3535 ; RUN: llc -mtriple=thumbv7em-apple-darwin -mcpu=cortex-m4 -filetype=obj -o - < %s \
36 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7EM
36 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7EM
3737 ; RUN: llc -mtriple=thumbv7em-apple-darwin -mcpu=cortex-m7 -filetype=obj -o - < %s \
38 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7EM
38 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7EM
3939
4040 ; RUN: llc -mtriple=armv7k-apple-darwin -filetype=obj -o - < %s \
41 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7K
41 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7K
4242 ; RUN: llc -mtriple=thumbv7k-apple-darwin -filetype=obj -o - < %s \
43 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7K
43 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7K
4444
4545 ; RUN: llc -mtriple=thumbv7m-apple-darwin -mcpu=sc300 -filetype=obj -o - < %s \
46 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7M
46 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7M
4747 ; RUN: llc -mtriple=thumbv7m-apple-darwin -mcpu=cortex-m3 -filetype=obj -o - < %s \
48 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7M
48 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7M
4949
5050 ; RUN: llc -mtriple=armv7s-apple-darwin -filetype=obj -o - < %s \
51 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7S
51 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7S
5252 ; RUN: llc -mtriple=thumbv7s-apple-darwin -filetype=obj -o - < %s \
53 ; RUN: | llvm-readobj -file-headers | FileCheck %s --check-prefix=CHECK-V7S
53 ; RUN: | llvm-readobj --file-headers | FileCheck %s --check-prefix=CHECK-V7S
5454
5555 define void @_test() {
5656 ret void
0 // This tests that ARM attributes are properly encoded.
11
22 // RUN: llvm-mc < %s -triple=arm-linux-gnueabi -filetype=obj -o - \
3 // RUN: | llvm-readobj -s -sd | FileCheck %s
3 // RUN: | llvm-readobj -S --sd | FileCheck %s
44
55 // Tag_CPU_name (=5)
66 .cpu cortex-a8
11 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 | FileCheck %s
22 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 | FileCheck %s
33
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
77
88 ; CHECK: .eabi_attribute 30, 4 @ Tag_ABI_optimization_goals
99 ; CHECK-OBJ: TagName: ABI_optimization_goals
11 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 | FileCheck %s
22 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 | FileCheck %s
33
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s
77
88 ; CHECK-NOT: .eabi_attribute 30
99 ; CHECK-NOT: Tag_ABI_optimization_goals
11 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 | FileCheck %s
22 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 | FileCheck %s
33
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
77
88 ; CHECK: .eabi_attribute 30, 6 @ Tag_ABI_optimization_goals
99 ; CHECK-OBJ: TagName: ABI_optimization_goals
11 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 | FileCheck %s
22 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 | FileCheck %s
33
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=CHECK-OBJ
77
88 ; CHECK: .eabi_attribute 30, 3 @ Tag_ABI_optimization_goals
99 ; CHECK-OBJ: TagName: ABI_optimization_goals
11 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 | FileCheck %s --check-prefix=SPEED
22 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 | FileCheck %s --check-prefix=MAXSPEED
33
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=NONE-OBJ
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=SPEED-OBJ
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj -arm-attributes - | FileCheck %s --check-prefix=MAXSPEED-OBJ
4 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O0 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=NONE-OBJ
5 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O1 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=SPEED-OBJ
6 ; RUN: llc < %s -mtriple=arm-none-none-eabi -mcpu=cortex-a7 -O3 -filetype obj -o - | llvm-readobj --arm-attributes - | FileCheck %s --check-prefix=MAXSPEED-OBJ
77
88 ; NONE: .eabi_attribute 30, 5 @ Tag_ABI_optimization_goals
99 ; SPEED: .eabi_attribute 30, 1 @ Tag_ABI_optimization_goals
None ; RUN: llc -march=hexagon -filetype=obj -o - < %s | llvm-readobj -relocations | FileCheck %s
0 ; RUN: llc -march=hexagon -filetype=obj -o - < %s | llvm-readobj -r | FileCheck %s
11
22 declare void @bar(i32);
33
None # RUN: llc -start-after=prologepilog -filetype=obj -O0 %s -o - | llvm-readobj -codeview | FileCheck %s
0 # RUN: llc -start-after=prologepilog -filetype=obj -O0 %s -o - | llvm-readobj --codeview | FileCheck %s
11
22 # Offsets are now CFA, or VFRAME, relative. Both the NRVO sret pointer and the
33 # string* parameter are on the stack, NRVO at offset 4 (after RA), and Str at
0 ; RUN: llc -mtriple=mips-unknown-linux -filetype=obj %s -o - | \
1 ; RUN: llvm-readobj -mips-abi-flags | \
1 ; RUN: llvm-readobj --mips-abi-flags | \
22 ; RUN: FileCheck --check-prefix=ASE-MICROMIPS %s
33
44 define void @_Z3foov() #0 {
11 # and proper section types.
22
33 # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o - \
4 # RUN: | llvm-readobj -s | FileCheck %s
4 # RUN: | llvm-readobj -S | FileCheck %s
55
66 .sdata
77 .word 0
0 ; RUN: llc -filetype=asm -o - -mtriple=mips-unknown-linux-gnu -function-sections < %s | FileCheck %s
11 ; RUN: llc -filetype=asm -o - -mtriple=mipsel-unknown-linux-gnu -function-sections < %s | FileCheck %s
22 ; RUN: llc -filetype=obj -o %t -mtriple=mips-unknown-linux-gnu -function-sections < %s
3 ; RUN: llvm-readobj -sections %t | FileCheck %s --check-prefix=CHECK-OBJ
3 ; RUN: llvm-readobj --sections %t | FileCheck %s --check-prefix=CHECK-OBJ
44 ; RUN: llc -filetype=obj -o %t -mtriple=mipsel-unknown-linux-gnu -function-sections < %s
5 ; RUN: llvm-readobj -sections %t | FileCheck %s --check-prefix=CHECK-OBJ
5 ; RUN: llvm-readobj --sections %t | FileCheck %s --check-prefix=CHECK-OBJ
66 ; RUN: llc -filetype=asm -o - -mtriple=mips64-unknown-linux-gnu -function-sections < %s | FileCheck %s
77 ; RUN: llc -filetype=asm -o - -mtriple=mips64el-unknown-linux-gnu -function-sections < %s | FileCheck %s
88 ; RUN: llc -filetype=obj -o %t -mtriple=mips64-unknown-linux-gnu -function-sections < %s
9 ; RUN: llvm-readobj -sections %t | FileCheck %s --check-prefix=CHECK-OBJ
9 ; RUN: llvm-readobj --sections %t | FileCheck %s --check-prefix=CHECK-OBJ
1010 ; RUN: llc -filetype=obj -o %t -mtriple=mips64el-unknown-linux-gnu -function-sections < %s
11 ; RUN: llvm-readobj -sections %t | FileCheck %s --check-prefix=CHECK-OBJ
11 ; RUN: llvm-readobj --sections %t | FileCheck %s --check-prefix=CHECK-OBJ
1212
1313 define i32 @foo() nounwind noinline uwtable "function-instrument"="xray-always" {
1414 ; CHECK: .section .text.foo,"ax",@progbits
22 ; RUN: llc %s -mtriple=thumbebv7-linux-gnueabi -o - | \
33 ; RUN: FileCheck -check-prefix=ELFASM %s
44 ; RUN: llc %s -mtriple=thumbv7-linux-gnueabi -filetype=obj -o - | \
5 ; RUN: llvm-readobj -s -sd | FileCheck -check-prefix=ELFOBJ -check-prefix=ELFOBJ-LE %s
5 ; RUN: llvm-readobj -S --sd | FileCheck -check-prefix=ELFOBJ -check-prefix=ELFOBJ-LE %s
66 ; RUN: llc %s -mtriple=thumbebv7-linux-gnueabi -filetype=obj -o - | \
7 ; RUN: llvm-readobj -s -sd | FileCheck -check-prefix=ELFOBJ -check-prefix=ELFOBJ-BE %s
7 ; RUN: llvm-readobj -S --sd | FileCheck -check-prefix=ELFOBJ -check-prefix=ELFOBJ-BE %s
88
99 ;; Make sure that bl __aeabi_read_tp is materialized and fixed up correctly
1010 ;; in the obj case.
0 ; RUN: llc -mtriple=x86_64-linux-gnu -filetype=asm < %s | FileCheck %s --check-prefix=DIRECTIVE
1 ; RUN: llc -mtriple=x86_64-linux-gnu -filetype=obj < %s | llvm-readobj -symbols | FileCheck %s --check-prefix=STT-FILE
1 ; RUN: llc -mtriple=x86_64-linux-gnu -filetype=obj < %s | llvm-readobj --symbols | FileCheck %s --check-prefix=STT-FILE
22
33 ; DIRECTIVE: .file "foobar"
44 ; STT-FILE: Name: foobar
None ; RUN: llc < %s -mtriple=i686-pc-linux -filetype=obj | llvm-readobj -s -sr -sd | FileCheck %s -check-prefix=LINUX
1 ; RUN: llc < %s -mtriple=i686-darwin-macosx10.7 -filetype=obj | llvm-readobj -sections | FileCheck -check-prefix=DARWIN %s
0 ; RUN: llc < %s -mtriple=i686-pc-linux -filetype=obj | llvm-readobj -S --sr --sd | FileCheck %s -check-prefix=LINUX
1 ; RUN: llc < %s -mtriple=i686-darwin-macosx10.7 -filetype=obj | llvm-readobj --sections | FileCheck -check-prefix=DARWIN %s
22
33 ; On darwin, check that we manage to generate the compact unwind section
44 ; DARWIN: Name: __compact_unwind
0 ; RUN: llc -mtriple i686-windows-itanium -filetype asm -o - %s | FileCheck %s -check-prefix CHECK-ASM
1 ; RUN: llc -mtriple i686-windows-itanium -filetype obj -o - %s | llvm-readobj -relocations - | FileCheck %s -check-prefix CHECK-OBJ
1 ; RUN: llc -mtriple i686-windows-itanium -filetype obj -o - %s | llvm-readobj -r - | FileCheck %s -check-prefix CHECK-OBJ
22
33 @get_count_incremented.count = internal thread_local unnamed_addr global i32 0, align 4
44
0 ; RUN: llc < %s -O1 -mtriple=x86_64-pc-win32 | FileCheck %s -check-prefix=ASM
11 ; RUN: llc < %s -O1 -mtriple=x86_64-pc-win32 -filetype=obj -o %t
2 ; RUN: llvm-readobj -unwind %t | FileCheck %s -check-prefix=READOBJ
2 ; RUN: llvm-readobj --unwind %t | FileCheck %s -check-prefix=READOBJ
33
44 declare void @g(i32)
55
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; struct S {
0 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -O0 < %s | FileCheck --check-prefix=X86 %s
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview | FileCheck --check-prefix=OBJ32 %s
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview | FileCheck --check-prefix=OBJ32 %s
22 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -O0 < %s | FileCheck --check-prefix=X64 %s
3 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview | FileCheck --check-prefix=OBJ64 %s
3 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview | FileCheck --check-prefix=OBJ64 %s
44
55 ; This LL file was generated by running clang on the following code:
66 ; D:\asm.c:
None ; RUN: llc -filetype=obj < %s | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc -filetype=obj < %s | llvm-readobj - --codeview | FileCheck %s
11
22 ; We need three continuation records for this.
33
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11 ;
22 ; Command to generate function-options.ll
33 ; $ clang++ class-options-common.cpp -S -emit-llvm -g -gcodeview -o class-options-common.ll
None ; RUN: llc -filetype=obj < %s | llvm-readobj -codeview - | FileCheck %s
0 ; RUN: llc -filetype=obj < %s | llvm-readobj --codeview - | FileCheck %s
11
22 ; Objective-C++ source demonstrating the issue:
33 ; void (^b)(void) = []() {};
0 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -o - -O0 -filetype=obj < %s \
1 ; RUN: | llvm-readobj -codeview | FileCheck %s
1 ; RUN: | llvm-readobj --codeview | FileCheck %s
22
33 ; C++ source to regenerate:
44 ; namespace foo {
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; Both A and B should get forward declarations and complete definitions for this
33 ; example.
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; ASM: .short 4412 # Record kind: S_COMPILE3
44 ; ASM-NEXT: .long 68 # Flags and language
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; Command to generate enum-co.ll
33 ; $ clang++ enum-co.cpp -S -emit-llvm -g -gcodeview -o enum-co.ll
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; Generated from the following C++ source:
33 ; enum E : int { BLAH };
0 ; RUN: llc -mtriple=i686-windows-msvc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -mtriple=i686-windows-msvc < %s -filetype=obj | llvm-readobj -codeview - | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -mtriple=i686-windows-msvc < %s -filetype=obj | llvm-readobj --codeview - | FileCheck %s --check-prefix=OBJ
22 target datalayout = "e-m:x-p:32:32-i64:64-f80:32-n8:16:32-a:0:32-S32"
33 target triple = "i686-pc-windows-msvc18.0.0"
44
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; C source:
44 ; int getval(void);
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; PR38857
44
0 ; RUN: llc -enable-shrink-wrap=true < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -enable-shrink-wrap=true -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -enable-shrink-wrap=true -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; C source:
44 ; int doSomething(int*);
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11 ;
22 ; Command to generate function-options.ll
33 ; $ clang++ function-options.cpp -S -emit-llvm -g -gcodeview -o function-options.ll
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11 ;
22 ; This test verifies global variables are emitted within the correct scope.
33 ;
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s --check-prefix=OBJ
22 ; RUN: llc < %s -filetype=obj | obj2yaml | FileCheck %s --check-prefix=YAML
33
44 ; C++ source to regenerate:
None ; RUN: llc < %s -filetype=obj -o - | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj -o - | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s -filetype=obj | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
0 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s -filetype=obj | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
11
22 ; This LL file was generated by running 'clang -O1 -g -gcodeview' on the
33 ; volatile int x;
0 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s -filetype=obj | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s -filetype=obj | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; This C++ source should run and you should be able to step through the volatile
44 ; modifications to x in windbg.
None ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s -filetype=obj | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
0 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s -filetype=obj | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
11
22 ; This LL file was generated by running 'clang -O1 -g -gcodeview' on the
33 ; following code:
None ; RUN: llc < %s -filetype=obj -o - | llvm-readobj -codeview -codeview-subsection-bytes | FileCheck %s
0 ; RUN: llc < %s -filetype=obj -o - | llvm-readobj --codeview --codeview-subsection-bytes | FileCheck %s
11
22 ; Check how we pad out the LF_FUNC_ID records. The 00F3F2F1 bytes in LeafData are
33 ; what's interesting here.
None ; RUN: llc -mtriple=x86_64-windows-msvc < %s -filetype=obj -o - | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc -mtriple=x86_64-windows-msvc < %s -filetype=obj -o - | llvm-readobj - --codeview | FileCheck %s
11
22 ; We should only get one func id record, and both inlinees should point to it,
33 ; even though there are two DISubprograms.
0 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s -filetype=obj | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 < %s -filetype=obj | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; This LL file was generated by running 'clang -O1 -g -gcodeview' on the
44 ; following code:
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; Use character types for all 8-bit integers. The VS debugger doesn't cope well
33 ; with the T_[U]INT1 types. Non-C language frontends are likely use the normal
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11 ;
22 ; Verify lambda routines are emitted properly in CodeView.
33 ;
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11 ;
22 ; -- lexicablock.cxx begin ----------------------------------------------------
33 ; int main(int argc, char *argv[]) {
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc < %s -filetype=obj | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc < %s -filetype=obj | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; Test what happens when we have two DIFile entries with differing slashes.
44 ; Make sure we only emit one file checksum entry.
None ; RUN: llc -mtriple=x86_64-windows-msvc < %s -filetype=obj | llvm-readobj -codeview - | FileCheck %s --check-prefix=OBJ
0 ; RUN: llc -mtriple=x86_64-windows-msvc < %s -filetype=obj | llvm-readobj --codeview - | FileCheck %s --check-prefix=OBJ
11
22 ; This LL file was generated by running 'clang -g -gcodeview' on the
33 ; following code:
0 ; RUN: llc -mtriple=x86_64-windows-msvc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -mtriple=x86_64-windows-msvc < %s -filetype=obj | llvm-readobj -codeview - | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -mtriple=x86_64-windows-msvc < %s -filetype=obj | llvm-readobj --codeview - | FileCheck %s --check-prefix=OBJ
22
33 ; This test attempts to exercise gaps in local variables. The local variable 'p'
44 ; will end up in some CSR (esi), which will be used in both the BB scheduled
0 ; RUN: llc -mtriple=x86_64-windows-msvc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -mtriple=x86_64-windows-msvc < %s -filetype=obj | llvm-readobj -codeview - | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -mtriple=x86_64-windows-msvc < %s -filetype=obj | llvm-readobj --codeview - | FileCheck %s --check-prefix=OBJ
22
33 ; This LL file was generated by running 'clang -g -gcodeview' on the
44 ; following code:
None ; RUN: llc < %s -filetype=obj | llvm-readobj -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj --codeview | FileCheck %s
11
22 ; CHECK: {{.*}}Proc{{.*}}Sym {
33 ; CHECK: Kind: S_GPROC32_ID (0x1147)
None ; RUN: llc %s -o - -filetype=obj | llvm-readobj -codeview | FileCheck %s
0 ; RUN: llc %s -o - -filetype=obj | llvm-readobj --codeview | FileCheck %s
11
22 ; CHECK: Struct (0x1000) {
33 ; CHECK: TypeLeafKind: LF_STRUCTURE (0x1505)
0 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -O0 < %s | FileCheck --check-prefix=X86 %s
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ32 %s
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ32 %s
22 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -O0 < %s | FileCheck --check-prefix=X64 %s
3 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ64 %s
3 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ64 %s
44
55 ; This LL file was generated by running clang on the following code:
66 ; D:\input.c:
0 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -O0 < %s | FileCheck --check-prefix=X86 %s
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ32 %s
1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ32 %s
22 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -O0 < %s | FileCheck --check-prefix=X64 %s
3 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ64 %s
3 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ64 %s
44
55 ; This LL file was generated by running clang on the following code:
66 ; D:\source.c:
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; struct HasNested {
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc < %s -filetype=obj | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc < %s -filetype=obj | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; Compile with -O1 as C
44
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11 source_filename = "test/DebugInfo/COFF/purge-typedef-udts.ll"
22 target datalayout = "e-m:x-p:32:32-i64:64-f80:32-n8:16:32-a:0:32-S32"
33 target triple = "i686-pc-windows-msvc19.11.25506"
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc < %s -filetype=obj | llvm-readobj -codeview - | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc < %s -filetype=obj | llvm-readobj --codeview - | FileCheck %s --check-prefix=OBJ
22
33 ; Generated from:
44 ; volatile int x;
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; This test checks that types which are used in expressions, but for which
33 ; there are no variables, known as retained types, get emitted.
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; Check that we keep namespace scopes around the same way MSVC does.
33 ; We do function scopes slightly differently, but everything should be alright.
0 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -O0 < %s | FileCheck --check-prefix=X86 %s
11 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32-itanium -O0 < %s | FileCheck --check-prefix=X86 %s
22 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32-gnu -O0 < %s | FileCheck --check-prefix=X86 %s
3 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ32 %s
4 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32-itanium -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ32 %s
5 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32-gnu -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ32 %s
3 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ32 %s
4 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32-itanium -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ32 %s
5 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32-gnu -o - -O0 < %s | llvm-mc -triple=i686-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ32 %s
66 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -O0 < %s | FileCheck --check-prefix=X64 %s
77 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32-itanium -O0 < %s | FileCheck --check-prefix=X64 %s
88 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32-gnu -O0 < %s | FileCheck --check-prefix=X64 %s
9 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ64 %s
10 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32-itanium -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ64 %s
11 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32-gnu -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -s -sr -codeview -section-symbols | FileCheck --check-prefix=OBJ64 %s
9 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32 -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ64 %s
10 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32-itanium -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ64 %s
11 ; RUN: llc -mcpu=core2 -mtriple=x86_64-pc-win32-gnu -o - -O0 < %s | llvm-mc -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj -S --sr --codeview --section-symbols | FileCheck --check-prefix=OBJ64 %s
1212
1313 ; This LL file was generated by running clang on the following code:
1414 ; D:\test.c:
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; Check for the appropriate MethodKind below.
33
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; ASM: .short 4412 # Record kind: S_COMPILE3
44 ; ASM-NEXT: .long 83 # Flags and language
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
22 ; RUN: opt -S -debugger-tune=lldb %s | FileCheck -check-prefix=OPT %s
33 ;
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat m.cpp
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; CHECK: CodeViewDebugInfo [
33 ; CHECK: Subsection [
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s
0 ; RUN: llc -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s
11
22 ; We should emit two array types: one used to describe the static data member,
33 ; and the other used by the S_GDATA32 for the definition.
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc < %s -filetype=obj -o - | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj -o - | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; ModuleID = 'foo.3a1fbbbh-cgu.0'
33 source_filename = "foo.3a1fbbbh-cgu.0"
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; struct A {
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat hello.cpp
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat t.cpp
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; This test ensures that circular type references through pointer types don't
33 ; cause infinite recursion. It also tests that we always refer to the forward
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; $ cat foo.cpp
0 ; RUN: llc < %s -filetype=obj > %t.obj
1 ; RUN: llvm-readobj -codeview %t.obj | FileCheck --check-prefix=READOBJ %s
1 ; RUN: llvm-readobj --codeview %t.obj | FileCheck --check-prefix=READOBJ %s
22 ; RUN: llvm-pdbutil dump -symbols %t.obj | FileCheck --check-prefix=PDBUTIL %s
33
44 ; C++ to regenerate:
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11 ;
22 ; Verify CodeView emission does not emit forward references for unnamed
33 ; structs/unions. If a forward reference is emitted for an unnamed composite
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 ; RUN: llc -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 ; PR38857
44
0 ; RUN: llc < %s | FileCheck %s --check-prefix=ASM
1 ; RUN: llc < %s -filetype=obj | llvm-readobj -codeview | FileCheck %s --check-prefix=CODEVIEW
1 ; RUN: llc < %s -filetype=obj | llvm-readobj --codeview | FileCheck %s --check-prefix=CODEVIEW
22
33 ; This test checks that for 32-bit x86 we use VFRAME and
44 ; S_DEFRANGE_FRAMEPOINTER_REL with the right offsets. The test has two function
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source to regenerate:
33 ; struct A {
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; Check for the appropriate MethodKind below.
33
None ; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 ; C++ source used to generate IR:
33 ; $ cat t.cpp
None ; RUN: llc < %s -filetype=obj -o - | llvm-readobj - -codeview | FileCheck %s
0 ; RUN: llc < %s -filetype=obj -o - | llvm-readobj - --codeview | FileCheck %s
11
22 ; We used to crash on this input because UnicodeString is a forward declaration
33 ; with no size. Our array type logic wanted to assert the size of the elements
2323 // $ clang++ -g dwarfdump-test-zlib.cc -Wl,--compress-debug-sections=zlib -o dwarfdump-test-zlib.elf-x86-64
2424 // $ clang++ -g dwarfdump-test-zlib.cc -Wa,--compress-debug-sections=zlib -c -o dwarfdump-test-zlib.o.elf-x86-64
2525 // $ clang++ -g dwarfdump-test-zlib.cc -Wl,--compress-debug-sections=zlib-gnu -o dwarfdump-test-zlibgnu.elf-x86-64
26 // llvm-readobj -sections can be used to see that outputs really contain the compressed sections, also output in both
26 // llvm-readobj --sections can be used to see that outputs really contain the compressed sections, also output in both
2727 // cases is slightly smaller, that is because of compression.
0 # RUN: yaml2obj < %s > %t.obj
1 # RUN: llvm-readobj -codeview %t.obj | FileCheck %s
1 # RUN: llvm-readobj --codeview %t.obj | FileCheck %s
22
33 # CHECK: Kind: S_UNAMESPACE (0x1124)
44 # CHECK-NEXT: Namespace: __vc_attributes
11
22 ; debug_names should be emitted regardless of the target and debugger tuning
33 ; RUN: llc -mtriple=x86_64-apple-darwin12 -filetype=obj < %s \
4 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=DEBUG_NAMES %s
4 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=DEBUG_NAMES %s
55 ; RUN: llc -mtriple=x86_64-apple-darwin12 -filetype=obj -debugger-tune=gdb < %s \
6 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=DEBUG_NAMES %s
6 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=DEBUG_NAMES %s
77 ; RUN: llc -mtriple=x86_64-pc-linux -filetype=obj < %s \
8 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=DEBUG_NAMES %s
8 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=DEBUG_NAMES %s
99 ; RUN: llc -mtriple=x86_64-pc-linux -filetype=obj -debugger-tune=lldb < %s \
10 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=DEBUG_NAMES %s
10 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=DEBUG_NAMES %s
1111
1212 ; But not if also type units are enabled.
1313 ; TODO: This is the case because we currently don't generate DWARF v5-compatible
1414 ; type units. Change this once DWARF v5 type units are implemented.
1515 ; RUN: llc -mtriple=x86_64-pc-linux -filetype=obj -generate-type-units -debugger-tune=lldb < %s \
16 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=NONE %s
16 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=NONE %s
1717
1818 ; Debug types are ignored for non-ELF targets which means it shouldn't affect
1919 ; accelerator table generation.
2020 ; RUN: llc -mtriple=x86_64-apple-darwin12 -generate-type-units -filetype=obj < %s \
21 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=DEBUG_NAMES %s
21 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=DEBUG_NAMES %s
2222
2323 ; NONE-NOT: apple_names
2424 ; NONE-NOT: debug_names
11
22 ; Darwin has the apple tables unless we specifically tune for gdb
33 ; RUN: llc -mtriple=x86_64-apple-darwin12 -filetype=obj < %s \
4 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=APPLE %s
4 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=APPLE %s
55 ; RUN: llc -mtriple=x86_64-apple-darwin12 -filetype=obj -debugger-tune=gdb < %s \
6 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=PUB %s
6 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=PUB %s
77
88 ; Linux does has debug_names tables only if we explicitly tune for lldb
99 ; RUN: llc -mtriple=x86_64-pc-linux -filetype=obj < %s \
10 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=PUB %s
10 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=PUB %s
1111 ; RUN: llc -mtriple=x86_64-pc-linux -filetype=obj -debugger-tune=lldb < %s \
12 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=DEBUG_NAMES %s
12 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=DEBUG_NAMES %s
1313
1414 ; No accelerator tables if type units are enabled, as DWARF v4 type units are
1515 ; not compatible with accelerator tables.
1616 ; RUN: llc -mtriple=x86_64-pc-linux -filetype=obj -generate-type-units -debugger-tune=lldb < %s \
17 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=NONE %s
17 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=NONE %s
1818
1919 ; Debug types are ignored for non-ELF targets which means it shouldn't affect
2020 ; accelerator table generation.
2121 ; RUN: llc -mtriple=x86_64-apple-darwin12 -generate-type-units -filetype=obj < %s \
22 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=APPLE %s
22 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=APPLE %s
2323
2424 ; APPLE-NOT: debug_names
2525 ; APPLE-NOT: debug{{.*}}pub
0 ; RUN: llc -O0 < %s | FileCheck %s --check-prefix=CHECK --check-prefix=DEBUG
11 ; RUN: llc < %s | FileCheck %s
2 ; RUN: llc -filetype=obj -O0 < %s | llvm-readobj -codeview - | FileCheck %s --check-prefix=OBJ
2 ; RUN: llc -filetype=obj -O0 < %s | llvm-readobj --codeview - | FileCheck %s --check-prefix=OBJ
33
44 ; IR generated by the following source:
55 ; struct NonTrivial {
11
22 ; RUN: llc < %s -o %t -filetype=obj -O0 -generate-type-units -mtriple=x86_64-unknown-linux-gnu
33 ; RUN: llvm-dwarfdump -v %t | FileCheck --check-prefix=CHECK --check-prefix=SINGLE %s
4 ; RUN: llvm-readobj -s -t %t | FileCheck --check-prefix=OBJ_SINGLE %s
4 ; RUN: llvm-readobj -S -t %t | FileCheck --check-prefix=OBJ_SINGLE %s
55
66 ; RUN: llc < %s -split-dwarf-file=foo.dwo -o %t -filetype=obj -O0 -generate-type-units -mtriple=x86_64-unknown-linux-gnu
77 ; RUN: llvm-dwarfdump -v %t | FileCheck --check-prefix=CHECK --check-prefix=FISSION %s
8 ; RUN: llvm-readobj -s -t %t | FileCheck --check-prefix=OBJ_FISSION %s
8 ; RUN: llvm-readobj -S -t %t | FileCheck --check-prefix=OBJ_FISSION %s
99
1010 ; Generated from bar.cpp:
1111
11
22 ; Darwin has the apple tables unless we specifically tune for gdb
33 ; RUN: llc -mtriple=x86_64-apple-darwin12 -filetype=obj < %s > %t
4 ; RUN: llvm-readobj -sections %t | FileCheck --check-prefix=APPLE %s
4 ; RUN: llvm-readobj --sections %t | FileCheck --check-prefix=APPLE %s
55 ; RUN: llvm-dwarfdump -apple-names %t | FileCheck --check-prefix=APPLE-NAMES %s
66 ; RUN: llc -mtriple=x86_64-apple-darwin12 -filetype=obj -debugger-tune=gdb < %s \
7 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=GNU %s
7 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=GNU %s
88
99 ; Linux does has debug_names tables only if we explicitly tune for lldb
1010 ; RUN: llc -mtriple=x86_64-pc-linux -filetype=obj < %s \
11 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=GNU %s
11 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=GNU %s
1212 ; RUN: llc -mtriple=x86_64-pc-linux -filetype=obj -debugger-tune=lldb < %s \
13 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=GNU %s
13 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=GNU %s
1414
1515 ; No accelerator tables if type units are enabled, as DWARF v4 type units are
1616 ; not compatible with accelerator tables.
1717 ; RUN: llc -mtriple=x86_64-pc-linux -filetype=obj -generate-type-units -debugger-tune=lldb < %s \
18 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=NONE %s
18 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=NONE %s
1919
2020 ; Debug types are ignored for non-ELF targets which means it shouldn't affect
2121 ; accelerator table generation.
2222 ; RUN: llc -mtriple=x86_64-apple-darwin12 -generate-type-units -filetype=obj < %s \
23 ; RUN: | llvm-readobj -sections - | FileCheck --check-prefix=APPLE %s
23 ; RUN: | llvm-readobj --sections - | FileCheck --check-prefix=APPLE %s
2424
2525 ; APPLE-NOT: debug_names
2626 ; APPLE-NOT: debug{{.*}}pub
44 RUN: obj2yaml %S/Inputs/precomp.obj > %t1/precomp.yaml
55 RUN: yaml2obj %t1/precomp-a.yaml > %t1/a.obj
66 RUN: yaml2obj %t1/precomp.yaml > %t1/precomp.obj
7 RUN: llvm-readobj -codeview %t1/a.obj | FileCheck %s -check-prefix PRECOMP
8 RUN: llvm-readobj -codeview %t1/precomp.obj | FileCheck %s -check-prefix ENDPRECOMP
7 RUN: llvm-readobj --codeview %t1/a.obj | FileCheck %s -check-prefix PRECOMP
8 RUN: llvm-readobj --codeview %t1/precomp.obj | FileCheck %s -check-prefix ENDPRECOMP
99 RUN: llvm-pdbutil dump -types %t1/a.obj | FileCheck %s -check-prefix PDB-PRECOMP
1010 RUN: llvm-pdbutil dump -types %t1/precomp.obj | FileCheck %s -check-prefix PDB-ENDPRECOMP
1111
0 // Test that R_390_PC32 and R_390_PC64 relocations can be generated.
1 // RUN: llvm-mc -triple s390x-linux-gnu -filetype=obj %s -o - | llvm-readobj -s -sr -sd | FileCheck %s
1 // RUN: llvm-mc -triple s390x-linux-gnu -filetype=obj %s -o - | llvm-readobj -S --sr --sd | FileCheck %s
22
33 // Test that RuntimeDyld can fix up such relocations.
44 // RUN: rm -rf %t && mkdir -p %t
0 # RUN: llvm-mc -filetype=obj -assemble \
11 # RUN: -triple=aarch64- %s -o - \
2 # RUN: | llvm-readobj -s -t - | FileCheck %s
2 # RUN: | llvm-readobj -S -t - | FileCheck %s
33 # CHECK: Name: $d.1 ({{[1-9][0-9]+}})
44 # CHECK-NEXT: Value: 0x4
55 # CHECK-NEXT: Size: 0
None // RUN: llvm-mc -filetype=obj -triple aarch64_be %s | llvm-readobj -section-data -sections | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple aarch64_be %s | llvm-readobj --section-data -S | FileCheck %s
11
22 // CHECK: 0000: 00123456 789ABCDE
33 foo: .xword 0x123456789abcde
0 // RUN: llvm-mc -triple=arm64-apple-ios -filetype=obj < %s | \
1 // RUN: llvm-readobj --expand-relocs -sections -section-relocations -section-data | \
1 // RUN: llvm-readobj --expand-relocs -S --section-relocations --section-data | \
22 // RUN: FileCheck %s
33 //
44 // rdar://13070556
None // RUN: llvm-mc -filetype=obj -triple aarch64-windows-gnu %s | llvm-readobj -s -sd | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple aarch64-windows-gnu %s | llvm-readobj -S --sd | FileCheck %s
11 .text
22 .align 5
33 f0:
0 ; RUN: llc -mtriple=aarch64-windows -filetype=obj -o - %s | \
1 ; RUN: llvm-readobj -codeview - | FileCheck %s
1 ; RUN: llvm-readobj --codeview - | FileCheck %s
22
33 ; ModuleID = 'a.c'
44 source_filename = "a.c"
0 // RUN: llvm-mc -triple aarch64-apple-ios -o - -filetype=obj %s | \
1 // RUN: llvm-readobj -symbols | FileCheck %s -check-prefix=READOBJ
1 // RUN: llvm-readobj --symbols | FileCheck %s -check-prefix=READOBJ
22
33 // READOBJ-LABEL: Name: cold_func
44 // READOBJ-NEXT: Type: Section
0 // RUN: llvm-mc %s -triple=aarch64-none-linux-gnu -filetype=asm -o - \
11 // RUN: | FileCheck %s --check-prefix=CHECK-ASM
22 // RUN: llvm-mc %s -triple=aarch64-none-linux-gnu -filetype=obj -o %t
3 // RUN: llvm-readobj -s -sd %t | FileCheck %s --check-prefix=CHECK-OBJ
3 // RUN: llvm-readobj -S --sd %t | FileCheck %s --check-prefix=CHECK-OBJ
44 // RUN: llvm-objdump -t %t | FileCheck %s --check-prefix=CHECK-SYMS
55
66 // RUN: llvm-mc %s -triple=aarch64_be-none-linux-gnu -filetype=asm -o - \
77 // RUN: | FileCheck %s --check-prefix=CHECK-ASM
88 // RUN: llvm-mc %s -triple=aarch64_be-none-linux-gnu -filetype=obj -o %t
9 // RUN: llvm-readobj -s -sd %t | FileCheck %s --check-prefix=CHECK-OBJ
9 // RUN: llvm-readobj -S --sd %t | FileCheck %s --check-prefix=CHECK-OBJ
1010 // RUN: llvm-objdump -t %t | FileCheck %s --check-prefix=CHECK-SYMS
1111
1212 .section .inst.aarch64_inst
0 // This test checks that the SEH directives emit the correct unwind data.
11
2 // RUN: llvm-mc -triple aarch64-pc-win32 -filetype=obj %s | llvm-readobj -s -r | FileCheck %s
2 // RUN: llvm-mc -triple aarch64-pc-win32 -filetype=obj %s | llvm-readobj -S -r | FileCheck %s
33
44 // CHECK: Sections [
55 // CHECK: Section {
0 // RUN: llvm-mc -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | FileCheck %s --check-prefix=ASM
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -symbols -s -sd | FileCheck %s --check-prefix=ELF
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | llvm-readobj --symbols -S --sd | FileCheck %s --check-prefix=ELF
22
33 // ELF: Section {
44 // ELF: Name: .text
0 // RUN: llvm-mc -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | FileCheck %s --check-prefix=ASM
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -s -sd | FileCheck %s --check-prefix=ELF
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -S --sd | FileCheck %s --check-prefix=ELF
22
33 // For compatibility reasons we treat convert .text sections to .hsatext
44
0 // RUN: llvm-mc -mattr=+code-object-v3 -triple amdgcn-amd-amdhsa -mcpu=gfx904 -mattr=+xnack < %s | FileCheck --check-prefix=ASM %s
11 // RUN: llvm-mc -mattr=+code-object-v3 -triple amdgcn-amd-amdhsa -mcpu=gfx904 -mattr=+xnack -filetype=obj < %s > %t
2 // RUN: llvm-readobj -elf-output-style=GNU -sections -symbols -relocations %t | FileCheck --check-prefix=READOBJ %s
2 // RUN: llvm-readelf -sections -symbols -relocations %t | FileCheck --check-prefix=READOBJ %s
33 // RUN: llvm-objdump -s -j .rodata %t | FileCheck --check-prefix=OBJDUMP %s
44
55 // big endian not supported
0 // RUN: llvm-mc -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | FileCheck %s --check-prefix=ASM
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -symbols -s -sd | FileCheck %s --check-prefix=ELF
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | llvm-readobj --symbols -S --sd | FileCheck %s --check-prefix=ELF
22
33 // ELF: Section {
44 // ELF: Name: .text
0 // RUN: llvm-mc -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | FileCheck %s --check-prefix=ASM --check-prefix=ASM_700
11 // RUN: llvm-mc -triple amdgcn--amdhsa -mcpu=gfx803 -mattr=-code-object-v3 -show-encoding %s | FileCheck %s --check-prefix=ASM --check-prefix=ASM_803
22 // RUN: llvm-mc -triple amdgcn--amdhsa -mcpu=stoney -mattr=-code-object-v3 -show-encoding %s | FileCheck %s --check-prefix=ASM --check-prefix=ASM_810
3 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -s -sd | FileCheck %s --check-prefix=ELF --check-prefix=ELF_700
4 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=gfx803 -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -s -sd | FileCheck %s --check-prefix=ELF --check-prefix=ELF_803
5 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=stoney -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -s -sd | FileCheck %s --check-prefix=ELF --check-prefix=ELF_810
3 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -S --sd | FileCheck %s --check-prefix=ELF --check-prefix=ELF_700
4 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=gfx803 -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -S --sd | FileCheck %s --check-prefix=ELF --check-prefix=ELF_803
5 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=stoney -mattr=-code-object-v3 -show-encoding %s | llvm-readobj -S --sd | FileCheck %s --check-prefix=ELF --check-prefix=ELF_810
66
77 // ELF: SHT_NOTE
88 // ELF: 0000: 04000000 08000000 01000000 414D4400
0 // RUN: llvm-mc -triple amdgcn--amdpal -mcpu=kaveri -show-encoding %s | FileCheck %s --check-prefix=ASM
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdpal -mcpu=kaveri -show-encoding %s | llvm-readobj -symbols -s -sd | FileCheck %s --check-prefix=ELF
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdpal -mcpu=kaveri -show-encoding %s | llvm-readobj --symbols -S --sd | FileCheck %s --check-prefix=ELF
22
33 .amdgpu_pal_metadata
44 ---
0 // RUN: llvm-mc -triple amdgcn--amdpal -mcpu=kaveri -show-encoding %s | FileCheck %s --check-prefix=ASM
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdpal -mcpu=kaveri -show-encoding %s | llvm-readobj -symbols -s -sd | FileCheck %s --check-prefix=ELF
1 // RUN: llvm-mc -filetype=obj -triple amdgcn--amdpal -mcpu=kaveri -show-encoding %s | llvm-readobj --symbols -S --sd | FileCheck %s --check-prefix=ELF
22
33 .amd_amdgpu_pal_metadata 0x12345678, 0xfedcba98, 0x2468ace0, 0xfdb97531
44 // ASM: .amd_amdgpu_pal_metadata 0x12345678,0xfedcba98,0x2468ace0,0xfdb97531
None // RUN: llvm-mc -filetype=obj -triple amdgcn-- -mcpu=kaveri -show-encoding %s | llvm-readobj -relocations | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple amdgcn-- -mcpu=kaveri -show-encoding %s | llvm-readobj -r | FileCheck %s
11
22 // CHECK: Relocations [
33 // CHECK: .rel.text {
0 // RUN: llvm-mc %s -triple=armv7-linux-gnueabi -filetype=obj -o - | \
1 // RUN: llvm-readobj -s -sr -sd | FileCheck %s
1 // RUN: llvm-readobj -S --sr --sd | FileCheck %s
22
33 .syntax unified
44 .eabi_attribute 6, 10
0 # RUN: llvm-mc -filetype=obj -assemble \
11 # RUN: -triple=arm-arm-none-eabi -mcpu=cortex-a9 %s -o - \
2 # RUN: | llvm-readobj -s -t - | FileCheck %s
2 # RUN: | llvm-readobj -S -t - | FileCheck %s
33 # CHECK: Name: $d.1 ({{[1-9][0-9]+}})
44 # CHECK-NEXT: Value: 0x4
55 # CHECK-NEXT: Size: 0
0 @ RUN: llvm-mc -triple thumbv7-windows-itanium -filetype obj -o - %s \
1 @ RUN: | llvm-readobj -s - | FileCheck %s
1 @ RUN: | llvm-readobj -S - | FileCheck %s
22
33 .syntax unified
44 .text
0 @ RUN: llvm-mc -triple thumbv7-windows-itanium -filetype obj -o - %s \
1 @ RUN: | llvm-readobj -s - | FileCheck %s
1 @ RUN: | llvm-readobj -S - | FileCheck %s
22
33 .syntax unified
44 .thumb
0 @ RUN: llvm-mc -triple thumbv7-windows-itanium -filetype obj -o - %s \
1 @ RUN: | llvm-readobj -s - | FileCheck %s
1 @ RUN: | llvm-readobj -S - | FileCheck %s
22
33 .syntax unified
44 .thumb
11 // RUN: | FileCheck %s
22
33 // RUN: llvm-mc -triple thumbv7-windows -filetype obj %s -o - \
4 // RUN: | llvm-readobj -symbols | FileCheck %s -check-prefix CHECK-SCN
4 // RUN: | llvm-readobj --symbols | FileCheck %s -check-prefix CHECK-SCN
55
66 .file "null-padded.asm"
77 // CHECK: (nx 1) {{0x[0-9]+}} .file
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv2
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv2a
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv3
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv3m
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv4
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv4t
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv5
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv5t
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv5te
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv6-m
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv6
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv6k
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv6t2
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv6z
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv7-a
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv7-m
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv7-r
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv7
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv7a
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv7e-m
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv7em
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv7m
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv7r
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv8-a
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv8.2-a
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch armv8a
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch iwmmxt
55 @ RUN: llvm-mc -triple arm-eabi -filetype asm %s \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ASM
77 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s \
8 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
8 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
99
1010 .syntax unified
1111 .arch iwmmxt2
0 @ RUN: llvm-mc < %s -triple armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd | FileCheck %s
22
33 @ CHECK: Name: .ARM.attribute
44 @ CHECK: SectionData (
0 @ RUN: llvm-mc -triple armv7-eabi -filetype obj -o - %s \
1 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
1 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s -check-prefix CHECK-ATTR
22
33 .syntax unified
44 .thumb
0 @ RUN: llvm-mc -triple armv7-elf -filetype asm -o - %s | FileCheck %s
11 @ RUN: llvm-mc < %s -triple armv7-unknown-linux-gnueabi -filetype=obj -o - \
2 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s --check-prefix=CHECK-OBJ
2 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s --check-prefix=CHECK-OBJ
33
44 .syntax unified
55 .thumb
None @ RUN: llvm-mc -triple armv7-eabi -filetype obj -o - %s | llvm-readobj -s -sd \
0 @ RUN: llvm-mc -triple armv7-eabi -filetype obj -o - %s | llvm-readobj -S --sd \
11 @ RUN: | FileCheck %s
22
33 .syntax unified
22 @ The later .fpu directive should overwrite the earlier one.
33 @ We also check here that all the .fpu directives that we expect to work do work
44
5 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s | llvm-readobj -arm-attributes \
5 @ RUN: llvm-mc -triple arm-eabi -filetype obj %s | llvm-readobj --arm-attributes \
66 @ RUN: | FileCheck %s -check-prefix CHECK-ATTR
77
88 .fpu none
0 @ RUN: llvm-mc < %s -triple armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd | FileCheck %s
22
33 @ CHECK: Name: .ARM.attribute
44 @ CHECK: SectionData (
0 @ RUN: llvm-mc -triple armv7-eabi -filetype obj -o - %s \
1 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s
1 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s
22
33 .syntax unified
44
0 @ RUN: llvm-mc -triple armv7-eabi -filetype obj -o - %s \
1 @ RUN: | llvm-readobj -arm-attributes | FileCheck %s
1 @ RUN: | llvm-readobj --arm-attributes | FileCheck %s
22
33 .syntax unified
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr > %t
1 @ RUN: | llvm-readobj -S --sd --sr > %t
22 @ RUN: FileCheck %s < %t
33 @ RUN: FileCheck --check-prefix=RELOC %s < %t
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd --sr | FileCheck %s
22
33 @ Check the compact pr1 model
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd --sr | FileCheck %s
22
33 @ Check the .cantunwind directive
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr > %t
1 @ RUN: | llvm-readobj -S --sd --sr > %t
22 @ RUN: FileCheck %s < %t
33 @ RUN: FileCheck --check-prefix=RELOC %s < %t
44
1919
2020
2121 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
22 @ RUN: | llvm-readobj -s -sd | FileCheck %s
22 @ RUN: | llvm-readobj -S --sd | FileCheck %s
2323
2424
2525 @-------------------------------------------------------------------------------
None @ RUN: llvm-mc -triple armv7-eabi -filetype obj -o - %s | llvm-readobj -s -sd \
0 @ RUN: llvm-mc -triple armv7-eabi -filetype obj -o - %s | llvm-readobj -S --sd \
11 @ RUN: | FileCheck %s
22
33 .syntax unified
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd | FileCheck %s
22
33 @ Check for different combination of .setfp, .pad, .save and .vsave.
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd | FileCheck %s
22
33 @ Check for different stack pointer offsets.
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr > %t
1 @ RUN: | llvm-readobj -S --sd --sr > %t
22 @ RUN: FileCheck %s < %t
33 @ RUN: FileCheck --check-prefix=RELOC %s < %t
44
0 @ RUN: llvm-mc -triple armv7-linux-eabi -filetype obj -o - %s \
1 @ RUN: | llvm-readobj -s -sd -sr > %t
1 @ RUN: | llvm-readobj -S --sd --sr > %t
22 @ RUN: FileCheck %s < %t
33 @ RUN: FileCheck --check-prefix=RELOC %s < %t
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd | FileCheck %s
22
33 @ Check the .save directive
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr -t | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd --sr -t | FileCheck %s
22
33 @ Check the .group section for the function in comdat section.
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr -t > %t
1 @ RUN: | llvm-readobj -S --sd --sr -t > %t
22 @ RUN: FileCheck %s < %t
33 @ RUN: FileCheck --check-prefix=RELOC %s < %t
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr -t > %t
1 @ RUN: | llvm-readobj -S --sd --sr -t > %t
22 @ RUN: FileCheck %s < %t
33 @ RUN: FileCheck --check-prefix=RELOC %s < %t
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd | FileCheck %s
22
33 @ Check for .setfp directive.
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr -r -t | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd --sr -r -t | FileCheck %s
22
33 @ Check whether the section is switched back or not.
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd --sr | FileCheck %s
22
33 @ Check the .fnstart directive and the .fnend directive.
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd -sr | FileCheck %s
1 @ RUN: | llvm-readobj -S --sd --sr | FileCheck %s
22
33 @ Check the .vsave directive
44
0 @ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s | FileCheck %s
1 @ RUN: | llvm-readobj -S | FileCheck %s
22
33 @ Test that the ARM_EXIDX sections point (Link) to the corresponding text
44 @ sections.
0 // RUN: llvm-mc %s -triple=thumbv7-linux-gnueabi \
1 // RUN: -filetype=obj -o - | llvm-readobj -s -sd -r -t | \
1 // RUN: -filetype=obj -o - | llvm-readobj -S --sd -r -t | \
22 // RUN: FileCheck %s
33
44 // We want to test relocatable thumb function call.
0 @ RUN: llvm-mc %s -triple=armv7-linux-gnueabi -filetype=obj -o - \
1 @ RUN: | llvm-readobj -s -sd | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-LE
1 @ RUN: | llvm-readobj -S --sd | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-LE
22
33 @ RUN: llvm-mc %s -triple=armebv7-linux-gnueabi -filetype=obj -o - \
4 @ RUN: | llvm-readobj -s -sd | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-BE
4 @ RUN: | llvm-readobj -S --sd | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-BE
55
66 .syntax unified
77
0 # Check section containing code and data with permission executable for the section.
11 @ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/1.s
2 @ RUN: llvm-readobj -elf-output-style=GNU -symbols %t.o | FileCheck %s
2 @ RUN: llvm-readelf -symbols %t.o | FileCheck %s
33
44 # Check section containing code and data with no permissions for the section.
55 @ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/2.s
6 @ RUN: llvm-readobj -elf-output-style=GNU -symbols %t.o | FileCheck %s
6 @ RUN: llvm-readelf -symbols %t.o | FileCheck %s
77
88 # Check section containing code and data with read/write permissions for the section.
99 @ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/3.s
10 @ RUN: llvm-readobj -elf-output-style=GNU -symbols %t.o | FileCheck %s
10 @ RUN: llvm-readelf -symbols %t.o | FileCheck %s
1111
1212 # Check section containing data with no permissions for the section.
1313 @ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/4.s
14 @ RUN: llvm-readobj -elf-output-style=GNU -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
14 @ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
1515
1616 # Check section containing only data with read/write permissions for the section.
1717 @ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/5.s
18 @ RUN: llvm-readobj -elf-output-style=GNU -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
18 @ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
1919
2020 # Check section containing the ident string with no permissions for the section.
2121 @ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/ident.s
22 @ RUN: llvm-readobj -elf-output-style=GNU -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
22 @ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
2323
2424 # Check section containing the attributes with no permissions for the section.
2525 @ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/attr.s
26 @ RUN: llvm-readobj -elf-output-style=GNU -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
26 @ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
2727
2828 # Check section containing code and data with no permissions for the section.
2929 # data comes before code.
3030 @ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/6.s
31 @ RUN: llvm-readobj -elf-output-style=GNU -symbols %t.o | FileCheck %s -check-prefix=MIX
31 @ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MIX
3232
3333 # Check section containing code and data with no permissions for the section.
3434 # data comes before code.
3535 @ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/7.s
36 @ RUN: llvm-readobj -elf-output-style=GNU -symbols %t.o | FileCheck %s
36 @ RUN: llvm-readelf -symbols %t.o | FileCheck %s
3737
3838 #CHECK: $a
3939 #CHECK: $d
0 # RUN: llvm-mc -triple i386-pc-linux-gnu -filetype=obj -o %t %s
1 # RUN: llvm-readobj -s -sd < %t | FileCheck %s
1 # RUN: llvm-readobj -S --sd < %t | FileCheck %s
22 .section test1
33 .byte 1
44 .section test2
0 # RUN: llvm-mc -triple i386-pc-linux-gnu -filetype=obj -o %t %s
1 # RUN: llvm-readobj -s < %t | FileCheck %s
1 # RUN: llvm-readobj -S < %t | FileCheck %s
22 .section .nobits
33 .byte 1
44 .section .nobits2
None // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s -o - | llvm-readobj -s -t -sd -addrsig | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s -o - | llvm-readobj -S -t --sd --addrsig | FileCheck %s
11
22 // CHECK: Name: .llvm_addrsig
33 // CHECK-NEXT: VirtualSize: 0x0
None // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 -mcpu=pentiumpro %s | llvm-readobj -s -sd | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 -mcpu=pentiumpro %s | llvm-readobj -S --sd | FileCheck %s
11
22 // Test that we get optimal nops in text
33 .text
0 // This test checks that the COFF object emitter works for the most basic
11 // programs.
22
3 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj -h -s -sr -sd -t | FileCheck %s
3 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj -h -S --sr --sd -t | FileCheck %s
44
55 .def _main;
66 .scl 2;
0 // This test checks that the COFF object emitter works for the most basic
11 // programs.
22
3 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -h -s -sr -sd -t | FileCheck %s
3 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -h -S --sr --sd -t | FileCheck %s
44
55 .def _main;
66 .scl 2;
0 // The purpose of this test is to verify that bss sections are emitted correctly.
11
2 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -s | FileCheck %s
3 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj -s | FileCheck %s
2 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -S | FileCheck %s
3 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj -S | FileCheck %s
44
55 .bss
66 .globl _g0
0 # RUN: llvm-mc -triple i686-windows-gnu -filetype obj -o - %s \
1 # RUN: | llvm-readobj -coff-directives -symbols | FileCheck %s
1 # RUN: | llvm-readobj --coff-directives --symbols | FileCheck %s
22
33 # NOTE: this test checks multiple things:
44 # - that -aligncomm is not emitted for 1-byte alignment
0 // Verify the .fix data section conveys the right offsets and the right relocations
1 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s -o - | llvm-readobj -relocations -expand-relocs -sections -section-data | FileCheck %s --check-prefix=READOBJ
1 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s -o - | llvm-readobj -r --expand-relocs -S --section-data | FileCheck %s --check-prefix=READOBJ
22
33 .text
44 .section .rdata,"dr"
None # RUN: llvm-mc -triple=x86_64-pc-win32 -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s
0 # RUN: llvm-mc -triple=x86_64-pc-win32 -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s
11
22 # This tries to test defrange gap edge cases.
33
None # RUN: llvm-mc -triple=i686-pc-win32 -filetype=obj < %s | llvm-readobj -codeview -codeview-subsection-bytes | FileCheck %s
0 # RUN: llvm-mc -triple=i686-pc-win32 -filetype=obj < %s | llvm-readobj --codeview --codeview-subsection-bytes | FileCheck %s
11 .text
22 .def @feat.00;
33 .scl 3;
None # RUN: llvm-mc -filetype=obj -triple i686-pc-win32 < %s | llvm-readobj -codeview - | FileCheck %s
0 # RUN: llvm-mc -filetype=obj -triple i686-pc-win32 < %s | llvm-readobj --codeview - | FileCheck %s
11 .text
22 .section .debug$S,"dr"
33 .p2align 2
None # RUN: llvm-mc -filetype=obj -triple i686-pc-win32 < %s | llvm-readobj -codeview - | FileCheck %s
0 # RUN: llvm-mc -filetype=obj -triple i686-pc-win32 < %s | llvm-readobj --codeview - | FileCheck %s
11 .text
22 .def @feat.00;
33 .scl 3;
0 # RUN: llvm-mc -filetype=asm < %s -triple i686-windows-msvc | FileCheck %s --check-prefix=ASM
1 # RUN: llvm-mc -filetype=obj < %s -triple i686-windows-msvc | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 # RUN: llvm-mc -filetype=obj < %s -triple i686-windows-msvc | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 .globl _foo
44 _foo:
None # RUN: llvm-mc -triple=i686-windows-msvc -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s
0 # RUN: llvm-mc -triple=i686-windows-msvc -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s
11
22 # Test for .cv_fpo_stackalign. We should generate FPO data that restores CSRs
33 # at each instruction, and in the last FrameData we should use the '@'
0 # RUN: llvm-mc -filetype=asm < %s -triple i686-windows-msvc | FileCheck %s --check-prefix=ASM
1 # RUN: llvm-mc -filetype=obj < %s -triple i686-windows-msvc | llvm-readobj -codeview | FileCheck %s --check-prefix=OBJ
1 # RUN: llvm-mc -filetype=obj < %s -triple i686-windows-msvc | llvm-readobj --codeview | FileCheck %s --check-prefix=OBJ
22
33 .globl _foo
44 _foo:
None # RUN: llvm-mc -triple=x86_64-pc-win32 -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s
0 # RUN: llvm-mc -triple=x86_64-pc-win32 -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s
11
22 # CHECK: InlineSiteSym {
33 # CHECK: BinaryAnnotations [
None # RUN: llvm-mc -triple=x86_64-windows -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s
0 # RUN: llvm-mc -triple=x86_64-windows -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s
11
22 # C source to generate the assembly:
33 # volatile int unlikely_cond = 0;
None # RUN: llvm-mc -triple=i686-pc-win32 -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s
0 # RUN: llvm-mc -triple=i686-pc-win32 -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s
11 .text
22 .def @feat.00;
33 .scl 3;
None # RUN: llvm-mc -triple=i686-pc-win32 -filetype=obj < %s | llvm-readobj -codeview | FileCheck %s
0 # RUN: llvm-mc -triple=i686-pc-win32 -filetype=obj < %s | llvm-readobj --codeview | FileCheck %s
11 .text
22 .def @feat.00;
33 .scl 3;
None # RUN: llvm-mc < %s -triple=i686-pc-win32 -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 # RUN: llvm-mc < %s -triple=i686-pc-win32 -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 # Based on the other cv-loc-unreachable-2.s, but with other code in the same
33 # section afterwards. We had negative label difference assertions when .cv_loc
None # RUN: llvm-mc < %s -triple=i686-pc-win32 -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 # RUN: llvm-mc < %s -triple=i686-pc-win32 -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 # Original source, slightly modified with an extra .cv_loc directive (at EXTRA
33 # below) that was causing assertions:
None # RUN: llvm-mc < %s -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj - -codeview | FileCheck %s
0 # RUN: llvm-mc < %s -triple=x86_64-pc-win32 -filetype=obj | llvm-readobj - --codeview | FileCheck %s
11
22 .section .debug$S
33 .long 4
0 # RUN: llvm-mc -triple=i686-windows-msvc %s -filetype=obj -o %t.obj
1 # RUN: llvm-readobj -codeview %t.obj | FileCheck %s
1 # RUN: llvm-readobj --codeview %t.obj | FileCheck %s
22
33 # The .cv_string directive mainly exists as a convenience for manually writing
44 # FPO data in assembler. Test that we can write FPO data using this directive,
None // RUN: llvm-mc -filetype=obj -triple i686-pc-mingw32 %s | llvm-readobj -s -sr -sd | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple i686-pc-mingw32 %s | llvm-readobj -S --sr --sd | FileCheck %s
11
22 // COFF resolves differences between labels in the same section, unless that
33 // label is declared with function type.
None ; RUN: llc -mtriple i686-windows -filetype obj -o - %s | llvm-readobj -sections \
0 ; RUN: llc -mtriple i686-windows -filetype obj -o - %s | llvm-readobj --sections \
11 ; RUN: | FileCheck %s
22
33 define dllexport void @function() {
0 # RUN: llvm-mc -triple i686-windows -g -filetype obj -o - %s \
1 # RUN: | llvm-readobj -s -t | FileCheck %s
1 # RUN: | llvm-readobj -S -t | FileCheck %s
22
33 .section .rdata
44
None // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s -o - | llvm-readobj -s | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s -o - | llvm-readobj -S | FileCheck %s
11
22 .def _main;
33 .scl 2;
66 // RUN: | FileCheck %s
77
88 // RUN: llvm-mc -triple i686-windows -filetype obj %s -o - \
9 // RUN: | llvm-readobj -symbols | FileCheck %s -check-prefix CHECK-SCN
9 // RUN: | llvm-readobj --symbols | FileCheck %s -check-prefix CHECK-SCN
1010
1111 .file "null-padded.asm"
1212 // CHECK: (nx 1) {{0x[0-9]+}} .file
0 // Test section manipulation via .linkonce directive.
11 //
2 // RUN: llvm-mc -triple i386-pc-win32 -filetype=obj %s | llvm-readobj -s -t | FileCheck %s
3 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -s -t | FileCheck %s
2 // RUN: llvm-mc -triple i386-pc-win32 -filetype=obj %s | llvm-readobj -S -t | FileCheck %s
3 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -S -t | FileCheck %s
44
55 .section s1
66 .linkonce
0 ; The purpose of this test is to verify that various module level assembly
11 ; constructs work.
22
3 ; RUN: llc -filetype=obj -mtriple i686-pc-win32 %s -o - | llvm-readobj -s -sd | FileCheck %s
4 ; RUN: llc -filetype=obj -mtriple x86_64-pc-win32 %s -o - | llvm-readobj -s -sd | FileCheck %s
3 ; RUN: llc -filetype=obj -mtriple i686-pc-win32 %s -o - | llvm-readobj -S --sd | FileCheck %s
4 ; RUN: llc -filetype=obj -mtriple x86_64-pc-win32 %s -o - | llvm-readobj -S --sd | FileCheck %s
55
66 module asm ".text"
77 module asm "_foo:"
None // RUN: llvm-mc -filetype=obj -triple i686-pc-windows-msvc < %s | llvm-readobj -s --section-data | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple i686-pc-windows-msvc < %s | llvm-readobj -S --section-data | FileCheck %s
11
22 .text
33 .set var, 42
None // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -s -sr | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -S --sr | FileCheck %s
11
22 // check that we produce the correct relocation for .secidx
33
0 # RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s -o %t.obj
1 # RUN: llvm-readobj -symbols -relocations %t.obj | FileCheck %s
1 # RUN: llvm-readobj --symbols -r %t.obj | FileCheck %s
22
33 # Previously .secrel32 and .secidx relocations against undefined symbols
44 # resulted in an error. That was a mistake. The linker is fully capable of
None // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -s -sr | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -S --sr | FileCheck %s
11
22 // check that we produce the correct relocation for .secrel32
33
None // RUN: llvm-mc -triple i386-pc-win32 -filetype=obj %s | llvm-readobj -s -t | FileCheck %s
1 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -s -t | FileCheck %s
0 // RUN: llvm-mc -triple i386-pc-win32 -filetype=obj %s | llvm-readobj -S -t | FileCheck %s
1 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -S -t | FileCheck %s
22
33 .section assocSec, "dr", discard, "assocSym"
44 .global assocSym
44 // (8, 999999]: base 10 string table index (/9999999)
55 // (999999, 0xFFFFFFFF]: base 64 string table index (//AAAAAA)
66 //
7 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -s | FileCheck %s
7 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -S | FileCheck %s
88
99 // Raw encoding
1010
None // RUN: llvm-mc -triple i386-pc-win32 -filetype=obj %s | llvm-readobj -s | FileCheck %s
1 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -s | FileCheck %s
0 // RUN: llvm-mc -triple i386-pc-win32 -filetype=obj %s | llvm-readobj -S | FileCheck %s
1 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -S | FileCheck %s
22
33 .section .foo$bar; .long 1
44 .section .foo@bar; .long 1
0 // This test checks the alignment and padding of the unwind info.
11
2 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -s -sd -sr -u | FileCheck %s
2 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -S --sd --sr -u | FileCheck %s
33
44 // CHECK: Sections [
55 // CHECK: Section {
0 // This test checks the alignment and padding of the unwind info.
11
2 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -s -sd -sr -u | FileCheck %s
2 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -S --sd --sr -u | FileCheck %s
33
44 // CHECK: Sections [
55 // CHECK: Section {
0 // This test checks the alignment and padding of the unwind info.
11
2 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -s -sd -sr -u | FileCheck %s
2 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -S --sd --sr -u | FileCheck %s
33
44 // CHECK: Sections [
55 // CHECK: Section {
None // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -sections -section-symbols | FileCheck %s
0 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj --sections --section-symbols | FileCheck %s
11
22 .text
33 .def weak_func;
None # RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj -symbols | FileCheck %s
0 # RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj --symbols | FileCheck %s
11
22 # This assembly should make an object with two .text sections, two .xdata
33 # sections, and two .pdata sections.
0 // This test ensures functions in custom sections get unwind info emitted in a
11 // distinct .xdata section.
2 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj -s -sd | FileCheck %s
2 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj -S --sd | FileCheck %s
33
44 // CHECK: Name: .xdata
55 // CHECK-NEXT: VirtualSize
0 // This test checks that the SEH directives emit the correct unwind data.
11
2 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -s -u -r | FileCheck %s
2 // RUN: llvm-mc -triple x86_64-pc-win32 -filetype=obj %s | llvm-readobj -S -u -r | FileCheck %s
33
44 // CHECK: Sections [
55 // CHECK: Section {
11 // references to functions. Failing to do so might cause pointer-to-function
22 // equality to fail if /INCREMENTAL links are used.
33
4 // RUN: llvm-mc -filetype=obj -incremental-linker-compatible -triple i686-pc-win32 %s | llvm-readobj -s | FileCheck %s
5 // RUN: llvm-mc -filetype=obj -incremental-linker-compatible -triple x86_64-pc-win32 %s | llvm-readobj -s | FileCheck %s
4 // RUN: llvm-mc -filetype=obj -incremental-linker-compatible -triple i686-pc-win32 %s | llvm-readobj -S | FileCheck %s
5 // RUN: llvm-mc -filetype=obj -incremental-linker-compatible -triple x86_64-pc-win32 %s | llvm-readobj -S | FileCheck %s
66
77 .def _foo;
88 .scl 2;
0 // The purpose of this test is to see if the COFF object writer is emitting the
11 // proper relocations for multiple pieces of data in a single data fragment.
22
3 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj -h -s -sr -sd -t | FileCheck %s
3 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s | llvm-readobj -h -S --sr --sd -t | FileCheck %s
44
55 .def _main;
66 .scl 2;
0 // The purpose of this test is to see if the COFF object writer is emitting the
11 // proper relocations for multiple pieces of data in a single data fragment.
22
3 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -h -s -sr -sd -t | FileCheck %s
3 // RUN: llvm-mc -filetype=obj -triple i686-pc-win32 %s | llvm-readobj -h -S --sr --sd -t | FileCheck %s
44
55 .def _main;
66 .scl 2;
None // RUN: llvm-mc -filetype=obj -triple arm-eabi %s -o - | llvm-readobj -s -t | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple arm-eabi %s -o - | llvm-readobj -S -t | FileCheck %s
11 // Test that global variables and functions are assigned correct section.
22 .text
33 .syntax unified
0 // RUN: llvm-mc -filetype=obj -triple thumbv7m-arm-linux-gnu %s -o - \
1 // RUN: | llvm-readobj -s -t | FileCheck %s
1 // RUN: | llvm-readobj -S -t | FileCheck %s
22
33 .text
44 bx lr
0 // RUN: llvm-mc -filetype=obj -triple thumbv7m-arm-linux-gnu %s -o - \
1 // RUN: | llvm-readobj -s -t | FileCheck %s
1 // RUN: | llvm-readobj -S -t | FileCheck %s
22
33 .section .text,"axy",%progbits,unique,0
44 .globl foo
0 // RUN: llvm-mc -filetype=obj -triple thumbv7m-arm-linux-gnu %s -o - \
1 // RUN: | llvm-readobj -s -t | FileCheck %s
1 // RUN: | llvm-readobj -S -t | FileCheck %s
22
33 .text
44 .ascii "test"
0 // RUN: llvm-mc -filetype=asm -triple x86_64-pc-linux-gnu %s -o - | FileCheck --check-prefix=ASM %s
1 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | llvm-readobj -s -t -sd -addrsig | FileCheck %s
2 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -split-dwarf-file %t.dwo -o - | llvm-readobj -s -t -sd -addrsig | FileCheck %s
3 // RUN: llvm-readobj -s %t.dwo | FileCheck --check-prefix=DWO %s
1 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | llvm-readobj -S -t --sd --addrsig | FileCheck %s
2 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -split-dwarf-file %t.dwo -o - | llvm-readobj -S -t --sd --addrsig | FileCheck %s
3 // RUN: llvm-readobj -S %t.dwo | FileCheck --check-prefix=DWO %s
44
55 // CHECK: Name: .llvm_addrsig
66 // CHECK-NEXT: Type: SHT_LLVM_ADDRSIG (0x6FFF4C03)
None // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | llvm-readobj -s | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | llvm-readobj -S | FileCheck %s
11
22 // Test that the bss section is correctly aligned
33
None // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu -mcpu=pentiumpro %s -o - | llvm-readobj -s -sd | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu -mcpu=pentiumpro %s -o - | llvm-readobj -S --sd | FileCheck %s
11
22 // Test that we get optimal nops in text
33 .text
None // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | llvm-readobj -s | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | llvm-readobj -S | FileCheck %s
11
22 // Test that the alignment does contribute to the size of the section.
33
None // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | llvm-readobj -s | FileCheck %s
0 // RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | llvm-readobj -S | FileCheck %s