[compiler-rt] [scudo] limit VMA size for riscv64 for DefaultConfig (PR #76013)

via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 8 11:08:47 PST 2024


================
@@ -124,8 +124,14 @@ struct DefaultConfig {
   struct Primary {
     using SizeClassMap = DefaultSizeClassMap;
 #if SCUDO_CAN_USE_PRIMARY64
+#if SCUDO_RISCV64
+    // Support 39-bit VMA for riscv-64
+    static const uptr RegionSizeLog = 30U;
+    static const uptr GroupSizeLog = 19U;
+#else
----------------
ChiaHungDuan wrote:

Can you share more detail about the failure you're seeing? Is the `RegionSizeLog = 30U` small enough for all 39-bit RISCV cases? I'm evaluating a different approach (#74531) to avoid the space preservation but I'm not sure if this solution will introduce a different fragmentation issue. If it's a different problem, I think we may want to have a complete different `DefaultConfig` for RISCV 39-bit (or having custom config for the specific project)

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


More information about the llvm-commits mailing list