From 55b45709a85ccce1fcc768a458179832b030218a Mon Sep 17 00:00:00 2001 From: Paul Osmialowski Date: Wed, 24 Jun 2026 18:00:27 +0100 Subject: [PATCH] [BOLT] Increase BufSize in runtime/common.h (#204607) During my work towards bolring the flang binary, I've encountered a frequently occuring problem with running out of the buffer space. The problem affects C++ programs with a decent number of very long symbol names, which is inevitable when using template metaprogramming. As one can clearly see, flang is one of such programs. The proposed BufSize value is an effect of the trial-and-error process aiming at finiding the smallest reasonable increase. --- bolt/runtime/common.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bolt/runtime/common.h b/bolt/runtime/common.h index 8689bc8b7204..96e269e1bb79 100644 --- a/bolt/runtime/common.h +++ b/bolt/runtime/common.h @@ -162,7 +162,7 @@ struct timespec { #error "For AArch64/ARM64,X86_64 AND RISCV64 only." #endif -constexpr uint32_t BufSize = 10240; +constexpr uint32_t BufSize = 32768U; // Helper functions for writing strings to the .fdata file. We intentionally // avoid using libc names to make it clear it is our impl.