Earlier quoted context omitted.
See [1], or [2] and [3]. [1] https://github.com/as-com/varint-simd/blob/f4c4af672403cc683... [2] https://en.wikipedia.org/wiki/X86_Bit_manipulation_instructi... [3] https://en.wikipedia.org/wiki/List_of_AMD_CPU_microarchitect...
So... ignore the cpuid bit indicating the instruction is present and look at manufacturer string, which is exactly what intel is being lambasted for here.
So what you would do for PDEP/PEXT would be
use_pdep = cpuid.supports_bmi2() && !cpuid.is_amd_before_zen3()
and not use_pdep = cpuid.is_intel_haswell_or_later()