This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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: [PATCH V4 5/6] Resolve dynamic target types of pointers.


Bernhard Heckel <bernhard.heckel@intel.com> writes:

>>> +set test "print intap, not associated"
>>> +gdb_test_multiple "print intap" $test {
>>> + -re " = \\(PTR TO -> \\( $int \\(:,:\\)\\)\\) <not
>>> associated>\r\n$gdb_prompt $" {
>>> +    pass $test
>>> +  }
>>> +  -re " = <not associated>\r\n$gdb_prompt $" {
>>> +    pass $test
>>> +  }
>>> +}
>> Why do we need to different regex here?  Need to handle the differences
>> of different compilers?  IMO, the former looks reasonable to me.
> A pointer to an array (especially to Variable Length Array, VLA) is
> described in Gfortran's  compiled debug info
> like normal array types + associated property of an pointer.

Could you show the debug information gfortran and ifort generates
respectively?

> Not sure if this is a bug in Gfortran or not? I was also thinking to
> make the
> output equal, and check if an array has pointer attributes but ..... I
> don't really like this approach. This would
> cause a lot of "if .. else" construct in the code for example:
> De-reference this pointer, Address operator, ...

If gfortran people confirm it is a bug, we can xfail the test.

-- 
Yao (齐尧)


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