This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFC] fix eliminate-unused-debug-types for casts (PR21391)


> > In the following code, "foo" doesn't get a debugging entry:
> > 
> > 	struct foo { int i; };
> > 
> > 	int bar (void) { return ((struct foo *)0x1234)->i; }
> > 
> > Unfortunately, by the time we get to prune_unused_type*, we no longer
> > know how the type was used.  To fix this problem, I mark all DIEs for
> > types that are used as casts in the front-end, and then consider these
> > types as used, when we are prunning the unused types.
> 
> During parsing, yes?  Then we'll mark casts used in parsed but
> non-emitted functions as used.  Was this patch superseded by the
> discussion on gcc@ about enums?

Yes.  I'm fixing all of it now.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]