This is the mail archive of the gcc@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: Variable DECL_SIZE


2012/10/4 Richard Guenther <richard.guenther@gmail.com>:
> On Wed, Oct 3, 2012 at 7:05 PM, Ilya Enkovich <enkovich.gnu@gmail.com> wrote:
>> Hi,
>>
>> I fall into ssa verification failure when try to pass field's
>> DECL_SIZE as an operand for CALL_EXPR. The fail occurs if field's size
>> is not a constant. In such case DECL_SIZE holds a VAR_DECL and I need
>> to find it's proper SSA_NAME. I thought it may be the default one but
>> gimple_default_def returns NULL. What is the right way to obtain
>> correct ssa_name in such case?
>
> There is no way.  You have to know that you need it's size at the point of
> gimplification.  Later there is no way to recover it.

Wow. It means I cannot also get an address of subsequent fields in the
structure. It looks weird. Is there a way to somehow preserve this
information during gimplification and use in later passes?

Ilya

>
> Richard.
>
>>
>> Thanks,
>> Ilya


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