141 f(mtStatistics, "Statistics") \
142 f(mtArguments, "Arguments") \
143 f(mtModule, "Module") \
144 f(mtSafepoint, "Safepoint") \
145 f(mtSynchronizer, "Synchronization") \
146 f(mtServiceability, "Serviceability") \
147 f(mtMetaspace, "Metaspace") \
148 f(mtStringDedup, "String Deduplication") \
149 f(mtObjectMonitor, "Object Monitors") \
150 f(mtNone, "Unknown") \
151 //end
152
153 #define MEMORY_TYPE_DECLARE_ENUM(type, human_readable) \
154 type,
155
156 /*
157 * Memory types
158 */
159 enum class MEMFLAGS {
160 MEMORY_TYPES_DO(MEMORY_TYPE_DECLARE_ENUM)
161 mt_number_of_types // number of memory types (mtDontTrack
162 // is not included as validate type)
163 };
164
165 #define MEMORY_TYPE_SHORTNAME(type, human_readable) \
166 constexpr MEMFLAGS type = MEMFLAGS::type;
167
168 // Generate short aliases for the enum values. E.g. mtGC instead of MEMFLAGS::mtGC.
169 MEMORY_TYPES_DO(MEMORY_TYPE_SHORTNAME)
170
171 // Make an int version of the sentinel end value.
172 constexpr int mt_number_of_types = static_cast<int>(MEMFLAGS::mt_number_of_types);
173
174 extern bool NMT_track_callsite;
175
176 class NativeCallStack;
177
178
179 char* AllocateHeap(size_t size,
180 MEMFLAGS flags,
|
141 f(mtStatistics, "Statistics") \
142 f(mtArguments, "Arguments") \
143 f(mtModule, "Module") \
144 f(mtSafepoint, "Safepoint") \
145 f(mtSynchronizer, "Synchronization") \
146 f(mtServiceability, "Serviceability") \
147 f(mtMetaspace, "Metaspace") \
148 f(mtStringDedup, "String Deduplication") \
149 f(mtObjectMonitor, "Object Monitors") \
150 f(mtNone, "Unknown") \
151 //end
152
153 #define MEMORY_TYPE_DECLARE_ENUM(type, human_readable) \
154 type,
155
156 /*
157 * Memory types
158 */
159 enum class MEMFLAGS {
160 MEMORY_TYPES_DO(MEMORY_TYPE_DECLARE_ENUM)
161 mtValueTypes, // memory for buffered value types
162 mt_number_of_types // number of memory types (mtDontTrack
163 // is not included as validate type)
164 };
165
166 #define MEMORY_TYPE_SHORTNAME(type, human_readable) \
167 constexpr MEMFLAGS type = MEMFLAGS::type;
168
169 // Generate short aliases for the enum values. E.g. mtGC instead of MEMFLAGS::mtGC.
170 MEMORY_TYPES_DO(MEMORY_TYPE_SHORTNAME)
171
172 // Make an int version of the sentinel end value.
173 constexpr int mt_number_of_types = static_cast<int>(MEMFLAGS::mt_number_of_types);
174
175 extern bool NMT_track_callsite;
176
177 class NativeCallStack;
178
179
180 char* AllocateHeap(size_t size,
181 MEMFLAGS flags,
|