Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NFC] [scudo] remove DCHECK #84255

Merged
merged 2 commits into from
Mar 6, 2024

Conversation

fmayer
Copy link
Contributor

@fmayer fmayer commented Mar 6, 2024

this gets checked in StackDepot::init anyway

Created using spr 1.3.4
@llvmbot
Copy link
Collaborator

llvmbot commented Mar 6, 2024

@llvm/pr-subscribers-compiler-rt-sanitizer

Author: Florian Mayer (fmayer)

Changes

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


Full diff: https://github.com/llvm/llvm-project/pull/84255.diff

1 Files Affected:

  • (modified) compiler-rt/lib/scudo/standalone/combined.h (+1-1)
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;

Created using spr 1.3.4
@fmayer fmayer changed the title [NFC] [scudo] turn DCHECK into CHECK [NFC] [scudo] remove DCHECK Mar 6, 2024
@fmayer fmayer merged commit 8acef12 into main Mar 6, 2024
4 checks passed
@fmayer fmayer deleted the users/fmayer/sprnfc-scudo-turn-dcheck-into-check branch March 6, 2024 23:45
fmayer added a commit to fmayer/llvm-project that referenced this pull request Apr 11, 2024
this gets checked in StackDepot::init anyway

Pull Request: llvm#84255
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants