https://bugs.llvm.org/show_bug.cgi?id=36345

            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
          Assignee: unassignedb...@nondot.org
          Reporter: sjoerd.mei...@arm.com
                CC: llvm-bugs@lists.llvm.org

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
/data/llvmdev/llvm/lib/Target/AArch64/AArch64InstrInfo.cpp:2573!

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:

  bb.1.entry:
    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
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to