Bug ID: 36707
           Summary: clang 6 generates invalid instruction on ARM64
           Product: clang
           Version: 6.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: -New Bugs

Created attachment 20055
a file that reproduces the bug

clang 6.0 generates invalid instruction "fmov h0,wzr". This instruction is
allowed starting with ARMv8.2, but clang generates it even for ARMv8.0. On
ARMv8.0 processor, the instruction causes SIGILL.

This bug is new to clang 6.0, clang 5.0 behaves correctly.

See the attached file and compile it with -O2.

00000000004005c0 <ret0>:
  4005c0:       1ee703e0        fmov    h0, wzr
  4005c4:       d65f03c0        ret

Note that if you compile the file with "-O2 -no-integrated-as", you get this
/tmp/ret-fp16-87b066.s: Assembler messages:
/tmp/ret-fp16-87b066.s:8: Error: selected processor does not support `fmov
clang-6.0: error: assembler command failed with exit code 1 (use -v to see

You are receiving this mail because:
You are on the CC list for the bug.
llvm-bugs mailing list

Reply via email to