Add an env var to turn off use of SIMD instructions
This commit is contained in:
parent
eee14ae148
commit
23a4012aeb
2 changed files with 8 additions and 0 deletions
|
|
@ -230,3 +230,8 @@ Variables that kitty sets when running child programs
|
|||
|
||||
Set to ``1`` when kitty is running a shell because of the ``--hold`` flag. Can
|
||||
be used to specialize shell behavior in the shell rc files as desired.
|
||||
|
||||
.. envvar:: KITTY_NO_SIMD
|
||||
|
||||
Set it to any value to prevent kitty from using SIMD CPU vector
|
||||
instructions.
|
||||
|
|
|
|||
|
|
@ -143,6 +143,9 @@ init_simd(void *x) {
|
|||
do_check();
|
||||
#endif
|
||||
#endif
|
||||
if (getenv("KITTY_NO_SIMD")) {
|
||||
has_avx2 = false; has_sse4_2 = false;
|
||||
}
|
||||
|
||||
#undef do_check
|
||||
if (has_avx2) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue