This is an archive of the discontinued LLVM Phabricator instance.

llvm-reduce: Don't delete triple/datalayout
ClosedPublic

Authored by arsenm on Apr 18 2022, 7:18 AM.

Details

Summary

Removing these is extremely unhelpful and just adds extra hassle. This
is really finding out whether your test script uses -mtriple or
not. You can't meaningfully delete these fields, and the resulting
module defaults to the host.

Diff Detail

Event Timeline

arsenm created this revision.Apr 18 2022, 7:18 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 18 2022, 7:18 AM
arsenm requested review of this revision.Apr 18 2022, 7:18 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 18 2022, 7:18 AM
Herald added a subscriber: wdng. · View Herald Transcript

we probably have different experiences, but personally I do find reducing the triple/datalayout helpful, a lot of the things I reduce aren't affected by the two. I don't think it's a bad thing that this depends on whether or not the test script passes -mtriple or not, llvm-reduce is doing its job and reducing as much as possible

however, I can see why it might be annoying, and re-adding the two lines is more work than deleting them

perhaps a flag to toggle this behavior?

we probably have different experiences, but personally I do find reducing the triple/datalayout helpful, a lot of the things I reduce aren't affected by the two. I don't think it's a bad thing that this depends on whether or not the test script passes -mtriple or not, llvm-reduce is doing its job and reducing as much as possible

however, I can see why it might be annoying, and re-adding the two lines is more work than deleting them

perhaps a flag to toggle this behavior?

I'm trying to fix needing extra flags that I will need in 100% of cases. As far as things that are manually reducible, deleting the triple/datalayout is as easy as it gets, and about as much work as adding an option flag

aeubanks accepted this revision.Apr 20 2022, 3:04 PM
This revision is now accepted and ready to land.Apr 20 2022, 3:04 PM
swamulism accepted this revision.Apr 20 2022, 9:15 PM