about summary refs log tree commit diff homepage
diff options
context:
space:
mode:
-rw-r--r--lib/Core/MemoryManager.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/Core/MemoryManager.cpp b/lib/Core/MemoryManager.cpp
index f98a8a34..dba90f8d 100644
--- a/lib/Core/MemoryManager.cpp
+++ b/lib/Core/MemoryManager.cpp
@@ -43,10 +43,11 @@ llvm::cl::opt<bool> NullOnZeroMalloc(
     llvm::cl::desc("Returns NULL if malloc(0) is called (default=false)"),
     llvm::cl::init(false), llvm::cl::cat(MemoryCat));
 
-llvm::cl::opt<unsigned> RedZoneSpace(
-    "red-zone-space",
-    llvm::cl::desc("Set the amount of free space between allocations. This is "
-                   "important to detect out-of-bounds accesses (default=10)"),
+llvm::cl::opt<unsigned> RedzoneSize(
+    "redzone-size",
+    llvm::cl::desc("Set the size of the redzones to be added after each "
+                   "allocation (in bytes). This is important to detect "
+                   "out-of-bounds accesses (default=10)"),
     llvm::cl::init(10), llvm::cl::cat(MemoryCat));
 
 llvm::cl::opt<unsigned long long> DeterministicStartAddress(
@@ -125,7 +126,7 @@ MemoryObject *MemoryManager::allocate(uint64_t size, bool isLocal,
     // This way, we make sure we have this allocation between its own red zones
     size_t alloc_size = std::max(size, (uint64_t)1);
     if ((char *)address + alloc_size < deterministicSpace + spaceSize) {
-      nextFreeSlot = (char *)address + alloc_size + RedZoneSpace;
+      nextFreeSlot = (char *)address + alloc_size + RedzoneSize;
     } else {
       klee_warning_once(0, "Couldn't allocate %" PRIu64
                            " bytes. Not enough deterministic space left.",