accept comma-separated entries in 'has'

This commit is contained in:
dzaima 2023-10-31 03:03:04 +02:00
parent f7ec9b2283
commit d911697242
2 changed files with 4 additions and 3 deletions

View File

@ -27,7 +27,7 @@ Thus, performance can be significantly improved by targeting the specific CPU vi
On x86-64, a native build will enable usage of AVX2 (i.e. ability to use 256-bit SIMD vectors instead of 128-bit ones, among other things), and BMI2 if available. But, on aarch64, NEON is always available, so a native build won't give significant benefits. On x86-64, a native build will enable usage of AVX2 (i.e. ability to use 256-bit SIMD vectors instead of 128-bit ones, among other things), and BMI2 if available. But, on aarch64, NEON is always available, so a native build won't give significant benefits.
To produce a binary utilizing AVX2 not specific to any processor, it's possible to do `make o3 has=avx2`. (`has='avx2 bmi2'` for targeting both AVX2 & BMI2) To produce a binary utilizing AVX2 not specific to any processor, it's possible to do `make o3 has=avx2`. (`has=avx2,bmi2` for targeting both AVX2 & BMI2)
Additionally, on AMD Zen 1 & Zen 2, `make o3n has=slow-pdep` will further improve certain builtins (Zen 1/2 support BMI2, but their implementation of `pdep`/`pext` is so slow that not using it for certain operations is very beneficial). Additionally, on AMD Zen 1 & Zen 2, `make o3n has=slow-pdep` will further improve certain builtins (Zen 1/2 support BMI2, but their implementation of `pdep`/`pext` is so slow that not using it for certain operations is very beneficial).

View File

@ -76,7 +76,8 @@ onExitList ← ⟨⟩
OnExit {𝕊: {𝕏@}¨ onExitList} OnExit {𝕊: {𝕏@}¨ onExitList}
_assert_ { 𝔾𝕩?𝕩; Log 𝕨𝔽𝕩 OnExit@ •Exit 1} _assert_ { 𝔾𝕩?𝕩; Log 𝕨𝔽𝕩 OnExit@ •Exit 1}
SepArgs {' ' ((¬-˜×·+`»>)) 𝕩} Split ((¬-˜×·+`»>))
SepArgs ' 'Split
Lowercase {𝕩 - (-´"Aa")×(𝕩'A')𝕩'Z'} Lowercase {𝕩 - (-´"Aa")×(𝕩'A')𝕩'Z'}
Uppercase {𝕩 - (-´"aA")×(𝕩'a')𝕩'z'} Uppercase {𝕩 - (-´"aA")×(𝕩'a')𝕩'z'}
@ -229,7 +230,7 @@ po ← { # parsed options
singeli GetOpt "singeli" singeli GetOpt "singeli"
replxx GetOpt "REPLXX" replxx GetOpt "REPLXX"
has Lowercase GetOpt "has" has ','Split¨Lowercase GetOpt "has"
has has ("slow-pdep"<has)/"bmi2" has has ("slow-pdep"<has)/"bmi2"
{𝕊: "Error: Unsupported 'has' options; options:"1", "¨𝕩}_assert_(´has) "avx2""bmi2""pclmul""slow-pdep" {𝕊: "Error: Unsupported 'has' options; options:"1", "¨𝕩}_assert_(´has) "avx2""bmi2""pclmul""slow-pdep"
{𝕊: "Error: Cannot have 'has' options on architecture '"arch"'; add an argument of "compat"arch=x86-64""target_arch=x86-64"}_assert_¬ (arch"x86-64") 0has {𝕊: "Error: Cannot have 'has' options on architecture '"arch"'; add an argument of "compat"arch=x86-64""target_arch=x86-64"}_assert_¬ (arch"x86-64") 0has