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: A plan to remove CUMULATIVE_ARGS [was: Re: RFA: PR44566: accessor macros (1/3): CUMULATIVE_ARGS]


On Fri, Jun 25, 2010 at 02:05:26PM -0400, Joern Rennecke wrote:
> Quoting Nathan Froyd <froydnj@codesourcery.com>:
>> Yes, we agree here, but I must be dense, because I can't tell what
>> changes that you think I would make that make it target-dependent.
>> Could you please provide examples of such changes?  Just for
>> clarification: I'm talking about making hooks that take/return pointers
>> to CUMULATIVE_ARGS, *not* the actual CUMULATIVE_ARGS structure.
>
> If you declare it as void * - or something typedef'ed to void * - than this
> problem does not arise.

OK, great.  This can be done after (or concurrently with) the last step
of the grand plan posted above.  I don't think it's worth doing
something with 'void *' until things are hookized appropriately.  Once
the hookization is complete, I agree that it would be reasonable to use
'void *' or similar to ensure the compiler does not perform unexpected
optimizations and to guard against errant pointer arithmetic.

-Nathan


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