Skip to content

Commit b30d667

Browse files
authored
[scudo] Change CompactPtrT and CompactPtrScale to optional (#90797)
1 parent e97bd03 commit b30d667

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

compiler-rt/lib/scudo/standalone/allocator_config.def

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -56,16 +56,8 @@ BASE_OPTIONAL(const bool, MaySupportMemoryTagging, false)
5656
// SizeClassMap to use with the Primary.
5757
PRIMARY_REQUIRED_TYPE(SizeClassMap)
5858

59-
// Defines the type and scale of a compact pointer. A compact pointer can
60-
// be understood as the offset of a pointer within the region it belongs
61-
// to, in increments of a power-of-2 scale. See `CompactPtrScale` also.
62-
PRIMARY_REQUIRED_TYPE(CompactPtrT)
63-
6459
// PRIMARY_REQUIRED(TYPE, NAME)
6560
//
66-
// The scale of a compact pointer. E.g., Ptr = Base + (CompactPtr << Scale).
67-
PRIMARY_REQUIRED(const uptr, CompactPtrScale)
68-
6961
// Log2 of the size of a size class region, as used by the Primary.
7062
PRIMARY_REQUIRED(const uptr, RegionSizeLog)
7163

@@ -86,6 +78,9 @@ PRIMARY_REQUIRED(const s32, MaxReleaseToOsIntervalMs)
8678

8779
// PRIMARY_OPTIONAL(TYPE, NAME, DEFAULT)
8880
//
81+
// The scale of a compact pointer. E.g., Ptr = Base + (CompactPtr << Scale).
82+
PRIMARY_OPTIONAL(const uptr, CompactPtrScale, SCUDO_MIN_ALIGNMENT_LOG)
83+
8984
// Indicates support for offsetting the start of a region by a random number of
9085
// pages. This is only used if `EnableContiguousRegions` is enabled.
9186
PRIMARY_OPTIONAL(const bool, EnableRandomOffset, false)
@@ -104,6 +99,11 @@ PRIMARY_OPTIONAL(const bool, EnableContiguousRegions, true)
10499
// guarantee a performance benefit.
105100
PRIMARY_OPTIONAL_TYPE(ConditionVariableT, ConditionVariableDummy)
106101

102+
// Defines the type and scale of a compact pointer. A compact pointer can
103+
// be understood as the offset of a pointer within the region it belongs
104+
// to, in increments of a power-of-2 scale. See `CompactPtrScale` also.
105+
PRIMARY_OPTIONAL_TYPE(CompactPtrT, uptr)
106+
107107
// SECONDARY_REQUIRED_TEMPLATE_TYPE(NAME)
108108
//
109109
// Defines the type of Secondary Cache to use.

0 commit comments

Comments
 (0)