This is an archive of the discontinued LLVM Phabricator instance.

[DAGCombiner] Remove explicit call to AddToWorklist in sqrt and reciprocal computations
ClosedPublic

Authored by deadalnix on Aug 21 2019, 1:18 PM.

Details

Summary

These nodes end up being processed regardless due to DAGCombiner ensuring arguments are processed. This changes the order in which nodes are processed, which fixes an issue on PowerPC.

Diff Detail

Repository
rL LLVM

Event Timeline

deadalnix created this revision.Aug 21 2019, 1:18 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 21 2019, 1:18 PM
RKSimon added inline comments.Aug 21 2019, 1:28 PM
test/CodeGen/PowerPC/qpx-recipest.ll
205 ↗(On Diff #216456)

Is the qvfcmpeq removed as well?

deadalnix marked an inline comment as done.Aug 22 2019, 5:36 AM
deadalnix added inline comments.
test/CodeGen/PowerPC/qpx-recipest.ll
205 ↗(On Diff #216456)

Let me double check, it may be an error of mine.

RKSimon added inline comments.Aug 22 2019, 5:41 AM
test/CodeGen/PowerPC/qpx-recipest.ll
205 ↗(On Diff #216456)

How bad would it be to use the update script and regenerate all the CHECKs?

deadalnix updated this revision to Diff 216593.Aug 22 2019, 6:07 AM

Restore check for qvfcmpeq

RKSimon accepted this revision.Aug 22 2019, 6:49 AM

LGTM - cheers

This revision is now accepted and ready to land.Aug 22 2019, 6:49 AM
deadalnix marked an inline comment as done.Aug 22 2019, 8:05 AM
deadalnix added inline comments.
test/CodeGen/PowerPC/qpx-recipest.ll
205 ↗(On Diff #216456)

As far as I know, this is not available for PowerPC, unless something changed recently.

lebedev.ri added inline comments.Aug 22 2019, 8:12 AM
test/CodeGen/PowerPC/qpx-recipest.ll
205 ↗(On Diff #216456)

Shouldn't be too complicated to add

jsji added inline comments.Aug 22 2019, 8:18 AM
test/CodeGen/PowerPC/qpx-recipest.ll
205 ↗(On Diff #216456)

I just tried, it should work.

deadalnix marked an inline comment as done.Aug 22 2019, 8:20 AM
deadalnix added inline comments.
test/CodeGen/PowerPC/qpx-recipest.ll
205 ↗(On Diff #216456)

As it turns out, I'm incorrect, so I'll do this and update the diff accordingly before landing.

xbolva00 added inline comments.
test/CodeGen/PowerPC/qpx-recipest.ll
205 ↗(On Diff #216456)

./update_llc_test_checks.py ../test/CodeGen/PowerPC/qpx-recipest.ll

./llvm-lit /home/xbolva00/LLVM/llvm/test/CodeGen/PowerPC/qpx-recipest.ll

  • Testing: 1 tests, single process --

PASS: LLVM :: CodeGen/PowerPC/qpx-recipest.ll (1 of 1)
Testing Time: 3.74s

Expected Passes    : 1
jsji added inline comments.Aug 22 2019, 8:22 AM
test/CodeGen/PowerPC/qpx-recipest.ll
205 ↗(On Diff #216456)

Simon have commited it in https://reviews.llvm.org/rL369659

deadalnix updated this revision to Diff 216636.Aug 22 2019, 8:33 AM

rebase and regenerate test

This revision was automatically updated to reflect the committed changes.