https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=218387

            Bug ID: 218387
           Summary: -march=native or any specific CPU seems to produce x87
                    math a lot
           Product: Base System
           Version: CURRENT
          Hardware: amd64
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: bin
          Assignee: [email protected]
          Reporter: [email protected]

I think this is a bug, but perhaps I just think it is because the behavior
diverges from GCC by quite a bit.

When you compile an application that does floating point math with clang in
current right now, specifying -march=native or -march=sandybridge or btver2 or
any number of CPUs I tried to target produces predominantly x87 instructions. 
Typically GCC and most other compilers I've seen default to targeting SSE
instructions, instead.

If you specify -march=x86-64, you get the results you'd expect (predominantly
SSE2 instructions for floating point).  This leads me to believe this is a bug,
for most everything SSE units should be the most optimal.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-bugs
To unsubscribe, send any mail to "[email protected]"

Reply via email to