------- Comment #5 from howarth at nitro dot med dot uc dot edu 2010-09-01
23:17 -------
The code generate IS random. I repeatedly execute...
/Users/howarth/darwin_objdir/gcc/xgcc -B/Users/howarth/darwin_objdir/gcc/
/Users/howarth/gcc/gcc/testsuite/gcc.c-torture/execute/builtins/sprintf-chk.c
/Users/howarth/gcc/gcc/testsuite/gcc.c-torture/execute/builtins/sprintf-chk-lib.c
/Users/howarth/gcc/gcc/testsuite/gcc.c-torture/execute/builtins/lib/main.c -w
-Os -lm -m32 --save-temps -o
/Users/howarth/darwin_objdir/gcc/testsuite/gcc/sprintf-chk.x7
in individual directories and diff there contents, eventually I get this...
--- pr45484/sprintf-chk.s 2010-09-01 19:13:24.000000000 -0400
+++ pr45484_2/sprintf-chk.s 2010-09-01 19:14:11.000000000 -0400
@@ -776,7 +776,6 @@
LCFI191:
call _abort
L56:
-LCFI192:
call ___i686.get_pc_thunk.bx
L57:
addl $24, %ebp
@@ -785,34 +784,33 @@
movl $0, (%eax)
leal -12(%ebp), %esp
popl %ebx
-LCFI193:
+LCFI192:
popl %esi
-LCFI194:
+LCFI193:
popl %edi
-LCFI195:
+LCFI194:
popl %ebp
-LCFI196:
+LCFI195:
ret
-LCFI197:
L73:
-LCFI198:
+LCFI196:
addl $32, %esp
-LCFI199:
+LCFI197:
call _abort
LFE2:
.globl _main_test
_main_test:
LFB3:
pushl %ebp
-LCFI200:
+LCFI198:
movl %esp, %ebp
-LCFI201:
+LCFI199:
pushl %ebx
-LCFI202:
+LCFI200:
call ___i686.get_pc_thunk.bx
L00000000004$pb:
subl $4, %esp
-LCFI203:
+LCFI201:
movl _s2-L00000000004$pb(%ebx), %eax
leal _p-L00000000004$pb(%ebx), %edx
movl %eax, _s2-L00000000004$pb(%ebx)
@@ -825,11 +823,11 @@
call _test1
call _test2
popl %eax
-LCFI204:
+LCFI202:
popl %ebx
-LCFI205:
+LCFI203:
popl %ebp
-LCFI206:
+LCFI204:
jmp _test3
LFE3:
.globl _ptr
@@ -1855,74 +1853,62 @@
.byte 0x4
.set L$set$189,LCFI192-LCFI190
.long L$set$189
- .byte 0x2e
- .byte 0x8
+ .byte 0xa
+ .byte 0xc3
.byte 0x4
.set L$set$190,LCFI193-LCFI192
.long L$set$190
- .byte 0xa
- .byte 0xc3
+ .byte 0xc6
.byte 0x4
.set L$set$191,LCFI194-LCFI193
.long L$set$191
- .byte 0xc6
+ .byte 0xc7
.byte 0x4
.set L$set$192,LCFI195-LCFI194
.long L$set$192
- .byte 0xc7
- .byte 0x4
- .set L$set$193,LCFI196-LCFI195
- .long L$set$193
.byte 0xc
.byte 0x5
.byte 0x4
.byte 0xc4
.byte 0x4
- .set L$set$194,LCFI197-LCFI196
- .long L$set$194
- .byte 0x13
- .byte 0x1
- .byte 0x2e
- .byte 0
- .byte 0x4
- .set L$set$195,LCFI198-LCFI197
- .long L$set$195
+ .set L$set$193,LCFI196-LCFI195
+ .long L$set$193
.byte 0xb
.align 2
LEFDE5:
LSFDE7:
- .set L$set$196,LEFDE7-LASFDE7
- .long L$set$196
+ .set L$set$194,LEFDE7-LASFDE7
+ .long L$set$194
LASFDE7:
.long LASFDE7-EH_frame1
.long LFB3-.
- .set L$set$197,LFE3-LFB3
- .long L$set$197
+ .set L$set$195,LFE3-LFB3
+ .long L$set$195
.byte 0
.byte 0x4
- .set L$set$198,LCFI200-LFB3
- .long L$set$198
+ .set L$set$196,LCFI198-LFB3
+ .long L$set$196
.byte 0xe
.byte 0x8
.byte 0x84
.byte 0x2
.byte 0x4
- .set L$set$199,LCFI201-LCFI200
- .long L$set$199
+ .set L$set$197,LCFI199-LCFI198
+ .long L$set$197
.byte 0xd
.byte 0x4
.byte 0x4
- .set L$set$200,LCFI202-LCFI201
- .long L$set$200
+ .set L$set$198,LCFI200-LCFI199
+ .long L$set$198
.byte 0x83
.byte 0x3
.byte 0x4
- .set L$set$201,LCFI205-LCFI202
- .long L$set$201
+ .set L$set$199,LCFI203-LCFI200
+ .long L$set$199
.byte 0xc3
.byte 0x4
- .set L$set$202,LCFI206-LCFI205
- .long L$set$202
+ .set L$set$200,LCFI204-LCFI203
+ .long L$set$200
.byte 0xc
.byte 0x5
.byte 0x4
@@ -1930,13 +1916,13 @@
.align 2
LEFDE7:
LSFDE9:
- .set L$set$203,LEFDE9-LASFDE9
- .long L$set$203
+ .set L$set$201,LEFDE9-LASFDE9
+ .long L$set$201
LASFDE9:
.long LASFDE9-EH_frame1
.long LFB4-.
- .set L$set$204,LFE4-LFB4
- .long L$set$204
+ .set L$set$202,LFE4-LFB4
+ .long L$set$202
.byte 0
.align 2
LEFDE9:
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45484