Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 9
    Sadly I'm not looking to remove the code from the binary - I'm looking to find out which parts of the source can be cleaned up Commented Feb 15, 2012 at 3:28
  • 10
    If I remember correctly, there is a verbosity option that will print a list of optimizations that was done by gc-sections. I think it is "--print-gc-sections" Commented Feb 15, 2012 at 5:13
  • @eyalm I think you answer gonna get lot more upvotes if you'd change it a bit to add the print-gc-sections option with an example. Commented Jul 6, 2018 at 10:13
  • The quoted information is in ld's manpage, not gcc's. Commented May 9, 2022 at 17:54