define i32 @length2(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length2:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $2, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $2
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i1 @length2_eq_nobuiltin_attr(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length2_eq_nobuiltin_attr:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $2, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $2
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: sete %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length2_eq_nobuiltin_attr:
define i32 @length3(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length3:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $3, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $3
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i1 @length3_eq(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length3_eq:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $3, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $3
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: setne %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length3_eq:
define i32 @length4(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length4:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $4, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $4
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i32 @length5(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length5:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $5, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $5
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i1 @length5_eq(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length5_eq:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $5, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $5
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: setne %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length5_eq:
define i32 @length8(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length8:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $8, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $8
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i1 @length8_eq(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length8_eq:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $8, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $8
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: sete %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length8_eq:
define i1 @length8_eq_const(i8* %X) nounwind minsize {
; X86-LABEL: length8_eq_const:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $8, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $.L.str, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $8
+; X86-NEXT: pushl $.L.str
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: setne %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length8_eq_const:
define i1 @length12_eq(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length12_eq:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $12, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $12
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: setne %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length12_eq:
define i32 @length12(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length12:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $12, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $12
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i32 @length16(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length16:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $16, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $16
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i1 @length16_eq(i8* %x, i8* %y) nounwind minsize {
; X86-NOSSE-LABEL: length16_eq:
; X86-NOSSE: # BB#0:
-; X86-NOSSE-NEXT: subl $16, %esp
-; X86-NOSSE-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NOSSE-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NOSSE-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NOSSE-NEXT: movl %eax, (%esp)
-; X86-NOSSE-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NOSSE-NEXT: movl $16, {{[0-9]+}}(%esp)
+; X86-NOSSE-NEXT: pushl $0
+; X86-NOSSE-NEXT: pushl $16
+; X86-NOSSE-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NOSSE-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NOSSE-NEXT: calll memcmp
+; X86-NOSSE-NEXT: addl $16, %esp
; X86-NOSSE-NEXT: testl %eax, %eax
; X86-NOSSE-NEXT: setne %al
-; X86-NOSSE-NEXT: addl $16, %esp
; X86-NOSSE-NEXT: retl
;
; X86-SSE2-LABEL: length16_eq:
define i1 @length16_eq_const(i8* %X) nounwind minsize {
; X86-NOSSE-LABEL: length16_eq_const:
; X86-NOSSE: # BB#0:
-; X86-NOSSE-NEXT: subl $16, %esp
-; X86-NOSSE-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NOSSE-NEXT: movl %eax, (%esp)
-; X86-NOSSE-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NOSSE-NEXT: movl $16, {{[0-9]+}}(%esp)
-; X86-NOSSE-NEXT: movl $.L.str, {{[0-9]+}}(%esp)
+; X86-NOSSE-NEXT: pushl $0
+; X86-NOSSE-NEXT: pushl $16
+; X86-NOSSE-NEXT: pushl $.L.str
+; X86-NOSSE-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NOSSE-NEXT: calll memcmp
+; X86-NOSSE-NEXT: addl $16, %esp
; X86-NOSSE-NEXT: testl %eax, %eax
; X86-NOSSE-NEXT: sete %al
-; X86-NOSSE-NEXT: addl $16, %esp
; X86-NOSSE-NEXT: retl
;
; X86-SSE2-LABEL: length16_eq_const:
define i32 @length24(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length24:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $24, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $24
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i1 @length24_eq(i8* %x, i8* %y) nounwind minsize {
; X86-LABEL: length24_eq:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $24, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $24
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: sete %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length24_eq:
define i1 @length24_eq_const(i8* %X) nounwind minsize {
; X86-LABEL: length24_eq_const:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $24, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $.L.str, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $24
+; X86-NEXT: pushl $.L.str
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: setne %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length24_eq_const:
define i32 @length32(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length32:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $32, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $32
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i1 @length32_eq(i8* %x, i8* %y) nounwind minsize {
; X86-LABEL: length32_eq:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $32, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $32
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: sete %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-SSE2-LABEL: length32_eq:
define i1 @length32_eq_const(i8* %X) nounwind minsize {
; X86-LABEL: length32_eq_const:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $32, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $.L.str, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $32
+; X86-NEXT: pushl $.L.str
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: setne %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-SSE2-LABEL: length32_eq_const:
define i32 @length64(i8* %X, i8* %Y) nounwind minsize {
; X86-LABEL: length64:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $64, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $64
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
define i1 @length64_eq(i8* %x, i8* %y) nounwind minsize {
; X86-LABEL: length64_eq:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
-; X86-NEXT: movl %ecx, {{[0-9]+}}(%esp)
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $64, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $64
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: setne %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length64_eq:
define i1 @length64_eq_const(i8* %X) nounwind minsize {
; X86-LABEL: length64_eq_const:
; X86: # BB#0:
-; X86-NEXT: subl $16, %esp
-; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
-; X86-NEXT: movl %eax, (%esp)
-; X86-NEXT: andl $0, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $64, {{[0-9]+}}(%esp)
-; X86-NEXT: movl $.L.str, {{[0-9]+}}(%esp)
+; X86-NEXT: pushl $0
+; X86-NEXT: pushl $64
+; X86-NEXT: pushl $.L.str
+; X86-NEXT: pushl {{[0-9]+}}(%esp)
; X86-NEXT: calll memcmp
+; X86-NEXT: addl $16, %esp
; X86-NEXT: testl %eax, %eax
; X86-NEXT: sete %al
-; X86-NEXT: addl $16, %esp
; X86-NEXT: retl
;
; X64-LABEL: length64_eq_const:
declare x86_thiscallcc void @thiscall(%class.Class* %class, i32 %a, i32 %b, i32 %c, i32 %d)
declare void @oneparam(i32 %a)
declare void @eightparams(i32 %a, i32 %b, i32 %c, i32 %d, i32 %e, i32 %f, i32 %g, i32 %h)
+declare void @eightparams16(i16 %a, i16 %b, i16 %c, i16 %d, i16 %e, i16 %f, i16 %g, i16 %h)
+declare void @eightparams64(i64 %a, i64 %b, i64 %c, i64 %d, i64 %e, i64 %f, i64 %g, i64 %h)
declare void @struct(%struct.s* byval %a, i32 %b, i32 %c, i32 %d)
declare void @inalloca(<{ %struct.s }>* inalloca)
call void @B_func(%struct.B* sret %tmp, %struct.B* %ref.tmp, i32 1)
ret void
}
+
+; NORMAL-LABEL: pr34863_16
+; NORMAL: movl 4(%esp), %eax
+; NORMAL-NEXT: pushl $65535
+; NORMAL-NEXT: pushl $0
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: calll _eightparams16
+; NORMAL-NEXT: addl $32, %esp
+;
+; NOPUSH-LABEL: pr34863_16
+; NOPUSH: subl $32, %esp
+; NOPUSH-NEXT: movl 36(%esp), %eax
+; NOPUSH-NEXT: movl %eax, 20(%esp)
+; NOPUSH-NEXT: movl %eax, 16(%esp)
+; NOPUSH-NEXT: movl %eax, 12(%esp)
+; NOPUSH-NEXT: movl %eax, 8(%esp)
+; NOPUSH-NEXT: movl %eax, 4(%esp)
+; NOPUSH-NEXT: movl %eax, (%esp)
+; NOPUSH-NEXT: movl $65535, 28(%esp)
+; NOPUSH-NEXT: andl $0, 24(%esp)
+; NOPUSH-NEXT: calll _eightparams16
+; NOPUSH-NEXT: addl $32, %esp
+define void @pr34863_16(i16 %x) minsize nounwind {
+entry:
+ tail call void @eightparams16(i16 %x, i16 %x, i16 %x, i16 %x, i16 %x, i16 %x, i16 0, i16 -1)
+ ret void
+}
+
+; NORMAL-LABEL: pr34863_32
+; NORMAL: movl 4(%esp), %eax
+; NORMAL-NEXT: pushl $-1
+; NORMAL-NEXT: pushl $0
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: calll _eightparams
+; NORMAL-NEXT: addl $32, %esp
+;
+; NOPUSH-LABEL: pr34863_32
+; NOPUSH: subl $32, %esp
+; NOPUSH-NEXT: movl 36(%esp), %eax
+; NOPUSH-NEXT: movl %eax, 20(%esp)
+; NOPUSH-NEXT: movl %eax, 16(%esp)
+; NOPUSH-NEXT: movl %eax, 12(%esp)
+; NOPUSH-NEXT: movl %eax, 8(%esp)
+; NOPUSH-NEXT: movl %eax, 4(%esp)
+; NOPUSH-NEXT: movl %eax, (%esp)
+; NOPUSH-NEXT: orl $-1, 28(%esp)
+; NOPUSH-NEXT: andl $0, 24(%esp)
+; NOPUSH-NEXT: calll _eightparams
+; NOPUSH-NEXT: addl $32, %esp
+define void @pr34863_32(i32 %x) minsize nounwind {
+entry:
+ tail call void @eightparams(i32 %x, i32 %x, i32 %x, i32 %x, i32 %x, i32 %x, i32 0, i32 -1)
+ ret void
+}
+
+; NORMAL-LABEL: pr34863_64
+; NORMAL: movl 4(%esp), %eax
+; NORMAL-NEXT: movl 8(%esp), %ecx
+; NORMAL-NEXT: pushl $-1
+; NORMAL-NEXT: pushl $-1
+; NORMAL-NEXT: pushl $0
+; NORMAL-NEXT: pushl $0
+; NORMAL-NEXT: pushl %ecx
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %ecx
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %ecx
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %ecx
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %ecx
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: pushl %ecx
+; NORMAL-NEXT: pushl %eax
+; NORMAL-NEXT: calll _eightparams64
+; NORMAL-NEXT: addl $64, %esp
+;
+; NOPUSH-LABEL: pr34863_64
+; NOPUSH: subl $64, %esp
+; NOPUSH-NEXT: movl 68(%esp), %eax
+; NOPUSH-NEXT: movl 72(%esp), %ecx
+; NOPUSH-NEXT: movl %ecx, 44(%esp)
+; NOPUSH-NEXT: movl %eax, 40(%esp)
+; NOPUSH-NEXT: movl %ecx, 36(%esp)
+; NOPUSH-NEXT: movl %eax, 32(%esp)
+; NOPUSH-NEXT: movl %ecx, 28(%esp)
+; NOPUSH-NEXT: movl %eax, 24(%esp)
+; NOPUSH-NEXT: movl %ecx, 20(%esp)
+; NOPUSH-NEXT: movl %eax, 16(%esp)
+; NOPUSH-NEXT: movl %ecx, 12(%esp)
+; NOPUSH-NEXT: movl %eax, 8(%esp)
+; NOPUSH-NEXT: movl %ecx, 4(%esp)
+; NOPUSH-NEXT: movl %eax, (%esp)
+; NOPUSH-NEXT: orl $-1, 60(%esp)
+; NOPUSH-NEXT: orl $-1, 56(%esp)
+; NOPUSH-NEXT: andl $0, 52(%esp)
+; NOPUSH-NEXT: andl $0, 48(%esp)
+; NOPUSH-NEXT: calll _eightparams64
+; NOPUSH-NEXT: addl $64, %esp
+define void @pr34863_64(i64 %x) minsize nounwind {
+entry:
+ tail call void @eightparams64(i64 %x, i64 %x, i64 %x, i64 %x, i64 %x, i64 %x, i64 0, i64 -1)
+ ret void
+}