brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.1 KiB · 276c6da Raw
60 lines · python
1# UNSUPPORTED: expensive_checks, debug2 3# RUN: %python %s > %t.ll4# RUN: llc -mtriple powerpc-ibm-aix-xcoff -code-model=small -mcpu=pwr7 -mattr=-altivec -O0 < %t.ll | \5# RUN:   FileCheck --check-prefix=ASM32 %s6 7# RUN: llc -mtriple powerpc64-ibm-aix-xcoff -code-model=small -mcpu=pwr7 -mattr=-altivec -O0 < %t.ll | \8# RUN:   FileCheck --check-prefix=ASM64 %s9 10# RUN: llc -mtriple powerpc-ibm-aix-xcoff -code-model=small -mcpu=pwr7 -mattr=-altivec -O0 \11# RUN:     -filetype=obj -o %t.o < %t.ll12# RUN: llvm-objdump --no-print-imm-hex -D -r --symbol-description %t.o | FileCheck -D#NFA=2 --check-prefix=DIS32 %s13 14# RUN: llc -mtriple powerpc64-ibm-aix-xcoff -code-model=small -mcpu=pwr7 -mattr=-altivec -O0 \15# RUN:     -filetype=obj -o %t.o < %t.ll16# RUN: llvm-objdump --no-print-imm-hex -D -r --symbol-description %t.o | FileCheck -D#NFA=2 --check-prefix=DIS64 %s17 18numentries = 819519for x in range(0, numentries):20    print("@a%d = global i32 0, align 4 #0" % (x))21 22print("define void @foo() {")23print("entry:")24for x in range(0, numentries):25    print("store i32 1, i32* @a%d, align 4" % (x))26print("ret void")27print("}")28 29print('attributes #0 = { "toc-data" }')30 31# 32-bit assembly check32# ASM32:  la 4, a0[TD](2)33# ASM32:  la 4, a1[TD](2)34 35# ASM32:  la 4, a8191[TD](2)36# ASM32:  la 4, a8192[TD](2)37# ASM32:  la 4, a8193[TD](2)38 39# 64-bit assembly check40# ASM64:  la 4, a0[TD](2)41# ASM64:  la 4, a1[TD](2)42 43# ASM64:  la 4, a8191[TD](2)44# ASM64:  la 4, a8192[TD](2)45# ASM64:  la 4, a8193[TD](2)46 47# DIS32:    fffc: 38 82 7f fc   addi 4, 2, 3276448# DIS32:      0000fffe:  R_TOC  (idx: [[#NFA+16391]]) a8191[TD]49# DIS32:   10004: 38 82 80 00   addi 4, 2, -3276850# DIS32:      00010006:  R_TOC  (idx: [[#NFA+16393]]) a8192[TD]51# DIS32:   1000c: 38 82 80 04   addi 4, 2, -3276452# DIS32:      0001000e:  R_TOC  (idx: [[#NFA+16395]]) a8193[TD]53 54# DIS64:    fffc: 38 82 7f fc   addi 4, 2, 3276455# DIS64:      0000fffe:  R_TOC  (idx: [[#NFA+16391]]) a8191[TD]56# DIS64:   10004: 38 82 80 00   addi 4, 2, -3276857# DIS64:      00010006:  R_TOC  (idx: [[#NFA+16393]]) a8192[TD]58# DIS64:   1000c: 38 82 80 04   addi 4, 2, -3276459# DIS64:      0001000e:  R_TOC  (idx: [[#NFA+16395]]) a8193[TD]60