[compiler-rt] 41a2753 - [scudo] Fix definition of SCUDO_SMALL_STACK_DEPOT.
Christopher Ferris via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 21 15:18:10 PDT 2023
Author: Christopher Ferris
Date: 2023-08-21T15:17:56-07:00
New Revision: 41a275321fdf535726c10a8425231d16ce680090
URL: https://github.com/llvm/llvm-project/commit/41a275321fdf535726c10a8425231d16ce680090
DIFF: https://github.com/llvm/llvm-project/commit/41a275321fdf535726c10a8425231d16ce680090.diff
LOG: [scudo] Fix definition of SCUDO_SMALL_STACK_DEPOT.
The SCUDO_FUZZ macro is either defined or not defined. The previous
code assumed it had a one or zero value, so change the setting of
SCUDO_SMALL_STACK_DEPOT based on defined(SCUDO_FUZZ).
Reviewed By: Chia-hungDuan
Differential Revision: https://reviews.llvm.org/D158459
Added:
Modified:
compiler-rt/lib/scudo/standalone/platform.h
Removed:
################################################################################
diff --git a/compiler-rt/lib/scudo/standalone/platform.h b/compiler-rt/lib/scudo/standalone/platform.h
index 8cd1fd8d43f3f1..7504c9d142f990 100644
--- a/compiler-rt/lib/scudo/standalone/platform.h
+++ b/compiler-rt/lib/scudo/standalone/platform.h
@@ -66,7 +66,11 @@
// Use smaller table sizes for fuzzing in order to reduce input size.
// Trusty just has less available memory.
#ifndef SCUDO_SMALL_STACK_DEPOT
-#define SCUDO_SMALL_STACK_DEPOT (SCUDO_FUZZ || SCUDO_TRUSTY)
+#if defined(SCUDO_FUZZ) || SCUDO_TRUSTY
+#define SCUDO_SMALL_STACK_DEPOT 1
+#else
+#define SCUDO_SMALL_STACK_DEPOT 0
+#endif
#endif
#ifndef SCUDO_MIN_ALIGNMENT_LOG
More information about the llvm-commits
mailing list