This is an archive of the discontinued LLVM Phabricator instance.

Kaleidoscope-Ch7: Add missing transformutils to llvm-config params
Needs ReviewPublic

Authored by mkroll on Feb 12 2017, 9:04 AM.

Details

Summary

TransformUtils is needed because of llvm::createPromoteMemoryToRegisterPass

Diff Detail

Event Timeline

mkroll created this revision.Feb 12 2017, 9:04 AM
chapuni edited edge metadata.Feb 12 2017, 9:42 AM

"x86" (one of "native") may induct TransformUtils, though.

I wonder libraries on llvm-config could describe minimal set, or "Used libraries in toy.cpp"
If the latter, we should give, to llvm-config, LINK_COMPONENTS in llvm/examples/Kaleidoscope/Chapter7/CMakeLists.txt.

That is, I don't think it'd be appropriate just to add TransformUtils to the command line of llvm-config in the doc.

FYI, I recommend LINK_COMPONENTS should describe "Libraries referred from objects to be linked".
In future, clang-modules would help it. (modules should know libs to link)