Bug ID: 85281
           Summary: [8 Regression] Assembler messages: Error: operand size
                    mismatch for `vpbroadcastb' with -mavx512bw
           Product: gcc
           Version: 8.0.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot
          Reporter: zsojka at seznam dot cz
  Target Milestone: ---

Created attachment 43875
reduced testcase

Compiler output:
$ x86_64-pc-linux-gnu-gcc -O -mavx512bw -masm=intel -w testcase.c -save-temps
testcase.s: Assembler messages:
testcase.s:32: Error: operand size mismatch for `vpbroadcastb'

The failing instruction is:
        vpbroadcastb    zmm0{k2}, XMMWORD PTR [rsp+48]
which is mixing zmm0 and XMMWORD.
This compiles fine with att syntax:
        vpbroadcastb    48(%rsp), %zmm0{%k2}

The gcc I am using is patched with the fix for PR85177#c1

7-branch is fine on this testcase, but it generates very different (inferior in
my eyes) code.

$ x86_64-pc-linux-gnu-gcc -v
Using built-in specs.
Target: x86_64-pc-linux-gnu
Configured with: /repo/gcc-trunk//configure --enable-languages=c,c++
--enable-valgrind-annotations --disable-nls --enable-checking=yes,rtl,df,extra
--disable-bootstrap --with-cloog --with-ppl --with-isl
--build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu
--target=x86_64-pc-linux-gnu --with-ld=/usr/bin/x86_64-pc-linux-gnu-ld
--with-as=/usr/bin/x86_64-pc-linux-gnu-as --disable-libstdcxx-pch
Thread model: posix
gcc version 8.0.1 20180407 (experimental) (GCC)

Reply via email to