[Patch, Fortran, OOP] PR 64230: [4.9/5 Regression] Invalid memory reference in a compiler-generated finalizer for allocatable component

Paul Richard Thomas paul.richard.thomas@gmail.com
Tue Jan 27 08:10:00 GMT 2015


Dear Janus,

I know somewhat less than nothing about such matters. I suggest that
you contact the authors of the testcases that use libubsan that you
mention.

Sorry

Paul

On 26 January 2015 at 22:20, Janus Weil <janus@gcc.gnu.org> wrote:
> Hi Paul,
>
>> The testcase has a dependence on libubsan.so, which my LD_LIBRARY_PATH
>> does not seem to be able to resolve. It therefore fails in the
>> regression test. When I point to ~/lib64, I get the message:
>>
>> /svn/trunk/gcc/testsuite/gfortran.dg/class_allocate_18.f90:8: runtime
>> error: signed integer overflow: 214358001592 * 214358001560 cannot be
>> represented in type 'integer(kind=8)'
>
> of course I tested it but did not see any problem on my machine
> (Ubuntu 14.10, x86_64-unknown-linux-gnu).
>
> In fact class_allocate_18.f90 seems to be the only testcase in
> gfortran.dg/ which uses any -fsanitize options, but there are plenty
> in other sections (mostly c-c++-common/ubsan/ and g++.dg/ubsan/).
>
> Could it be a problem with your local setup or a dejagnu issue that
> only applears on certain platforms? I have no idea how to fix this. Do
> you have any suggestion?
>
> Cheers,
> Janus
>
>
>
>> On 26 January 2015 at 15:57, Janus Weil <janus@gcc.gnu.org> wrote:
>>> 2015-01-24 18:18 GMT+01:00 Tobias Burnus <burnus@net-b.de>:
>>>>> this is a second patch dealing with finalization-related regressions,
>>>>> [...]
>>>>> This patch fixes an invalid memory reference inside the finalizer
>>>>> routine (at runtime), which apparently was caused by dereferencing a
>>>>> pointer without checking if it's NULL. I simply insert a call to
>>>>> ASSOCIATED.
>>>>> [...]
>>>>>
>>>>> This one regtests cleanly on x86_64-unknown-linux-gnu. Ok for trunk and
>>>>> 4.9?
>>>>
>>>>
>>>> OK. Thanks for the patch!
>>>
>>> Thanks for the review, Tobias. Committed to trunk as r220125. Will
>>> backport to 4.9 soon.
>>>
>>> Cheers,
>>> Janus
>>
>>
>>
>> --
>> Outside of a dog, a book is a man's best friend. Inside of a dog it's
>> too dark to read.
>>
>> Groucho Marx



-- 
Outside of a dog, a book is a man's best friend. Inside of a dog it's
too dark to read.

Groucho Marx



More information about the Gcc-patches mailing list