memory overhead of static const char?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

when having a .cpp file that contains lines like:

static const char * data = "test";

compile it with -fPIC and link it as a .so file - how big is the actual overhead beside the 5 byte text (incl. terminating \0)?

I saw that there are symbols created in the .so file when looking at it with objdump -x

I don't need these symbols because I use the defined variables only locally in the .cpp file and nobody outside accesses them - maybe another variable declaration prevents creating these symbols and reduces the needed memory?

Best regards,

Erik


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux