Skip to content

Commit

Permalink
Merge branch 'master' into drain_filter
Browse files Browse the repository at this point in the history
  • Loading branch information
mbrubeck authored Jun 15, 2023
2 parents 9367dcb + 0c56f1b commit 07a3c89
Show file tree
Hide file tree
Showing 6 changed files with 126 additions and 73 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ jobs:
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Install packages
if: matrix.os == 'ubuntu-latest'
run: sudo apt-get install -y binutils-dev libunwind8-dev libcurl4-openssl-dev libelf-dev libdw-dev cmake gcc libiberty-dev
run: sudo apt-get update -y && sudo apt-get install -y binutils-dev libunwind8-dev libcurl4-openssl-dev libelf-dev libdw-dev cmake gcc libiberty-dev

- name: Install toolchain
uses: actions-rs/toolchain@v1
Expand Down Expand Up @@ -98,4 +98,3 @@ jobs:
- name: Mark the job as unsuccessful
run: exit 1
if: "!success()"

2 changes: 1 addition & 1 deletion debug_metadata/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ The GNU debugger (GDB) supports defining custom debugger views using Pretty Prin
Pretty printers are written as python scripts that describe how a type should be displayed
when loaded up in GDB/LLDB. (See: https://sourceware.org/gdb/onlinedocs/gdb/Pretty-Printing.html#Pretty-Printing)
The pretty printers provide patterns, which match type names, and for matching
types, descibe how to display those types. (For writing a pretty printer, see: https://sourceware.org/gdb/onlinedocs/gdb/Writing-a-Pretty_002dPrinter.html#Writing-a-Pretty_002dPrinter).
types, describe how to display those types. (For writing a pretty printer, see: https://sourceware.org/gdb/onlinedocs/gdb/Writing-a-Pretty_002dPrinter.html#Writing-a-Pretty_002dPrinter).

### Embedding Visualizers

Expand Down
16 changes: 8 additions & 8 deletions debug_metadata/smallvec.natvis
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
<AutoVisualizer xmlns="http://schemas.microsoft.com/vstudio/debugger/natvis/2010">
<Type Name="smallvec::SmallVec&lt;array$&lt;*,*&gt;&gt;" Priority="Medium">
<Intrinsic Name="is_inline" Expression="$T2 &gt; capacity" />
<Intrinsic Name="len" Expression="is_inline() ? capacity : data.variant1.value.__0.__1" />
<Intrinsic Name="data_ptr" Expression="is_inline() ? data.variant0.value.__0.value.value : data.variant1.value.__0.__0" />
<Intrinsic Name="is_inline" Expression="$T2 &gt;= capacity" />
<Intrinsic Name="len" Expression="is_inline() ? capacity : data.variant1.value.len" />
<Intrinsic Name="data_ptr" Expression="is_inline() ? data.variant0.value.__0.value.value : data.variant1.value.ptr.pointer" />

<DisplayString>{{ len={len()} }}</DisplayString>
<DisplayString>{{ len={len()} is_inline={is_inline()} }}</DisplayString>
<Expand>
<Item Name="[capacity]">is_inline() ? $T2 : capacity</Item>
<Item Name="[len]">len()</Item>
<Item Name="[data_ptr]">data_ptr()</Item>

<ArrayItems>
<Size>len()</Size>
Expand All @@ -17,11 +18,10 @@
</Type>

<Type Name="smallvec::SmallVec&lt;array$&lt;*,*&gt;&gt;" Priority="MediumLow">
<Intrinsic Name="is_inline" Expression="$T2 &gt; capacity" />
<Intrinsic Name="is_inline" Expression="$T2 &gt;= capacity" />
<Intrinsic Name="len" Expression="is_inline() ? capacity : data.heap.__1" />
<Intrinsic Name="data_ptr" Expression="is_inline() ? data.inline.value.value.value : data.heap.__0" />

<DisplayString>{{ len={len()} }}</DisplayString>
<Intrinsic Name="data_ptr" Expression="is_inline() ? data.inline.value.value.value : data.heap.__0.pointer" />
<DisplayString>{{ len={len()} is_inline={is_inline()} }}</DisplayString>
<Expand>
<Item Name="[capacity]">is_inline() ? $T2 : capacity</Item>
<Item Name="[len]">len()</Item>
Expand Down
Loading

0 comments on commit 07a3c89

Please sign in to comment.