Bug ID: 36345
           Summary: [AArch64][GlobalISel] struct passing with fp16 members
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs

Compilation of this:

  typedef struct {
    __fp16 array[2];
  } struct2;

  struct2 global_arg0;

  void c_test(struct2 arg0) {
    global_arg0 = arg0;

fails with:

  unimplemented reg-to-reg copy
  UNREACHABLE executed at

when e.g. compiled with:

  -O0 --target=aarch64-arm-none-eabi -march=armv8-a+simd+fp bug.c -S

Looks like GISel is generating a COPY node:

    liveins: $h0, $h1
        renamable $x8 = IMPLICIT_DEF
        renamable $w9 = COPY killed renamable $h0

but this is trying to copy from a 16-bit to a 32-bit register (and COPY works
with equal sized source/destination registers?).

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

Reply via email to