This is an archive of the discontinued LLVM Phabricator instance.

Parse EB variant as suffix for ARM triples
ClosedPublic

Authored by joerg on Jan 25 2015, 11:55 AM.

Details

Summary

The canonical CPU variant for ARM according to config.guess uses a suffix it seems:

# ./config.guess
earmv7hfeb-unknown-netbsd7.99.4

Extend the triple parsing to support this. Avoid running the ARM parser multiple times because StringSwitch is not lazy.

Diff Detail

Event Timeline

joerg updated this revision to Diff 18732.Jan 25 2015, 11:55 AM
joerg retitled this revision from to Parse EB variant as suffix for ARM triples.
joerg updated this object.
joerg edited the test plan for this revision. (Show Details)
joerg added a reviewer: t.p.northover.
joerg added a subscriber: Unknown Object (MLST).
rengolin added inline comments.
lib/Support/Triple.cpp
1039

This patterns repeat far too often, can you move it into a helper function?

joerg added a comment.Jan 25 2015, 2:59 PM

Yes in principle, but I'd like to keep this simple for the moment as work on a more extensive rewrite after 3.6 is done.

rengolin accepted this revision.Jan 25 2015, 3:02 PM
rengolin added a reviewer: rengolin.

Makes sense. LGTM. Thanks!

This revision is now accepted and ready to land.Jan 25 2015, 3:02 PM
t.p.northover accepted this revision.Jan 25 2015, 5:40 PM
t.p.northover edited edge metadata.

Probably for the best; armv7eb seems more readable to me than armebv7 anyway.

This revision was automatically updated to reflect the committed changes.