This is an archive of the discontinued LLVM Phabricator instance.

[PowerPC][HTM] Fix $zero is not a GPRC register for builtin_ttest
ClosedPublic

Authored by jsji on Jun 10 2019, 8:33 AM.

Details

Summary

This was found during HTM cleanup.
Adding a test for builtin_ttest would expose following issue.

    • Bad machine code: Illegal physical register for instruction ***
  • function: test10
  • basic block: %bb.0 entry (0xf0e57497b58)
  • instruction: %5:crrc0 = TABORTWCI 0, $zero, 0
  • operand 2: $zero

$zero is not a GPRC register.
LLVM ERROR: Found 1 machine code errors.

Diff Detail

Event Timeline

jsji created this revision.Jun 10 2019, 8:33 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 10 2019, 8:33 AM
Herald added a subscriber: hiraditya. · View Herald Transcript
hfinkel accepted this revision.Jun 10 2019, 10:49 AM

Indeed. Doesn't look like R0 is special there. LGTM.

This revision is now accepted and ready to land.Jun 10 2019, 10:49 AM
This revision was automatically updated to reflect the committed changes.