lkml.org 
[lkml]   [2005]   [Oct]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [2.6] binfmt_elf bug (exposed by klibc).
Date
From
Paweł Sikora <pluto@agmk.net> wrote:
> I've a simple program called empty.c.
>
> $ cat empty.c
>
> int main(int argc, char* argv[])
> {
> return 0;
> }
>
> $ cat empty410.s
>
> .file "empty.c"
> .text
> .p2align 4,,15
> .globl main
> .type main, @function
> main:
> xorl %eax, %eax
> ret
> .size main, .-main
> .ident "GCC: (GNU) 4.1.0 20050922 (experimental)"
> .section .note.GNU-stack,"", at progbits

I get a substantially different empty.s (gcc-4.0.2, Fedora rawhide on i686):

.file "empty.c"
.text
.p2align 2,,3
.globl main
.type main, @function
main:
pushl %ebp
movl %esp, %ebp
subl $8, %esp
andl $-16, %esp
subl $16, %esp
xorl %eax, %eax
leave
ret
.size main, .-main
.ident "GCC: (GNU) 4.0.2 20050928 (Red Hat 4.0.2-1)"
.section .note.GNU-stack,"",@progbits

> binutils-2.15.94.0.2.2 produces for this code empty .data and .bss
> sections:

binutils-2.16.91.0.2-4 doesn't. It looks like you are using broken tools.
--
Dr. Horst H. von Brand User #22616 counter.li.org
Departamento de Informatica Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria +56 32 654239
Casilla 110-V, Valparaiso, Chile Fax: +56 32 797513
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-10-07 15:48    [W:1.038 / U:0.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site