On Thu, Jul 07, 2005 at 01:28:18PM -0400, Michael Tegtmeyer wrote: > So the question is, what is the easiest way to obtain the > specific field that was referenced in this case? > You need to traverse the IL and examine the LHS and RHS of expressions for COMPONENT_REF and INDIRECT_REF expressions. In GIMPLE these expressions may only appear on the LHS or RHS of assignments, and in function arguments.
You then need to walk the expression looking for FIELD_DECLs. And you had better do this before SRA (which will decompose most structure references into compiler generated scalars). Diego.