• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: dead-code stripping, pass two...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: dead-code stripping, pass two...


  • Subject: Re: dead-code stripping, pass two...
  • From: "Andy O'Meara" <email@hidden>
  • Date: Wed, 17 May 2006 23:38:27 -0400
  • Thread-topic: dead-code stripping, pass two...

If you search this list archive, you'll find the below thread -- it should
address your questions/problems:

http://lists.apple.com/archives/xcode-users/2006/Mar/msg00552.html




On 5/17/06 10:44 PM, "Steve Christensen" <email@hidden> wrote:

> Following another other dead-code stripping thread, I turned on
> "Symbols hidden by default" (aka [GCC_SYMBOLS_PRIVATE_EXTERN, -
> fvisibility=hidden]) and noticed a reduction in executable size.
> However nm is still reporting a lot of API symbols that are only
> referenced from unused C++ class methods, so I don't know where the
> reduction actually came from. Thus I'm still kinda in the same boat
> is before.
>
> Any more guesses? :-)
>
>
>
> On May 17, 2006, at 2:16 PM, Steve Christensen wrote:
>
>> On May 17, 2006, at 2:03 PM, Ladd Van Tol wrote:
>>
>>> On May 17, 2006, at 11:27 AM, Steve Christensen wrote:
>>>
>>>> I'd asked about this last month and didn't really receive any
>>>> responses, so I figure I should try again just in case.
>>>>
>>>> I have a number of plug-in projects I imported from CodeWarrior
>>>> to Xcode as part of making them Universal and all that. They
>>>> build and run correctly, but I've noticed that the binary size
>>>> has grown considerably more than 2x (in one case going from
>>>> around 48K in CodeWarrior to 197K as a UB built by Xcode).
>>>>
>>>> After doing a little more poking around, I found that the problem
>>>> appears to be that unused class methods are not being stripped
>>>> out, which means that the method code as well as any that they
>>>> reference, etc., etc., gets left in the binary. These are not
>>>> virtual methods, BTW.
>>>>
>>>> I have dead-code stripping and symbol stripping turned on, as
>>>> well as doing an extra post-link strip pass and specifying an
>>>> exported symbols file just to see if that would make a
>>>> difference. It doesn't.
>>>>
>>>> Is there some magical incantation that I've missed someplace? A
>>>> known linker bug? A bug in the CodeWarrior project import process?
>>>
>>> This is fairly obvious, but do you have -gfull set?
>>
>> Yep, or at least that's what the project settings say.
>  _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Xcode-users mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
>
>


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: dead-code stripping, pass two...
      • From: Steve Christensen <email@hidden>
References: 
 >Re: dead-code stripping, pass two... (From: Steve Christensen <email@hidden>)

  • Prev by Date: Re: Switching from -O3 to -Os causes my code to start crashing
  • Next by Date: Re: dead-code stripping, pass two...
  • Previous by thread: Re: dead-code stripping, pass two...
  • Next by thread: Re: dead-code stripping, pass two...
  • Index(es):
    • Date
    • Thread