mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-07-30 20:18:08 +00:00
Update Abseil raw_flat_hash visualization (#18329)
### Description <!-- Describe your changes. --> Fix the broken pieces due to the latest Abseil update. ### Motivation and Context <!-- - Why is this change required? What problem does it solve? Make the debugging bearable.
This commit is contained in:
parent
a0eeeafa80
commit
a37e6a503b
1 changed files with 39 additions and 13 deletions
52
cmake/external/abseil-cpp.natvis
vendored
52
cmake/external/abseil-cpp.natvis
vendored
|
|
@ -25,30 +25,56 @@
|
|||
</Type>
|
||||
<!-- Should handle both flat hash_set and hash_map -->
|
||||
<Type Name="absl::lts_20230802::container_internal::raw_hash_set<*>">
|
||||
<DisplayString Condition="size_ == 0">empty</DisplayString>
|
||||
<DisplayString>{{ size={size_} }}</DisplayString>
|
||||
<Intrinsic Name="_commonfields" Expression="settings_.value"/>
|
||||
<Intrinsic Name="_size" Expression="settings_.value.compressed_tuple_.value"/>
|
||||
<Intrinsic Name="_capacity" Expression="_commonfields().capacity_"/>
|
||||
<Intrinsic Name="_control" Expression="_commonfields().control_"/>
|
||||
<Intrinsic Name="_slots" Expression="(slot_type*)(_commonfields().slots_)"/>
|
||||
<DisplayString Condition="_size() == 0">empty</DisplayString>
|
||||
<DisplayString IncludeView="noparens">size={ _size() }</DisplayString>
|
||||
<DisplayString ExcludeView="noparens">size=({_size()})</DisplayString>
|
||||
<Expand>
|
||||
<Item Name="[size]" ExcludeView="simple">size_</Item>
|
||||
<Item Name="[capacity]" ExcludeView="simple">capacity_</Item>
|
||||
<CustomListItems MaxItemsPerView="5000">
|
||||
<Item Name="[Size]">_size()</Item>
|
||||
<Item Name="[Capacity]" ExcludeView="noparens">_capacity()</Item>
|
||||
<CustomListItems MaxItemsPerView="100">
|
||||
<Variable Name="nslot" InitialValue="0" />
|
||||
<Size>size_</Size>
|
||||
<Size>_size()</Size>
|
||||
<Loop>
|
||||
<!-- bool IsFull(ctrl_t c) const { return c >= 0; } -->
|
||||
<If Condition="ctrl_[nslot] >= 0">
|
||||
<Item>slots_[nslot]</Item>
|
||||
<If Condition="_control()[nslot] >= 0">
|
||||
<Item>_slots()[nslot]</Item>
|
||||
</If>
|
||||
<Exec>nslot++</Exec>
|
||||
<Break Condition="nslot == capacity_" />
|
||||
<Break Condition="nslot == _capacity()" />
|
||||
</Loop>
|
||||
</CustomListItems>
|
||||
</Expand>
|
||||
</Type>
|
||||
<Type Name="absl::lts_20230802::container_internal::map_slot_type<*>">
|
||||
<DisplayString>{{ {value.first}:{value.second} }}</DisplayString>
|
||||
|
||||
<!-- Primitive types stored as a value -->
|
||||
<Type Name="absl::lts_20230802::container_internal::Storage<*,*,0>">
|
||||
<DisplayString IncludeView="noparens">*($T1 *){value}</DisplayString>
|
||||
<DisplayString ExcludeView="noparens">(*($T1 *){value})</DisplayString>
|
||||
<Expand>
|
||||
<Item Name="[key]" ExcludeView="simple">value.first</Item>
|
||||
<Item Name="[value]" ExcludeView="simple">value.second</Item>
|
||||
<ExpandedItem>*($T1 *){value}</ExpandedItem>
|
||||
</Expand>
|
||||
</Type>
|
||||
|
||||
<!-- For storage inherited from the type -->
|
||||
<Type Name="absl::lts_20230802::container_internal::Storage<*,*,1>">
|
||||
<DisplayString IncludeView="noparens">*($T1 *)this</DisplayString>
|
||||
<DisplayString ExcludeView="noparens">(*($T1 *)this)</DisplayString>
|
||||
<Expand>
|
||||
<ExpandedItem>*($T1 *)this</ExpandedItem>
|
||||
</Expand>
|
||||
</Type>
|
||||
|
||||
<Type Name="absl::lts_20230802::container_internal::map_slot_type<*>">
|
||||
<DisplayString IncludeView="noparens">{value.first}, {value.second}</DisplayString>
|
||||
<DisplayString ExcludeView="noparens">({value.first}, {value.second})</DisplayString>
|
||||
<Expand>
|
||||
<Item Name="first" ExcludeView="simple">value.first</Item>
|
||||
<Item Name="second" ExcludeView="simple">value.second</Item>
|
||||
</Expand>
|
||||
</Type>
|
||||
</AutoVisualizer>
|
||||
|
|
|
|||
Loading…
Reference in a new issue