[libc-commits] [libc] [llvm] [libc] Files now flush on exit (PR #230215)

Jeff Bailey via libc-commits libc-commits at lists.llvm.org
Fri Oct 9 02:49:58 PDT 2026


================
@@ -165,6 +165,12 @@
       "doc": "Configures sorting algorithm for qsort and qsort_r. Values accepted are LIBC_QSORT_QUICK_SORT, LIBC_QSORT_HEAP_SORT."
     }
   },
+  "stdlib": {
+    "LIBC_CONF_EXIT_FLUSH_STREAMS": {
+      "value": true,
+      "doc": "Flush all open stdio streams when exit is called, as required by the C standard. Can be disabled in configurations without stdio streams (e.g. baremetal without files) so that exit does not depend on stdio."
----------------
kaladron wrote:

That's a good point - the cmake could be made conditional on the targets being there rather than being a knob that one would twiddle separately.  We probably want this unconditionally when the streams are enabled.


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


More information about the libc-commits mailing list