On 26 Oct 2015, at 16:21, Eric van Gyzen <vangy...@freebsd.org> wrote:
> 
> One counter-argument to this change is that most applications already
>  use SIMD, and the number of applications and amount of SIMD usage
>  are only increasing.

Note that SSE and SIMD are not the same thing.  The x86-64 ABI uses SSE 
registers for floating point arguments, so even a purely scalar application 
that uses floating point will end up faulting in the SSE state.  This is not 
the case on IA32, where x87 registers are used (though when compiling for i686, 
SSE is used by default because register allocation for x87 is a huge pain).

I believe that the no-sse option for clang is ABI-preserving, so will not 
actually disable all SSE unless you also specify -msoft-float.  I don’t think 
that libthr uses floating point anywhere, but libc does and you only need to 
call one function that takes a floating point argument in between context 
switches to lose this gain on x86-64.  With this change, we’re making the 
compiler emit less efficient code, on the assumption that nothing will touch 
the fpu in the quantum before the next context switch.  I’d really like to see 
the set of applications that you benchmarked the change with on x86-64 to reach 
the conclusion that this is a net win overall. 

Or, to put it another way: How many applications are multithreaded but don’t 
use any floating point code?

David

_______________________________________________
svn-src-stable-10@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10
To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"

Reply via email to