On 08/22/2017 06:15 AM, Alex Bennée wrote: >> +#ifndef have_avx2 >> + /* There are a number of things we must check before we can be >> + sure of not hitting invalid opcode. */ >> + if (c & bit_OSXSAVE) { >> + unsigned xcrl, xcrh; >> + asm ("xgetbv" : "=a" (xcrl), "=d" (xcrh) : "c" (0)); >> + if (xcrl & 6 == 6) { > > My picky compiler complains: > > /home/alex/lsrc/qemu/qemu.git/tcg/i386/tcg-target.inc.c: In function > ‘tcg_target_init’: > /home/alex/lsrc/qemu/qemu.git/tcg/i386/tcg-target.inc.c:3053:22: error: > suggest parentheses around comparison in operand of ‘&’ [-Werror=parentheses] > if (xcrl & 6 == 6) {
Bah. I forgot that my default build uses -march=native, and my laptop has AVX2, so this bit wouldn't have been compile tested at all. Fixed on the branch. r~