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: How to extract types of variables and its uid?


On Fri, Apr 10, 2015 at 6:28 AM, Swati Rathi <swatirathi@cse.iitb.ac.in> wrote:
> Is there a plan of merging type uid's?

No, there is no reason to do so.

> Also, is there is a global store maintaining all the types used in a
> program?

No.

> Or is there any other unique feature to distinguish between two tree types,
> other than type uid?

Depends on the definition of the equality relation.

Richard.

>
>
> On Thursday 09 April 2015 09:47 PM, Richard Biener wrote:
>>
>> On April 9, 2015 5:11:00 PM GMT+02:00, Swati
>> Rathi<swatirathi@cse.iitb.ac.in>  wrote:
>>>
>>> I have enabled the LTO infrastructure using -flto -flto-partition=none.
>>>
>>> In the LTO infrastructure, when I try to print the TYPE_UID for the
>>> types of variable var1 and var2, its different (as mentioned in my
>>> first
>>> post).
>>>
>>> IStream *var1;
>>> IStream *var2;
>>
>> Even there merging isn't guaranteed.
>>
>> Richard.
>>
>>> On Thursday 09 April 2015 08:21 PM, Andrew Pinski wrote:
>>>>
>>>> On Thu, Apr 9, 2015 at 10:40 PM, Swati Rathi
>>>
>>> <swatirathi@cse.iitb.ac.in>  wrote:
>>>>>
>>>>> Even I am getting same uid's on small programs.
>>>>> I tried declaring variables across files also.
>>>>> But I am unable to replicate the problem on small programs.
>>>>>
>>>>> I am testing on SPEC CPU2006 benchmark suite, program - 453.povray
>>>>> Below is the information which is getting dumped using
>>>>> -fdump-tree-gimple-uid
>>>>>
>>>>> IStream has different uid's -> 5363, 5364, 11467 and 11521. In a
>>>
>>> file the
>>>>>
>>>>> uid is same.
>>>>> Can you suggest other experiments to identify the reason?
>>>>
>>>> Yes UID are only the same compiling unit.  If you want to do some
>>>> analysis with types across units you should be using LTO
>>>> infrastructure.
>>>>
>>>> Thanks,
>>>> Andrew
>
>


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