Chris Wedgwood wrote:
[Gcc not eliminating trivial dead code...
did you compile without optimisation?]
Gcc 2.96 does remove the unreached code in your example,
but it still emits string constants.
int func()
{
if (1)
a = "foo";
else
a = "bar";
}
.LC0:
.string "foo"
.LC1:
.string "bar"
.text
.align 4
.globl func
.type func,@function
func:
pushl %ebp
movl %esp, %ebp
movl $.LC0, a
popl %ebp
ret
-- Jamie
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/
- Re: if (CONFIG_FOO) Re: 2.4.0-test... Alexander Viro
- Re: if (CONFIG_FOO) Re: 2.4.0-test... Russell King
- Re: 2.4.0-test8-pre1 is quite bad / ho... Peter Samuelson
- Re: 2.4.0-test8-pre1 is quite bad / how ab... Peter Rival
- Re: 2.4.0-test8-pre1 is quite bad / ho... Andi Kleen
- Re: 2.4.0-test8-pre1 is quite bad ... Mark H. Wood
- Re: 2.4.0-test8-pre1 is quite bad / how about i... Alexander Viro
- Re: 2.4.0-test8-pre1 is quite bad / how ab... Alan Cox
- Re: 2.4.0-test8-pre1 is quite bad / ho... Alexander Viro
- Re: 2.4.0-test8-pre1 is quite bad / how ab... Tim Waugh
- Re: 2.4.0-test8-pre1 is quite bad / how ab... Jamie Lokier
- Re: 2.4.0-test8-pre1 is quite bad / how about i... Michael Elizabeth Chastain
- Re: 2.4.0-test8-pre1 is quite bad / how ab... Alexander Viro
- Re: 2.4.0-test8-pre1 is quite bad / ho... Martin Dalecki
- Re: 2.4.0-test8-pre1 is quite bad ... Alexander Viro
- Re: 2.4.0-test8-pre1 is quite ... Martin Dalecki
- Re: 2.4.0-test8-pre1 is quite bad / how ab... Linus Torvalds
- Re: 2.4.0-test8-pre1 is quite bad / ho... Pavel Machek
- Re: 2.4.0-test8-pre1 is quite bad / how ab... Christoph Hellwig
- Re: 2.4.0-test8-pre1 is quite bad / how about i... Michael Elizabeth Chastain
- Re: 2.4.0-test8-pre1 is quite bad / how about i... Michael Elizabeth Chastain

