[all-commits] [llvm/llvm-project] 018a96: [AArch64][GlobalISel] Fix a crash during selection...

Amara Emerson via All-commits all-commits at lists.llvm.org
Fri May 28 16:35:40 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 018a9641ff1a488f3ffbe1251666696fa5b29915
      https://github.com/llvm/llvm-project/commit/018a9641ff1a488f3ffbe1251666696fa5b29915
  Author: Amara Emerson <amara at apple.com>
  Date:   2021-05-28 (Fri, 28 May 2021)

  Changed paths:
    M llvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
    A llvm/test/CodeGen/AArch64/GlobalISel/select-zext-as-copy.mir

  Log Message:
  -----------
  [AArch64][GlobalISel] Fix a crash during selection of a G_ZEXT(s8 = G_LOAD)

We have special handling for a zext of a load <32b because the load does a zext
for free. In that case, we just select the G_ZEXT as if it were a copy but this
triggered the copy checking code to balk at the mismatched size.

This was being hidden because normally these get combined into G_ZEXTLOAD but
for atomics this doesn't happen. The test case here just uses a normal load
because the particular atomic isn't supported yet anyway.




More information about the All-commits mailing list