]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Enable eager FPU context switch by default on amd64.
authorKonstantin Belousov <kib@FreeBSD.org>
Wed, 13 Jun 2018 17:55:09 +0000 (17:55 +0000)
committerKonstantin Belousov <kib@FreeBSD.org>
Wed, 13 Jun 2018 17:55:09 +0000 (17:55 +0000)
commitd1a07e31e5cc38fe82aeeda91d58dfdaaa6934bc
tree74a969bca11cd072000a0c4244d863cb7eeccea4
parent46c0e42b6e65a8b0d9cf024b6d831dd4bc705d1a
Enable eager FPU context switch by default on amd64.

With compilers making increasing use of vector instructions the
performance benefit of lazily switching FPU state is no longer a
desirable tradeoff.  Linux switched to eager FPU context switch some
time ago, and the idea was floated on the FreeBSD-current mailing list
some years ago[1].

Enable eager FPU context switch by default on amd64, with a tunable/sysctl
available to turn it back off.

[1] https://lists.freebsd.org/pipermail/freebsd-current/2015-March/055198.html

Reviewed by: jhb
Tested by: pho
Sponsored by: The FreeBSD Foundation
sys/amd64/amd64/cpu_switch.S
sys/amd64/amd64/fpu.c