Closed nivas-x86 closed 2 years ago
The Cpu::has() parallel check seems to broken.
Below code on Haswell machine prints "WRONG" . (The commit https://github.com/herumi/xbyak/commit/3ea8e45d33bbe22b4130d1bf01edc91b8aadf7fa prints "OK")
#include <stdio.h> #include "xbyak/xbyak_util.h" using namespace Xbyak::util; int main() { Cpu hsw; if ((hsw.has(Cpu::tAVX2) && hsw.has(Cpu::tAVX512F)) == hsw.has(Cpu::tAVX2 | Cpu::tAVX512F)) { printf("OK\n"); return 0; } else { printf("WRONG\n"); return -1; } }
Sorry for the incompleteness. Is this patch okay?
No problem. Thank you for the quick fix, it works fine now.
Thank you for the quick check. I've pushed it into the master branch.
The Cpu::has() parallel check seems to broken.
Below code on Haswell machine prints "WRONG" . (The commit https://github.com/herumi/xbyak/commit/3ea8e45d33bbe22b4130d1bf01edc91b8aadf7fa prints "OK")