clang generated code sometimes confuses fbt

Dimitry Andric dim at FreeBSD.org
Tue Mar 5 14:57:35 UTC 2013


On 2013-03-05 13:02, Andriy Gapon wrote:
> on 04/03/2013 13:50 Dimitry Andric said the following:
>> Actually, that way of fixing breaks it for gcc, so it should really be
>> fixed in sort_iidescs() instead.  See attached diff; I verified it works
>> for both gcc-compiled and clang-compiled objects.
>
> Impossible!  It looks like the attached diff was a nop change :-)
>
> BTW, so changing clang to match gcc is not an option?
> I do not insist, just curious.

I could not find a good argument to present to upstream to change this
behaviour, except "gcc has been doing it for x years, without a good
reason". :-)  And I did not want to make yet another FreeBSD specific
change.

In my opinion, gcc is losing information here, e.g. the original
pathname to the source file.  There is no reason debugging tools cannot
be fixed to be able to cope with this.


More information about the freebsd-hackers mailing list