1
- // Copyright 2024 Braden Ganetsky
1
+ // Copyright 2024-2025 Braden Ganetsky
2
2
// Distributed under the Boost Software License, Version 1.0.
3
3
// https://www.boost.org/LICENSE_1_0.txt
4
4
5
- // Generated on 2024 -08-25T17:48:54
5
+ // Generated on 2025 -08-21T03:09:19
6
6
7
7
#ifndef BOOST_UNORDERED_DETAIL_UNORDERED_PRINTERS_HPP
8
8
#define BOOST_UNORDERED_DETAIL_UNORDERED_PRINTERS_HPP
@@ -58,22 +58,23 @@ __asm__(".pushsection \".debug_gdb_scripts\", \"MS\",%progbits,1\n"
58
58
59
59
" .ascii \" class BoostUnorderedFcaPrinter:\\ n\"\n "
60
60
" .ascii \" def __init__(self, val):\\ n\"\n "
61
- " .ascii \" self.val = BoostUnorderedHelpers.maybe_unwrap_reference(val)\\ n\"\n "
62
- " .ascii \" self.name = f\\\" {self.val.type.strip_typedefs()}\\\" .split(\\\" <\\\" )[0]\\ n\"\n "
61
+ " .ascii \" val = BoostUnorderedHelpers.maybe_unwrap_reference(val)\\ n\"\n "
62
+ " .ascii \" self.table = val[\\\" table_\\\" ]\\ n\"\n "
63
+ " .ascii \" self.name = f\\\" {val.type.strip_typedefs()}\\\" .split(\\\" <\\\" )[0]\\ n\"\n "
63
64
" .ascii \" self.name = self.name.replace(\\\" boost::unordered::\\\" , \\\" boost::\\\" )\\ n\"\n "
64
65
" .ascii \" self.is_map = self.name.endswith(\\\" map\\\" )\\ n\"\n "
65
- " .ascii \" self.cpo = BoostUnorderedPointerCustomizationPoint(self.val[ \\\" table_ \\\" ] [\\\" buckets_\\\" ][\\\" buckets\\\" ])\\ n\"\n "
66
+ " .ascii \" self.cpo = BoostUnorderedPointerCustomizationPoint(self.table [\\\" buckets_\\\" ][\\\" buckets\\\" ])\\ n\"\n "
66
67
67
68
" .ascii \" def to_string(self):\\ n\"\n "
68
- " .ascii \" size = self.val[ \\\" table_ \\\" ] [\\\" size_\\\" ]\\ n\"\n "
69
+ " .ascii \" size = self.table [\\\" size_\\\" ]\\ n\"\n "
69
70
" .ascii \" return f\\\" {self.name} with {size} elements\\\"\\ n\"\n "
70
71
71
72
" .ascii \" def display_hint(self):\\ n\"\n "
72
73
" .ascii \" return \\\" map\\\"\\ n\"\n "
73
74
74
75
" .ascii \" def children(self):\\ n\"\n "
75
76
" .ascii \" def generator():\\ n\"\n "
76
- " .ascii \" grouped_buckets = self.val[ \\\" table_ \\\" ] [\\\" buckets_\\\" ]\\ n\"\n "
77
+ " .ascii \" grouped_buckets = self.table [\\\" buckets_\\\" ]\\ n\"\n "
77
78
78
79
" .ascii \" size = grouped_buckets[\\\" size_\\\" ]\\ n\"\n "
79
80
" .ascii \" buckets = grouped_buckets[\\\" buckets\\\" ]\\ n\"\n "
@@ -167,14 +168,20 @@ __asm__(".pushsection \".debug_gdb_scripts\", \"MS\",%progbits,1\n"
167
168
168
169
" .ascii \" class BoostUnorderedFoaPrinter:\\ n\"\n "
169
170
" .ascii \" def __init__(self, val):\\ n\"\n "
170
- " .ascii \" self.val = BoostUnorderedHelpers.maybe_unwrap_reference(val)\\ n\"\n "
171
- " .ascii \" self.name = f\\\" {self.val.type.strip_typedefs()}\\\" .split(\\\" <\\\" )[0]\\ n\"\n "
171
+ " .ascii \" val = BoostUnorderedHelpers.maybe_unwrap_reference(val)\\ n\"\n "
172
+ " .ascii \" self.table = val[\\\" table_\\\" ]\\ n\"\n "
173
+ " .ascii \" self.name = f\\\" {val.type.strip_typedefs()}\\\" .split(\\\" <\\\" )[0]\\ n\"\n "
172
174
" .ascii \" self.name = self.name.replace(\\\" boost::unordered::\\\" , \\\" boost::\\\" )\\ n\"\n "
173
175
" .ascii \" self.is_map = self.name.endswith(\\\" map\\\" )\\ n\"\n "
174
- " .ascii \" self.cpo = BoostUnorderedPointerCustomizationPoint(self.val[\\\" table_\\\" ][\\\" arrays\\\" ][\\\" groups_\\\" ])\\ n\"\n "
176
+ " .ascii \" self.cpo = BoostUnorderedPointerCustomizationPoint(self.table[\\\" arrays\\\" ][\\\" groups_\\\" ])\\ n\"\n "
177
+ " .ascii \" self.groups = self.cpo.to_address(self.table[\\\" arrays\\\" ][\\\" groups_\\\" ])\\ n\"\n "
178
+ " .ascii \" self.elements = self.cpo.to_address(self.table[\\\" arrays\\\" ][\\\" elements_\\\" ])\\ n\"\n "
179
+
180
+ " .ascii \" self.N = 15 # `self.groups.dereference()[\\\" N\\\" ]` may be optimized out\\ n\"\n "
181
+ " .ascii \" self.sentinel_ = 1 # `self.groups.dereference()[\\\" sentinel_\\\" ]` may be optimized out\\ n\"\n "
175
182
176
183
" .ascii \" def to_string(self):\\ n\"\n "
177
- " .ascii \" size = BoostUnorderedHelpers.maybe_unwrap_atomic(self.val[ \\\" table_ \\\" ] [\\\" size_ctrl\\\" ][\\\" size\\\" ])\\ n\"\n "
184
+ " .ascii \" size = BoostUnorderedHelpers.maybe_unwrap_atomic(self.table [\\\" size_ctrl\\\" ][\\\" size\\\" ])\\ n\"\n "
178
185
" .ascii \" return f\\\" {self.name} with {size} elements\\\"\\ n\"\n "
179
186
180
187
" .ascii \" def display_hint(self):\\ n\"\n "
@@ -204,30 +211,21 @@ __asm__(".pushsection \".debug_gdb_scripts\", \"MS\",%progbits,1\n"
204
211
" .ascii \" m = group[\\\" m\\\" ]\\ n\"\n "
205
212
" .ascii \" at = lambda b: BoostUnorderedHelpers.maybe_unwrap_atomic(m[b][\\\" n\\\" ])\\ n\"\n "
206
213
207
- " .ascii \" N = group[\\\" N\\\" ]\\ n\"\n "
208
- " .ascii \" sentinel_ = group[\\\" sentinel_\\\" ]\\ n\"\n "
209
214
" .ascii \" if self.is_regular_layout(group):\\ n\"\n "
210
- " .ascii \" return pos == N-1 and at(N-1) == sentinel_\\ n\"\n "
215
+ " .ascii \" return pos == self. N-1 and at(self. N-1) == self. sentinel_\\ n\"\n "
211
216
" .ascii \" else:\\ n\"\n "
212
- " .ascii \" return pos == N-1 and (at(0) & 0x4000400040004000) == 0x4000 and (at(1) & 0x4000400040004000) == 0\\ n\"\n "
217
+ " .ascii \" return pos == self. N-1 and (at(0) & 0x4000400040004000) == 0x4000 and (at(1) & 0x4000400040004000) == 0\\ n\"\n "
213
218
214
219
" .ascii \" def children(self):\\ n\"\n "
215
220
" .ascii \" def generator():\\ n\"\n "
216
- " .ascii \" table = self.val[\\\" table_\\\" ]\\ n\"\n "
217
- " .ascii \" groups = self.cpo.to_address(table[\\\" arrays\\\" ][\\\" groups_\\\" ])\\ n\"\n "
218
- " .ascii \" elements = self.cpo.to_address(table[\\\" arrays\\\" ][\\\" elements_\\\" ])\\ n\"\n "
219
-
220
- " .ascii \" pc_ = groups.cast(gdb.lookup_type(\\\" unsigned char\\\" ).pointer())\\ n\"\n "
221
- " .ascii \" p_ = elements\\ n\"\n "
221
+ " .ascii \" pc_ = self.groups.cast(gdb.lookup_type(\\\" unsigned char\\\" ).pointer())\\ n\"\n "
222
+ " .ascii \" p_ = self.elements\\ n\"\n "
222
223
" .ascii \" first_time = True\\ n\"\n "
223
- " .ascii \" mask = 0\\ n\"\n "
224
- " .ascii \" n0 = 0\\ n\"\n "
225
- " .ascii \" n = 0\\ n\"\n "
226
224
227
225
" .ascii \" count = 0\\ n\"\n "
228
226
" .ascii \" while p_ != 0:\\ n\"\n "
229
227
" .ascii \" # This if block mirrors the condition in the begin() call\\ n\"\n "
230
- " .ascii \" if (not first_time) or (self.match_occupied(groups.dereference()) & 1):\\ n\"\n "
228
+ " .ascii \" if (not first_time) or (self.match_occupied(self. groups.dereference()) & 1):\\ n\"\n "
231
229
" .ascii \" pointer = BoostUnorderedHelpers.maybe_unwrap_foa_element(p_)\\ n\"\n "
232
230
" .ascii \" value = self.cpo.to_address(pointer).dereference()\\ n\"\n "
233
231
" .ascii \" if self.is_map:\\ n\"\n "
@@ -241,17 +239,17 @@ __asm__(".pushsection \".debug_gdb_scripts\", \"MS\",%progbits,1\n"
241
239
" .ascii \" count += 1\\ n\"\n "
242
240
" .ascii \" first_time = False\\ n\"\n "
243
241
244
- " .ascii \" n0 = pc_.cast(gdb.lookup_type(\\\" uintptr_t\\\" )) % groups.dereference().type.sizeof\\ n\"\n "
242
+ " .ascii \" n0 = pc_.cast(gdb.lookup_type(\\\" uintptr_t\\\" )) % self. groups.dereference().type.sizeof\\ n\"\n "
245
243
" .ascii \" pc_ = self.cpo.next(pc_, -n0)\\ n\"\n "
246
244
247
- " .ascii \" mask = (self.match_occupied(pc_.cast(groups.type).dereference()) >> (n0+1)) << (n0+1)\\ n\"\n "
245
+ " .ascii \" mask = (self.match_occupied(pc_.cast(self. groups.type).dereference()) >> (n0+1)) << (n0+1)\\ n\"\n "
248
246
" .ascii \" while mask == 0:\\ n\"\n "
249
- " .ascii \" pc_ = self.cpo.next(pc_, groups.dereference().type.sizeof)\\ n\"\n "
250
- " .ascii \" p_ = self.cpo.next(p_, groups.dereference()[ \\\" N \\\" ] )\\ n\"\n "
251
- " .ascii \" mask = self.match_occupied(pc_.cast(groups.type).dereference())\\ n\"\n "
247
+ " .ascii \" pc_ = self.cpo.next(pc_, self. groups.dereference().type.sizeof)\\ n\"\n "
248
+ " .ascii \" p_ = self.cpo.next(p_, self.N )\\ n\"\n "
249
+ " .ascii \" mask = self.match_occupied(pc_.cast(self. groups.type).dereference())\\ n\"\n "
252
250
253
251
" .ascii \" n = BoostUnorderedHelpers.countr_zero(mask)\\ n\"\n "
254
- " .ascii \" if self.is_sentinel(pc_.cast(groups.type).dereference(), n):\\ n\"\n "
252
+ " .ascii \" if self.is_sentinel(pc_.cast(self. groups.type).dereference(), n):\\ n\"\n "
255
253
" .ascii \" p_ = 0\\ n\"\n "
256
254
" .ascii \" else:\\ n\"\n "
257
255
" .ascii \" pc_ = self.cpo.next(pc_, n)\\ n\"\n "
0 commit comments