This is an archive of the discontinued LLVM Phabricator instance.

[gn build] Add check-llvm target and make it work
ClosedPublic

Authored by thakis on Jan 1 2019, 6:57 PM.

Details

Summary

With this, check-llvm runs and passes all of clang's lit tests. It doesn't run any of its unit tests yet.

This is the only change in the GN build patch series that needs a change to a file outside of llvm/utils/gn: llvm/test/tools/llvm-config/booleans.test checks the result of llvm-config --build-system for some reason, so I'm updating the test to accept "gn" as valid output in addition to "cmake". (The alternative would be to let the gn build self-identify as cmake, which seems worse.)

Like with check-clang and check-lld, running just ninja -C out/gn will build all prerequisites needed to run tests, but it won't run the tests (so that the build becomes clean after one build). Running ninja -C out/gn check-llvm will build prerequisites if needed and run the tests. The check-llvm target never becomes clean and runs tests every time.

Diff Detail

Repository
rL LLVM

Event Timeline

thakis created this revision.Jan 1 2019, 6:57 PM
thakis updated this revision to Diff 179816.Jan 1 2019, 7:31 PM
thakis edited the summary of this revision. (Show Details)

now passes all tests

thakis edited the summary of this revision. (Show Details)Jan 1 2019, 7:37 PM
thakis updated this revision to Diff 179847.Jan 2 2019, 7:54 AM
thakis edited the summary of this revision. (Show Details)

fix most FIXMEs, make ld64 plugin tests run and pass

thakis updated this revision to Diff 179850.Jan 2 2019, 8:08 AM
thakis edited the summary of this revision. (Show Details)

ready to go

thakis updated this revision to Diff 179852.Jan 2 2019, 8:25 AM

fix minor derp

thakis updated this revision to Diff 179853.Jan 2 2019, 8:26 AM

git ls-files '*.gn' '*.gni' | xargs -n 1 gn format again

Ok, all dependencies of this have landed. D56200 is a "soft" dependency in that it's only needed to make a comment in this change here be true, it's not a functional dependency.

thakis updated this revision to Diff 179885.Jan 2 2019, 10:29 AM

add back llvm-exegesis dep that got dropped in the move

phosek: ping :-) Almost done!

serge-sans-paille accepted this revision.Jan 4 2019, 1:17 AM

LGTM, but *only* with respect to the Python 2/3 compatibility of the modification, which is just a drop in the ocean of this patch.

This revision is now accepted and ready to land.Jan 4 2019, 1:17 AM
thakis updated this revision to Diff 180239.Jan 4 2019, 5:48 AM
thakis edited the summary of this revision. (Show Details)

pulled some stuff out into dependent patches to make this smaller

thakis added a comment.Jan 4 2019, 5:53 AM

LGTM, but *only* with respect to the Python 2/3 compatibility of the modification, which is just a drop in the ocean of this patch.

Thanks! I landed that part in r350394, and moved other dependencies into their own issues D56316, D56317. Hopefully that makes this patch here a bit easier to handle.

thakis requested review of this revision.Jan 4 2019, 8:07 AM
phosek accepted this revision.Jan 4 2019, 9:00 AM

LGTM

This revision is now accepted and ready to land.Jan 4 2019, 9:00 AM
This revision was automatically updated to reflect the committed changes.