clang makes segfaulting code with -march=core2 on i386

Andrey Chernov ache at freebsd.org
Sat Sep 13 18:58:52 UTC 2014


On 13.09.2014 22:30, Dimitry Andric wrote:
>> By first glance I see a lots of <optimized out> things. It is known that
>> in edge cases gcc preserves more "unused" values than clang. It can be
>> the possible case. I'll try to lower -O level preserving -march=core2
>> and see.
> 
> It seems to work for me with -O1 -march=core2, and while valgrind does
> complain a little, the warnings are all benign.
> 
> I'll see if I can "mix and match" a few -O2 and -O1 compiled objects, to
> zero in on where the problematic area(s) are.

I can confirm that it works with -march=core2 and without -O at all or
with -O1. So it looks very match like overoptimization in clang.

-- 
http://ache.vniz.net/

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 455 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-toolchain/attachments/20140913/0afe0853/attachment.sig>


More information about the freebsd-toolchain mailing list