diff options
| author | Daniel Chen <cdchen@ca.ibm.com> | 2024-05-08 09:47:53 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-05-08 09:47:53 -0400 |
| commit | f97f04ec4392c79163179331211ea8c48e61799b (patch) | |
| tree | 606d7872323ecc2069aa000731ce99c7616cfc54 /llvm/lib/Bitcode/Reader/BitcodeReader.cpp | |
| parent | 40b322baef143df271d8b9142028aaeeec2a4d78 (diff) | |
[mlir] Fixing a regression that '-D' option of llvm-tblgen is unregistered. (#91329)
PR #89664 introduced a regression that it unregistered llvm-tblgen
option `-D` for macros. The test `TestOps.cpp` failed due to passing a
macros to llvm-tblgen.
It caused our internal build to fail because we append `-DLOCAL_NAME`
into `LLVM_TABLEGEN_FLANGS` in `llvm/lib/cmake/llvm/TableGen.cmake` as
```
list(APPEND LLVM_TABLEGEN_FLAGS "-DLOCAL_NAME")
```
And in `./llvm/lib/Target/PowerPC/PPC.td`, we check it for some
downstream code as:
```
...
#ifdef LOCAL_NAME
...
#endif
```
Now we got error message from mlir-src-sharder as
```
mlir-src-sharder -op-shard-index=1 -DLOCAL_NAME llvm-project/mlir/test/lib/Dialect/Test/TestOps.cpp --write-if-changed -o tools/mlir/test/lib/Dialect/Test/TestOps.1.cpp -d tools/mlir/test/lib/Dialect/Test/TestOps.1.cpp.d
mlir-src-sharder: Unknown command line argument '-DLOCAL_NAME'. Try: 'llvm-project/build/bin/mlir-src-sharder --help'
mlir-src-sharder: Did you mean '-I'?
```
This PR is to fix the regression.
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
0 files changed, 0 insertions, 0 deletions
