[PATCH] D136791: llvm-reduce: Support emitting bitcode for final result

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 28 17:52:06 PDT 2022


arsenm added a comment.

In D136791#3893379 <https://reviews.llvm.org/D136791#3893379>, @aeubanks wrote:

> wdyt about replacing `-output-bitcode` with `-output-type=autodetect|bitcode|text`, defaulting to `autodetect`? that seems conceptually cleaner than this logic, which has a weird imbalance between preferring bitcode vs text

I thought about doing this. We have so little consistency throughout the tools for this. Most seem to use -S to switch to text, and I don't think any try to detect based on the file extension. Since it's a reduction tool, the most sensible thing would probably be to just consistently reuse the input type (this also applies to -write-tmp-files-as-bitcode. Most of the tools happen to accept .ll or .bc inputs, but you could be reducing something that specifically needs one or the other)


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D136791/new/

https://reviews.llvm.org/D136791



More information about the llvm-commits mailing list