[llvm] Move the preserve-{bc,ll}-uselistorder options out of individual tools, make them global defaults for AsmWriter and BitcodeWriter (PR #160079)

Mingjie Xu via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 23 06:00:34 PDT 2025


================
@@ -118,6 +118,11 @@ static cl::opt<bool>
 #endif
                                 cl::desc(""));
 
+static cl::opt<bool> PreserveBitcodeUseListOrder(
+    "preserve-bc-uselistorder",
+    cl::desc("Preserve use-list order when writing LLVM bitcode."),
+    cl::init(false), cl::Hidden);
----------------
Enna1 wrote:

Appreciate the feedback.
I've updated to use `std::optional<bool>` for `-preserve-bc-uselistorder` and `-preserve-ll-uselistorder` as suggested.

https://github.com/llvm/llvm-project/pull/160079


More information about the llvm-commits mailing list