[compiler-rt] [NFC] [scudo] turn DCHECK into CHECK (PR #84255)

Florian Mayer via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 6 15:05:56 PST 2024


https://github.com/fmayer created https://github.com/llvm/llvm-project/pull/84255

This should get optimized away anyway: https://godbolt.org/z/GM6sKM5YE


>From 0c6a5d6e12c351f46d07ac0cf711f70e08fb600a Mon Sep 17 00:00:00 2001
From: Florian Mayer <fmayer at google.com>
Date: Wed, 6 Mar 2024 15:05:46 -0800
Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20initia?=
 =?UTF-8?q?l=20version?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Created using spr 1.3.4
---
 compiler-rt/lib/scudo/standalone/combined.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/compiler-rt/lib/scudo/standalone/combined.h b/compiler-rt/lib/scudo/standalone/combined.h
index fa6077384d9826..10c2f5ffb90a90 100644
--- a/compiler-rt/lib/scudo/standalone/combined.h
+++ b/compiler-rt/lib/scudo/standalone/combined.h
@@ -1570,7 +1570,7 @@ class Allocator {
     if (TabSize > UINT32_MAX / kFramesPerStack)
       return;
     u32 RingSize = static_cast<u32>(TabSize * kFramesPerStack);
-    DCHECK(isPowerOfTwo(RingSize));
+    CHECK(isPowerOfTwo(RingSize));
 
     uptr StackDepotSize = sizeof(StackDepot) + sizeof(atomic_u64) * RingSize +
                           sizeof(atomic_u32) * TabSize;



More information about the llvm-commits mailing list