Help with module.c and free_pi_tree()
Brendan Kochunas
bkochuna@umich.edu
Fri Dec 6 14:56:00 GMT 2013
Hi Janus,
On 12/6/2013 3:50 AM, Janus Weil wrote:
> Hi Brendan,
>
>> I'm currently encountering the ICE related to Bug tickets 47546, 53015, and
>> 58007 (e.g. free_pi_tree(): Unresolved fix-up).
>
> unfortunately these bugs have turned out to be quite elusive and
> sometimes hard to reproduce. The first two have been fixed by now
> (because they are not reproducible any more), and for the third one a
> patch has been posted. Are you able to build gfortran yourself, and if
> yes have you tried the patch?
>
I can build gfortran, but I did not see this patch. I'll track it down.
>
>> I have a few hypothesis as to what conditions cause this ICE to show up when
>> building my code.
>>
>> I would like to spend some time debugging the compiler for my particular use
>> case/code to see if I can understand what is going on.
>
> It would be nice if you could figure out what is going on, but this is
> certainly not the easiest PR to start with if you are a newbie to
> gfortran.
>
I agree with this sentiment, but I'm still going to give it a shot :)
>
>> I'm new to the list and I'm curious how much support via email I might be
>> able to expect. It will generally involve questions along the lines of "how
>> do I check this?" or "what is this data structure or where is it defined?" I
>> have no qualms about putting forth effort digging through the code and
>> reading comments and other documentation, so I hope whatever help I'll need
>> is minimal. Again it'll mostly be help finding info on what I need to know
>> to what I would like.
>>
>> That said... I'm hoping to understand some of the following in as much
>> detail as possible.
>> * The contents and layout of the *.mod files generated during compilation
>> * The structure of the pointer index tree and the node data types.
>> * How the read_module() routine in module.c populates the pi_tree.
>>
>> If you just want to point me to existing documentation on these things I'm
>> perfectly ok with that.
>
> I'm afraid there isn't a lot of actual documentation on these kind of
> things, except for the actual code and comments in module.c. If you
> are willing to try and contribute this kind of documentation, that
> would be highly welcome. The proper place for it would be
> http://gcc.gnu.org/onlinedocs/gfc-internals/ (which is generated from
> gfc-internals.texi in the gfortran sources).
>
Thanks for the link. I started reading through more of the module.c
source right after I sent my original message and realized a few of my
questions were answered by the comments in module.c. The content in this
link looks like it'll help fill in the gaps for me.
>
>> Now (for your interest, feel free to skip the rest if you're not interested)
>> here's my understanding/thoughts on what may be happening to cause this ICE
>> to show up when building my code.
>
> All the information you give is not very helpful for us without seeing
> your code. Could you post here the code that is necessary to trigger
> the ICE? Reducing it as much as possible would be very helpful.
If I'm able to reliably reproduce the error with my code and determine
the cause, I hope that I may be able to write some generic test code
that replicates the behavior and I will gladly pass that along to you all.
>
> Cheers,
> Janus
>
Thank you for the reply!
-Brendan
More information about the Fortran
mailing list