crond and non-void function not returning

Bernhard Fischer rep.nop at aon.at
Wed May 24 09:50:55 UTC 2006


On Sun, May 21, 2006 at 10:22:17PM +0200, Yann E. MORIN wrote:
>Bernhard,
>All,
>
>On Saturday 20 May 2006 153, Bernhard Fischer wrote:
>> On Fri, May 19, 2006 at 10:03:34PM +0200, Yann E. MORIN wrote:
>> >And using ATTRIBUTE_NORETURN has no effect on a function that is non-void.
>> You're right.
>
>No, I'm not totally right, see below...

Yeah, if there is no explicit ret; in the function, i should have added.
>
>> So.. that proposed return 0; confuses the optimizers enough to add about
>> 50 (or so) bytes to the defconfig binary.
>
>Woupss.. Bad.
>
>> IMA mode
>
>IMA == ? (yep, all sources compiled at once, but acronym means?)

InterModule Analysis;
Some commercial compiler vendors refer to vaguely the same thing as
IPO == InterProcedural Optimization
IPA == InterProcedural Analysis
>
>> AFAICS adding a exit(0) or bb_fflush_stdout_and_exit(0) is size-neutral
>> for both IMA and legacy compiles, so i will apply the latter instead of
>> return 0.
>
[snip examples]
>
>"Et voila." And as Bernhard pointed out, adding a call to exit(3), or to
>bb_fflush_stdout_and_exit, is size-neutral.



More information about the busybox mailing list