looking for a way to tell gcc not to remove some code he thinks is unreachable.

looking for a way to tell gcc not to remove some code he thinks is unreachable.

Erez D erez0001 at gmail.com
Mon Mar 7 12:11:36 IST 2011


I have a function which is not called in a regular way, so gcc thinks it is
dead code.
however it is not, and i am looking for a way to tell the linker not to
remove it.

i can call it from some place with a flag that tells it to do nothing, but
this is a ugly hack
is there a directive telling gcc not to remove that certain function ?


thanks,
erez.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.cs.huji.ac.il/pipermail/linux-il/attachments/20110307/7eca0e08/attachment.html>


More information about the Linux-il mailing list