llvm/mlir-www

Undocumented LLVM_TARGETS_TO_BUILD values "Native" and "host" used and used inconsistently

PerMildner opened this issue · 2 comments

https://mlir.llvm.org/getting_started/ says (under "Unix-like compile/testing"):

cmake ... -DLLVM_TARGETS_TO_BUILD="Native;NVPTX;AMDGPU" ...

whereas, under "Windows compile/testing" it says:

cmake ... -DLLVM_TARGETS_TO_BUILD="host" ...

However, neither "Native" nor "host" are documented as valid values for LLVM_TARGETS_TO_BUILD (the only symbolic value listed is "all").

This is inconsistent and in a "Getting Started" document it is also unfortunate that an undocumented flag value is used.

A quick grep shows that both "Native" and "host" are used in the sources, even in the same sub-projects. E.g. llvm-project/mlir/examples/standalone/README.md ("host"), llvm-project/mlir/examples/minimal-opt/README.md ("Native"). llvm-project/libcxx/utils/ci/run-buildbot ("host"), and so on.

The documentation for these flag is rather an issue for the LLVM repo than for the MLIR website.
Even better: send a PR to add the doc here: https://github.com/llvm/llvm-project/blob/main/llvm/docs/CMake.rst ?

Thanks for looking at this.
I agree that the undocumented-ness is for the LLVM repo, but at least MLIR should consistently use the same undocumented option :-)