aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/SystemZ/frame-15.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/SystemZ/frame-15.ll')
-rw-r--r--test/CodeGen/SystemZ/frame-15.ll150
1 files changed, 75 insertions, 75 deletions
diff --git a/test/CodeGen/SystemZ/frame-15.ll b/test/CodeGen/SystemZ/frame-15.ll
index bc87e174d0..af804da82c 100644
--- a/test/CodeGen/SystemZ/frame-15.ll
+++ b/test/CodeGen/SystemZ/frame-15.ll
@@ -19,9 +19,9 @@ declare void @foo(float *%ptr1, float *%ptr2)
; First check the highest in-range offset after conversion, which is 4092
; for word-addressing instructions like LDEB.
;
-; The last in-range doubleword offset is 4088. Since the frame has an
-; emergency spill slot at 160(%r15), the amount that we need to allocate
-; in order to put another object at offset 4088 is (4088 - 168) / 4 = 980
+; The last in-range doubleword offset is 4088. Since the frame has two
+; emergency spill slots at 160(%r15), the amount that we need to allocate
+; in order to put another object at offset 4088 is (4088 - 176) / 4 = 978
; words.
define void @f1(double *%dst) {
; CHECK-NOFP: f1:
@@ -31,13 +31,13 @@ define void @f1(double *%dst) {
; CHECK-FP: f1:
; CHECK-FP: ldeb {{%f[0-7]}}, 4092(%r11)
; CHECK-FP: br %r14
- %region1 = alloca [980 x float], align 8
- %region2 = alloca [980 x float], align 8
- %start1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [978 x float], align 8
+ %region2 = alloca [978 x float], align 8
+ %start1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 1
- %ptr2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 1
+ %ptr1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 1
+ %ptr2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 1
%float1 = load float *%ptr1
%float2 = load float *%ptr2
%double1 = fpext float %float1 to double
@@ -58,13 +58,13 @@ define void @f2(double *%dst) {
; CHECK-FP: lghi %r1, 4096
; CHECK-FP: ldeb {{%f[0-7]}}, 0(%r1,%r11)
; CHECK-FP: br %r14
- %region1 = alloca [980 x float], align 8
- %region2 = alloca [980 x float], align 8
- %start1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [978 x float], align 8
+ %region2 = alloca [978 x float], align 8
+ %start1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 2
- %ptr2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 2
+ %ptr1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 2
+ %ptr2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 2
%float1 = load float *%ptr1
%float2 = load float *%ptr2
%double1 = fpext float %float1 to double
@@ -85,13 +85,13 @@ define void @f3(double *%dst) {
; CHECK-FP: lghi %r1, 4096
; CHECK-FP: ldeb {{%f[0-7]}}, 4(%r1,%r11)
; CHECK-FP: br %r14
- %region1 = alloca [980 x float], align 8
- %region2 = alloca [980 x float], align 8
- %start1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [978 x float], align 8
+ %region2 = alloca [978 x float], align 8
+ %start1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 3
- %ptr2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 3
+ %ptr1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 3
+ %ptr2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 3
%float1 = load float *%ptr1
%float2 = load float *%ptr2
%double1 = fpext float %float1 to double
@@ -112,13 +112,13 @@ define void @f4(double *%dst) {
; CHECK-FP: lghi %r1, 4096
; CHECK-FP: ldeb {{%f[0-7]}}, 4092(%r1,%r11)
; CHECK-FP: br %r14
- %region1 = alloca [2004 x float], align 8
- %region2 = alloca [2004 x float], align 8
- %start1 = getelementptr inbounds [2004 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [2004 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [2002 x float], align 8
+ %region2 = alloca [2002 x float], align 8
+ %start1 = getelementptr inbounds [2002 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [2002 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [2004 x float]* %region1, i64 0, i64 1
- %ptr2 = getelementptr inbounds [2004 x float]* %region2, i64 0, i64 1
+ %ptr1 = getelementptr inbounds [2002 x float]* %region1, i64 0, i64 1
+ %ptr2 = getelementptr inbounds [2002 x float]* %region2, i64 0, i64 1
%float1 = load float *%ptr1
%float2 = load float *%ptr2
%double1 = fpext float %float1 to double
@@ -139,13 +139,13 @@ define void @f5(double *%dst) {
; CHECK-FP: lghi %r1, 8192
; CHECK-FP: ldeb {{%f[0-7]}}, 0(%r1,%r11)
; CHECK-FP: br %r14
- %region1 = alloca [2004 x float], align 8
- %region2 = alloca [2004 x float], align 8
- %start1 = getelementptr inbounds [2004 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [2004 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [2002 x float], align 8
+ %region2 = alloca [2002 x float], align 8
+ %start1 = getelementptr inbounds [2002 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [2002 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [2004 x float]* %region1, i64 0, i64 2
- %ptr2 = getelementptr inbounds [2004 x float]* %region2, i64 0, i64 2
+ %ptr1 = getelementptr inbounds [2002 x float]* %region1, i64 0, i64 2
+ %ptr2 = getelementptr inbounds [2002 x float]* %region2, i64 0, i64 2
%float1 = load float *%ptr1
%float2 = load float *%ptr2
%double1 = fpext float %float1 to double
@@ -166,13 +166,13 @@ define void @f6(double *%dst) {
; CHECK-FP: lghi %r1, 8192
; CHECK-FP: ldeb {{%f[0-7]}}, 4(%r1,%r11)
; CHECK-FP: br %r14
- %region1 = alloca [2004 x float], align 8
- %region2 = alloca [2004 x float], align 8
- %start1 = getelementptr inbounds [2004 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [2004 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [2002 x float], align 8
+ %region2 = alloca [2002 x float], align 8
+ %start1 = getelementptr inbounds [2002 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [2002 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [2004 x float]* %region1, i64 0, i64 3
- %ptr2 = getelementptr inbounds [2004 x float]* %region2, i64 0, i64 3
+ %ptr1 = getelementptr inbounds [2002 x float]* %region1, i64 0, i64 3
+ %ptr2 = getelementptr inbounds [2002 x float]* %region2, i64 0, i64 3
%float1 = load float *%ptr1
%float2 = load float *%ptr2
%double1 = fpext float %float1 to double
@@ -183,7 +183,7 @@ define void @f6(double *%dst) {
}
; Now try an offset of 4092 from the start of the object, with the object
-; being at offset 8192. This time we need objects of (8192 - 168) / 4 = 2006
+; being at offset 8192. This time we need objects of (8192 - 168) / 4 = 2004
; words.
define void @f7(double *%dst) {
; CHECK-NOFP: f7:
@@ -195,13 +195,13 @@ define void @f7(double *%dst) {
; CHECK-FP: lghi %r1, 8192
; CHECK-FP: ldeb {{%f[0-7]}}, 4092(%r1,%r11)
; CHECK-FP: br %r14
- %region1 = alloca [2006 x float], align 8
- %region2 = alloca [2006 x float], align 8
- %start1 = getelementptr inbounds [2006 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [2006 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [2004 x float], align 8
+ %region2 = alloca [2004 x float], align 8
+ %start1 = getelementptr inbounds [2004 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [2004 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [2006 x float]* %region1, i64 0, i64 1023
- %ptr2 = getelementptr inbounds [2006 x float]* %region2, i64 0, i64 1023
+ %ptr1 = getelementptr inbounds [2004 x float]* %region1, i64 0, i64 1023
+ %ptr2 = getelementptr inbounds [2004 x float]* %region2, i64 0, i64 1023
%float1 = load float *%ptr1
%float2 = load float *%ptr2
%double1 = fpext float %float1 to double
@@ -223,13 +223,13 @@ define void @f8(double *%dst) {
; CHECK-FP: lghi %r1, 12288
; CHECK-FP: ldeb {{%f[0-7]}}, 4(%r1,%r11)
; CHECK-FP: br %r14
- %region1 = alloca [2008 x float], align 8
- %region2 = alloca [2008 x float], align 8
- %start1 = getelementptr inbounds [2008 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [2008 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [2006 x float], align 8
+ %region2 = alloca [2006 x float], align 8
+ %start1 = getelementptr inbounds [2006 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [2006 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [2008 x float]* %region1, i64 0, i64 1023
- %ptr2 = getelementptr inbounds [2008 x float]* %region2, i64 0, i64 1023
+ %ptr1 = getelementptr inbounds [2006 x float]* %region1, i64 0, i64 1023
+ %ptr2 = getelementptr inbounds [2006 x float]* %region2, i64 0, i64 1023
%float1 = load float *%ptr1
%float2 = load float *%ptr2
%double1 = fpext float %float1 to double
@@ -252,13 +252,13 @@ define void @f9(double *%dst) {
; CHECK-FP: lay %r1, 12296(%r11)
; CHECK-FP: ldeb {{%f[0-7]}}, 0(%r1)
; CHECK-FP: br %r14
- %region1 = alloca [2008 x float], align 8
- %region2 = alloca [2008 x float], align 8
- %start1 = getelementptr inbounds [2008 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [2008 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [2006 x float], align 8
+ %region2 = alloca [2006 x float], align 8
+ %start1 = getelementptr inbounds [2006 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [2006 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [2008 x float]* %region1, i64 0, i64 1024
- %ptr2 = getelementptr inbounds [2008 x float]* %region2, i64 0, i64 1024
+ %ptr1 = getelementptr inbounds [2006 x float]* %region1, i64 0, i64 1024
+ %ptr2 = getelementptr inbounds [2006 x float]* %region2, i64 0, i64 1024
%float1 = load float *%ptr1
%float2 = load float *%ptr2
%double1 = fpext float %float1 to double
@@ -268,31 +268,31 @@ define void @f9(double *%dst) {
ret void
}
-; Repeat f2 in a case that needs the emergency spill slot, because all
+; Repeat f2 in a case that needs the emergency spill slots, because all
; call-clobbered and allocated call-saved registers are live. Note that
; %vptr and %dst are copied to call-saved registers, freeing up %r2 and
; %r3 during the main test.
define void @f10(i32 *%vptr, double *%dst) {
; CHECK-NOFP: f10:
-; CHECK-NOFP: stg [[REGISTER:%r[1-9][0-4]?]], 160(%r15)
+; CHECK-NOFP: stg [[REGISTER:%r[1-9][0-4]?]], [[OFFSET:160|168]](%r15)
; CHECK-NOFP: lghi [[REGISTER]], 4096
; CHECK-NOFP: ldeb {{%f[0-7]}}, 0([[REGISTER]],%r15)
-; CHECK-NOFP: lg [[REGISTER]], 160(%r15)
+; CHECK-NOFP: lg [[REGISTER]], [[OFFSET]](%r15)
; CHECK-NOFP: br %r14
;
; CHECK-FP: f10:
-; CHECK-FP: stg [[REGISTER:%r[1-9][0-4]?]], 160(%r11)
+; CHECK-FP: stg [[REGISTER:%r[1-9][0-4]?]], [[OFFSET:160|168]](%r11)
; CHECK-FP: lghi [[REGISTER]], 4096
; CHECK-FP: ldeb {{%f[0-7]}}, 0([[REGISTER]],%r11)
-; CHECK-FP: lg [[REGISTER]], 160(%r11)
+; CHECK-FP: lg [[REGISTER]], [[OFFSET]](%r11)
; CHECK-FP: br %r14
- %region1 = alloca [980 x float], align 8
- %region2 = alloca [980 x float], align 8
- %start1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [978 x float], align 8
+ %region2 = alloca [978 x float], align 8
+ %start1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %ptr1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 2
- %ptr2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 2
+ %ptr1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 2
+ %ptr2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 2
%i0 = load volatile i32 *%vptr
%i1 = load volatile i32 *%vptr
%i2 = load volatile i32 *%vptr
@@ -329,13 +329,13 @@ define void @f11(double *%dst, i64 %index) {
; CHECK-FP: lay %r1, 4096(%r11)
; CHECK-FP: ldeb {{%f[0-7]}}, 0([[REGISTER]],%r1)
; CHECK-FP: br %r14
- %region1 = alloca [980 x float], align 8
- %region2 = alloca [980 x float], align 8
- %start1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 0
- %start2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 0
+ %region1 = alloca [978 x float], align 8
+ %region2 = alloca [978 x float], align 8
+ %start1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 0
+ %start2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 0
call void @foo(float *%start1, float *%start2)
- %elem1 = getelementptr inbounds [980 x float]* %region1, i64 0, i64 2
- %elem2 = getelementptr inbounds [980 x float]* %region2, i64 0, i64 2
+ %elem1 = getelementptr inbounds [978 x float]* %region1, i64 0, i64 2
+ %elem2 = getelementptr inbounds [978 x float]* %region2, i64 0, i64 2
%base1 = ptrtoint float *%elem1 to i64
%base2 = ptrtoint float *%elem2 to i64
%addr1 = add i64 %base1, %index