This is an archive of the discontinued LLVM Phabricator instance.

[PowerPC] Propagate undef from MMA assemble
AbandonedPublic

Authored by qiucf on Aug 25 2021, 2:41 AM.

Details

Reviewers
nemanjai
jsji
stefanp
shchenz
Group Reviewers
Restricted Project
Summary

Unlike ordinary vector instructions, MMA/Pair are built and operated through intrinsics, so we can't automatically propagate undef information from some of the source vectors. This brings problem if enabling ppc-track-subreg-liveness.

Diff Detail

Event Timeline

qiucf created this revision.Aug 25 2021, 2:41 AM
qiucf requested review of this revision.Aug 25 2021, 2:41 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 25 2021, 2:41 AM
lkail added a subscriber: lkail.Aug 25 2021, 3:06 AM
lkail added inline comments.
llvm/test/CodeGen/PowerPC/ppc64-acc-regalloc-bugfix.ll
4

I don't quite understand you both add a new option and change the IR. The IR is legal and if adding this new option leads to a crash, I think we should seek the reason behind it. Changing IR might be a workaround, but not addressing the root cause.

qiucf added inline comments.Aug 29 2021, 5:44 AM
llvm/test/CodeGen/PowerPC/ppc64-acc-regalloc-bugfix.ll
4

I manually skipped removing xxmtacc-xxmfacc in pre-emit peephole, which satisfies machine verifier.

bb.0.dmblvi_entry:
  renamable $vsl3 = XXLXORz
  renamable $vsl0 = XXLXORz
  renamable $acc0 = XXMTACC killed renamable $acc0(tied-def 0)
  renamable $acc0 = XXMFACC killed renamable $acc0(tied-def 0)
  STXV killed renamable $vsl1, 0, $zero8 :: (store (s128) into `<16 x i8>* null`, align 1)

Here stxv is not error because acc0 is partially defined. Is that an expected state?

Anyway, here vsl1 is undefined, so it should be removed as if it's stxv undef, ... if we can track its state.

qiucf abandoned this revision.Sep 5 2021, 10:23 PM

I think we can abandon this since D109302 is created.