Skip to content

[Debugger Visualizers] Optimize lookup behavior#147552

Open
Walnut356 wants to merge 5 commits intorust-lang:mainfrom
Walnut356:cleanup
Open

[Debugger Visualizers] Optimize lookup behavior#147552
Walnut356 wants to merge 5 commits intorust-lang:mainfrom
Walnut356:cleanup

Conversation

@Walnut356
Copy link
Copy Markdown
Contributor

@Walnut356 Walnut356 commented Oct 10, 2025

View all comments

Background

Almost all of the commands in lldb_commands used a regex to associate a type with the synthetic_lookup and summary_lookup python functions. When looking up a type, LLDB iterates through the commands in reverse order (so that new commands can overwrite old ones), stopping when it finds a match. These lookups are cached, but it's a shallow cache (e.g. when Vec<T> is matched by lldb, it will always point to synthetic_lookup, NOT the result of synthetic_lookup which would be StdVecSyntheticProvider).

This becomes a problem because within synthetic_lookup and summary_lookup we run classify_rust_type which checks exact same regexes again. This causes 2 issues:

  1. running the regexes via lldb commands is even more of a waste because the final check is a .* regex that associates with synthetic_lookup anyway
  2. Every time lldb wants to display a value, that value must run the entirety of synthetic_lookup and run its type through 19 regexes + some assorted checks every single time. Those checks take between 1 and 100 microseconds depending on the type.

On a 10,000 element Vec<i32> (which bypasses classify_struct and therefore the 19 regexes), ~30 milliseconds are spent on classify_rust_type. For a 10,000 element Vec<UserDefinedStruct> that jumps up to ~350 milliseconds.

The salt on the wound is that some of those 19 regexes are useless (BTreeMap and BTreeSet which don't even have synthetic/summary providers so it doesn't matter if we know what type it is), and then the results of that lookup function use string-comparisons in a giant if...elif...elif chain.

Solution

To fix all of that, the lldb_commands now point directly to their appropriate synthetic/summary when possible. In cases where there was extra logic, streamlined functions have been added that have much fewer types being passed in, thus only need to do one or two simple checks (e.g. classify_hashmap and classify_hashset).

Some of the lldb_commands regexes were also consolidated to reduce the total number of commands we pass to lldb (e.g. NonZero

An extra upshot is that summary_lookup could be completely removed due to being redundant.

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Oct 10, 2025
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Oct 10, 2025

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@Zalathar
Copy link
Copy Markdown
Member

While I'm not comfortable reviewing this myself (and it might be tricky to find someone who is), I do want to at least say thanks for working on it.

@Walnut356
Copy link
Copy Markdown
Contributor Author

Walnut356 commented Oct 13, 2025

If it helps the review any, this is more or less how it should have been written from the start. The type synthetic add -l technically expects a python class (-l is short for --python-class), it's sortof a hack that we exploit LLDB not being able to differentiate between an initializer function and a flat function. It's nice because we can check extra bits of the value without callback-based type matching (which was only introduced in lldb 19.0), but I'm not sure why it was written the way it was in cases like Vec<T> that are unambiguous.

The MSVC providers I added a while ago already point directly to the initializer rather than taking a trip through synthetic_lookup and summary_lookup first. This patch just applies that to all of the commands because it's significantly faster.

There shouldn't be any actual changes for end-users (aside from IndirectionSyntheticProvider fixing a minor bug with pointer types).

@Mark-Simulacrum
Copy link
Copy Markdown
Member

r=me if this is still ready to go (not sure if other changes have landed in the last month that make a rebase make sense). I think we can land this and revert/revisit if it runs into issues, the description makes sense to me and the changes seem reasonable.

Copy link
Copy Markdown
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes also look sensible to me. Given that at worst we can revert, let's merge this.

View changes since this review

@jieyouxu
Copy link
Copy Markdown
Member

@bors r=Mark-Simulacrum,jieyouxu rollup

@bors
Copy link
Copy Markdown
Collaborator

bors commented Nov 12, 2025

📌 Commit 2e8e618 has been approved by Mark-Simulacrum,jieyouxu

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Nov 12, 2025
@jieyouxu
Copy link
Copy Markdown
Member

Uh actually @Walnut356, this doesn't need a rebase or anything, right? If not, please r= us
@bors r-
@bors delegate+

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Nov 12, 2025
@bors
Copy link
Copy Markdown
Collaborator

bors commented Nov 12, 2025

✌️ @Walnut356, you can now approve this pull request!

If @jieyouxu told you to "r=me" after making some further change, please make that change, then do @bors r=@jieyouxu

@Walnut356
Copy link
Copy Markdown
Contributor Author

@bors r=@jieyouxu

@bors
Copy link
Copy Markdown
Collaborator

bors commented Nov 15, 2025

📌 Commit 2e8e618 has been approved by jieyouxu

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Nov 15, 2025
@jieyouxu
Copy link
Copy Markdown
Member

@bors r=Mark-Simulacrum,jieyouxu

@bors
Copy link
Copy Markdown
Collaborator

bors commented Nov 15, 2025

💡 This pull request was already approved, no need to approve it again.

@bors
Copy link
Copy Markdown
Collaborator

bors commented Nov 15, 2025

📌 Commit 2e8e618 has been approved by Mark-Simulacrum,jieyouxu

It is now in the queue for this repository.

@bors
Copy link
Copy Markdown
Collaborator

bors commented Nov 15, 2025

⌛ Testing commit 2e8e618 with merge 3d00472...

bors added a commit that referenced this pull request Nov 15, 2025
[Debugger Visualizers] Optimize lookup behavior

# Background

Almost all of the commands in `lldb_commands` used a regex to associate a type with the `synthetic_lookup` and `summary_lookup` python functions. When looking up a type, LLDB iterates through the commands in reverse order (so that new commands can overwrite old ones), stopping when it finds a match. These lookups are cached, but it's a shallow cache (e.g. when `Vec<T>` is matched by lldb, it will always point to `synthetic_lookup`, NOT the result of `synthetic_lookup` which would be `StdVecSyntheticProvider`).

This becomes a problem because within `synthetic_lookup` and `summary_lookup` we run `classify_rust_type` which checks exact same regexes again. This causes 2 issues:

1. running the regexes via lldb commands is even more of a waste because the final check is a `.*` regex that associates with `synthetic_lookup` anyway
2. Every time lldb wants to display a value, that value must run the entirety of `synthetic_lookup` and run its type through 19 regexes + some assorted checks every single time. Those checks take between 1 and 100 microseconds depending on the type.

On a 10,000 element `Vec<i32>` (which bypasses `classify_struct` and therefore the 19 regexes), ~30 milliseconds are spent on `classify_rust_type`. For a 10,000 element `Vec<UserDefinedStruct>` that jumps up to ~350 milliseconds.

The salt on the wound is that some of those 19 regexes are useless (`BTreeMap` and `BTreeSet` which don't even have synthetic/summary providers so it doesn't matter if we know what type it is), and then the results of that lookup function use string-comparisons in a giant `if...elif...elif` chain.

# Solution

To fix all of that, the `lldb_commands` now point directly to their appropriate synthetic/summary when possible. In cases where there was extra logic, streamlined functions have been added that have much fewer types being passed in, thus only need to do one or two  simple checks (e.g. `classify_hashmap` and `classify_hashset`).

Some of the `lldb_commands` regexes were also consolidated to reduce the total number of commands we pass to lldb (e.g. `NonZero`

An extra upshot is that `summary_lookup` could be completely removed due to being redundant.
@rust-log-analyzer

This comment has been minimized.

@bors
Copy link
Copy Markdown
Collaborator

bors commented Nov 15, 2025

💔 Test failed - checks-actions

@bors bors removed the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Nov 15, 2025
@bors bors added the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Dec 20, 2025
@Kivooeo
Copy link
Copy Markdown
Member

Kivooeo commented Dec 20, 2025

@bors try jobs=aarch64-apple

@rust-bors

This comment has been minimized.

rust-bors bot added a commit that referenced this pull request Dec 20, 2025
[Debugger Visualizers] Optimize lookup behavior

try-job: aarch64-apple
@rust-log-analyzer

This comment has been minimized.

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Dec 20, 2025

💔 Test for a74aee3 failed: CI. Failed jobs:

@Walnut356
Copy link
Copy Markdown
Contributor Author

@rustbot review

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Dec 21, 2025
@Kivooeo
Copy link
Copy Markdown
Member

Kivooeo commented Dec 21, 2025

@bors try jobs=aarch64-apple

rust-bors bot added a commit that referenced this pull request Dec 21, 2025
[Debugger Visualizers] Optimize lookup behavior

try-job: aarch64-apple
@rust-bors

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Dec 21, 2025

💔 Test for f99edd6 failed: CI. Failed jobs:

@Kivooeo Kivooeo added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Dec 21, 2025
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Mar 31, 2026

This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed.

Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers.

@Walnut356
Copy link
Copy Markdown
Contributor Author

I think the tests should be fixed. Reminder that this needs to be run through aarch64-apple before being merged.

Also one of the tests might fail due to how old the version of LLDB is on that test runner? It's missing a fairly important API that was added in LLDB 18 iirc. I'm not sure though. If it does, we can just disable the test for now i guess.

@Zalathar
Copy link
Copy Markdown
Member

@bors try jobs=aarch64-apple

@rust-bors

This comment has been minimized.

rust-bors bot pushed a commit that referenced this pull request Mar 31, 2026
[Debugger Visualizers] Optimize lookup behavior


try-job: aarch64-apple
@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Mar 31, 2026

💔 Test for 993b5d3 failed: CI. Failed job:

@rust-log-analyzer
Copy link
Copy Markdown
Collaborator

The job aarch64-apple failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)

---- [debuginfo-lldb] tests/debuginfo/c-style-enum-in-composite.rs stdout ----
NOTE: compiletest thinks it is using LLDB version 1703

error: check directive(s) from `/Users/runner/work/rust/rust/tests/debuginfo/c-style-enum-in-composite.rs` not found in debugger output. errors:
    (c-style-enum-in-composite.rs:53) `[...] ({ a = OneHundred b = Vienna }, 9)`
the following subset of check directive(s) was found successfully:
    (c-style-enum-in-composite.rs:35) `((i16, c_style_enum_in_composite::AnEnum)) tuple_interior_padding = (0, OneHundred) `
    (c-style-enum-in-composite.rs:38) `(((u64, c_style_enum_in_composite::AnEnum), u64)) tuple_padding_at_end = ((1, OneThousand), 2) `
    (c-style-enum-in-composite.rs:41) `((c_style_enum_in_composite::AnEnum, c_style_enum_in_composite::AnotherEnum, c_style_enum_in_composite::AnEnum, c_style_enum_in_composite::AnotherEnum)) tuple_different_enums = (OneThousand, MountainView, OneMillion, Vienna) `
    (c-style-enum-in-composite.rs:44) `(c_style_enum_in_composite::PaddedStruct) padded_struct = { a = 3 b = OneMillion c = 4 d = Toronto e = 5 } `
    (c-style-enum-in-composite.rs:47) `(c_style_enum_in_composite::PackedStruct) packed_struct = { a = 6 b = OneHundred c = 7 d = Vienna e = 8 } `
    (c-style-enum-in-composite.rs:50) `(c_style_enum_in_composite::NonPaddedStruct) non_padded_struct = { a = OneMillion b = MountainView c = OneThousand d = Toronto } `
status: exit status: 0
command: LLDB_BATCHMODE_SCRIPT_PATH="/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/c-style-enum-in-composite.lldb/c-style-enum-in-composite.debugger.script" LLDB_BATCHMODE_TARGET_PATH="/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/c-style-enum-in-composite.lldb/a" PYTHONPATH="/Users/runner/work/rust/rust/src/etc" PYTHONUNBUFFERED="1" "lldb" "--one-line" "script --language python -- import lldb_batchmode; lldb_batchmode.main()"
--- stdout -------------------------------
(lldb) script --language python -- import lldb_batchmode; lldb_batchmode.main()
LLDB batch-mode script
----------------------
Debugger commands script is '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/c-style-enum-in-composite.lldb/c-style-enum-in-composite.debugger.script'.
Target executable is '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/c-style-enum-in-composite.lldb/a'.
Current working directory is '/Users/runner/work/rust/rust'
Creating a target for '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/c-style-enum-in-composite.lldb/a'
settings set auto-confirm true

settings set target.inherit-tcc true

version
lldb-1703.0.236.21 Apple Swift version 6.2.3 (swiftlang-6.2.3.3.21 clang-1700.6.3.2) 
command script import /Users/runner/work/rust/rust/src/etc/lldb_lookup.py
# LLDB iterates through these in reverse order to discover summaries/synthetics that means the top
# of the list can be "overwritten" by items lower on the list. Be careful when reordering items.
# Forces test-compliant formatting to all other types
type synthetic add -l lldb_lookup.synthetic_lookup -x ".*" --category Rust
# Std String
type synthetic add -l lldb_lookup.StdStringSyntheticProvider -x "^(alloc::([a-z_]+::)+)String$" --category Rust
type summary add -F lldb_lookup.StdStringSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)String$" --category Rust
# Std str
type synthetic add -l lldb_lookup.StdSliceSyntheticProvider -x "^&(mut )?str$" --category Rust
type summary add -F lldb_lookup.StdStrSummaryProvider -e -x -h "^&(mut )?str$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCStrSyntheticProvider -x "^ref(_mut)?\$<str\$>$" --category Rust
type summary add -F lldb_lookup.StdStrSummaryProvider -e -h -x "^ref(_mut)?\$<str\$>$" --category Rust
# Array/Slice
type synthetic add -l lldb_lookup.StdSliceSyntheticProvider -x "^&(mut )?\\[.+\\]$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^&(mut )?\\[.+\\]$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCStdSliceSyntheticProvider -x "^ref(_mut)?\$<slice2\$<.+> >" --category Rust
type summary add -F lldb_lookup.StdSliceSummaryProvider -e -x -h "^ref(_mut)?\$<slice2\$<.+> >" --category Rust
# OsString
type summary add -F lldb_lookup.StdOsStringSummaryProvider -e -x -h "^(std::ffi::([a-z_]+::)+)OsString$" --category Rust
# Vec
type synthetic add -l lldb_lookup.StdVecSyntheticProvider -x "^(alloc::([a-z_]+::)+)Vec<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Vec<.+>$" --category Rust
# VecDeque
type synthetic add -l lldb_lookup.StdVecDequeSyntheticProvider -x "^(alloc::([a-z_]+::)+)VecDeque<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)VecDeque<.+>$" --category Rust
# HashMap
type synthetic add -l lldb_lookup.classify_hashmap -x "^(std::collections::([a-z_]+::)+)HashMap<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(std::collections::([a-z_]+::)+)HashMap<.+>$" --category Rust
# HashSet
type synthetic add -l lldb_lookup.classify_hashset -x "^(std::collections::([a-z_]+::)+)HashSet<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(std::collections::([a-z_]+::)+)HashSet<.+>$" --category Rust
# Rc
type synthetic add -l lldb_lookup.StdRcSyntheticProvider -x "^(alloc::([a-z_]+::)+)Rc<.+>$" --category Rust
type summary add -F lldb_lookup.StdRcSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Rc<.+>$" --category Rust
# Arc
type synthetic add -l lldb_lookup.arc_synthetic -x "^(alloc::([a-z_]+::)+)Arc<.+>$" --category Rust
type summary add -F lldb_lookup.StdRcSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Arc<.+>$" --category Rust
# Cell
type synthetic add -l lldb_lookup.StdCellSyntheticProvider -x "^(core::([a-z_]+::)+)Cell<.+>$" --category Rust
# RefCell
type synthetic add -l lldb_lookup.StdRefSyntheticProvider -x "^(core::([a-z_]+::)+)Ref(Cell|Mut)?<.+>$" --category Rust
type summary add -F lldb_lookup.StdRefSummaryProvider -e -x -h "^(core::([a-z_]+::)+)Ref(Cell|Mut)?<.+>$" --category Rust
# NonZero
type summary add -F lldb_lookup.StdNonZeroNumberSummaryProvider -e -x -h "^(core::([a-z_]+::)+)NonZero(<.+>|I\d{0,3}|U\d{0,3})$" --category Rust
# PathBuf
type summary add -F lldb_lookup.StdPathBufSummaryProvider -e -x -h "^(std::([a-z_]+::)+)PathBuf$" --category Rust
# Path
type summary add -F lldb_lookup.StdPathSummaryProvider -e -x -h "^&(mut )?(std::([a-z_]+::)+)Path$" --category Rust
# Enum
# type summary add -F lldb_lookup.ClangEncodedEnumSummaryProvider -e -h "lldb_lookup.is_sum_type_enum" --recognizer-function --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCEnumSyntheticProvider -x "^enum2\$<.+>$" --category Rust
type summary add -F lldb_lookup.MSVCEnumSummaryProvider -e -x -h "^enum2\$<.+>$" --category Rust
## MSVC Variants
type synthetic add -l lldb_lookup.synthetic_lookup -x "^enum2\$<.+>::.*$" --category Rust
# Tuple
type synthetic add -l lldb_lookup.TupleSyntheticProvider -x "^\(.*\)$" --category Rust
type summary add -F lldb_lookup.TupleSummaryProvider -x "^\(.*\)$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCTupleSyntheticProvider -x "^tuple\$<.+>$" --category Rust
type summary add -F lldb_lookup.TupleSummaryProvider -e -x -h "^tuple\$<.+>$" --category Rust
type category enable Rust

breakpoint set --file 'c-style-enum-in-composite.rs' --line 137
DEBUG: breakpoint added, id = 1
Breakpoint 1: where = a`c_style_enum_in_composite::main + 192 at c-style-enum-in-composite.rs:137:5, address = 0x00000001000008dc 
DEBUG: registering breakpoint callback, id = 1
Error while trying to register breakpoint callback, id = 1, message = error: could not get num args: can't find callable: breakpoint_callback

run
Process 29882 launched: '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/c-style-enum-in-composite.lldb/a' (arm64) Process 29882 stopped * thread #1, name = 'main', queue = 'com.apple.main-thread', stop reason = breakpoint 1.1 frame #0: 0x00000001000008dc a`c_style_enum_in_composite::main at c-style-enum-in-composite.rs:137:5 134 135 let struct_with_drop = (StructWithDrop { a: OneHundred, b: Vienna }, 9_i64); 136 -> 137 zzz(); // #break ^ 138 } 139 140 fn zzz() { () } Target 0: (a) stopped. 
v tuple_interior_padding
((i16, c_style_enum_in_composite::AnEnum)) tuple_interior_padding = (0, OneHundred) 
v tuple_padding_at_end
(((u64, c_style_enum_in_composite::AnEnum), u64)) tuple_padding_at_end = ((1, OneThousand), 2) 
v tuple_different_enums
((c_style_enum_in_composite::AnEnum, c_style_enum_in_composite::AnotherEnum, c_style_enum_in_composite::AnEnum, c_style_enum_in_composite::AnotherEnum)) tuple_different_enums = (OneThousand, MountainView, OneMillion, Vienna) 
v padded_struct
(c_style_enum_in_composite::PaddedStruct) padded_struct = { a = 3 b = OneMillion c = 4 d = Toronto e = 5 } 
v packed_struct
(c_style_enum_in_composite::PackedStruct) packed_struct = { a = 6 b = OneHundred c = 7 d = Vienna e = 8 } 
v non_padded_struct
(c_style_enum_in_composite::NonPaddedStruct) non_padded_struct = { a = OneMillion b = MountainView c = OneThousand d = Toronto } 
v struct_with_drop
((c_style_enum_in_composite::StructWithDrop, i64)) struct_with_drop = ({a:OneHundred, b:Vienna}, 9) 
quit
------------------------------------------
--- stderr -------------------------------
warning: This version of LLDB has no plugin for the language "rust". Inspection of frame variables will be limited.
------------------------------------------

---- [debuginfo-lldb] tests/debuginfo/c-style-enum-in-composite.rs stdout end ----
---- [debuginfo-lldb] tests/debuginfo/destructured-local.rs stdout ----
NOTE: compiletest thinks it is using LLDB version 1703

error: check directive(s) from `/Users/runner/work/rust/rust/tests/debuginfo/destructured-local.rs` not found in debugger output. errors:
    (destructured-local.rs:202) `[...] (40, 41, 42`
the following subset of check directive(s) was found successfully:
    (destructured-local.rs:125) `DEBUG: breakpoint added, id = 1`
    (destructured-local.rs:127) `(bool) b = false `
    (destructured-local.rs:130) `(long) c = 2 `
    (destructured-local.rs:132) `(unsigned short) d = 3 `
    (destructured-local.rs:134) `(unsigned short) e = 4 `
    (destructured-local.rs:137) `(long) f = 5 `
    (destructured-local.rs:139) `((u32, u32)) g = (6, 7) `
    (destructured-local.rs:142) `(short) h = 8 `
    (destructured-local.rs:144) `(destructured_local::Struct) i = { a = 9 b = 10 } `
    (destructured-local.rs:146) `(short) j = 11 `
    (destructured-local.rs:149) `(long) k = 12 `
    (destructured-local.rs:151) `(int) l = 13 `
    (destructured-local.rs:154) `(int) m = 14 `
    (destructured-local.rs:156) `(int) n = 16 `
    (destructured-local.rs:159) `(int) o = 18 `
    (destructured-local.rs:162) `(long) p = 19 `
    (destructured-local.rs:164) `(int) q = 20 `
    (destructured-local.rs:166) `(destructured_local::Struct) r = { a = 21 b = 22 } `
    (destructured-local.rs:169) `(int) s = 24 `
    (destructured-local.rs:171) `(long) t = 23 `
    (destructured-local.rs:174) `(int) u = 25 `
    (destructured-local.rs:176) `(int) v = 26 `
    (destructured-local.rs:178) `(int) w = 27 `
    (destructured-local.rs:180) `(int) x = 28 `
    (destructured-local.rs:182) `(long) y = 29 `
    (destructured-local.rs:184) `(int) z = 30 `
    (destructured-local.rs:186) `(long) ae = 31 `
    (destructured-local.rs:188) `(int) oe = 32 `
    (destructured-local.rs:190) `(int) ue = 33 `
    (destructured-local.rs:193) `((i32, i32)) aa = (34, 35) `
    (destructured-local.rs:196) `((i32, i32)) bb = (36, 37) `
    (destructured-local.rs:199) `(int) cc = 38 `
    (destructured-local.rs:205) `((i32, i32, i32)) *ee = (43, 44, 45) `
    (destructured-local.rs:208) `(int) *ff = 46 `
    (destructured-local.rs:211) `((i32, i32)) gg = (47, 48) `
    (destructured-local.rs:214) `(int) *hh = 50 `
    (destructured-local.rs:217) `(int) ii = 51 `
    (destructured-local.rs:220) `(int) *jj = 52 `
    (destructured-local.rs:223) `(double) kk = 53 `
    (destructured-local.rs:226) `(long) ll = 54 `
    (destructured-local.rs:229) `(double) mm = 55 `
    (destructured-local.rs:232) `(long) *nn = 56 `
status: exit status: 0
command: LLDB_BATCHMODE_SCRIPT_PATH="/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/destructured-local.lldb/destructured-local.debugger.script" LLDB_BATCHMODE_TARGET_PATH="/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/destructured-local.lldb/a" PYTHONPATH="/Users/runner/work/rust/rust/src/etc" PYTHONUNBUFFERED="1" "lldb" "--one-line" "script --language python -- import lldb_batchmode; lldb_batchmode.main()"
--- stdout -------------------------------
(lldb) script --language python -- import lldb_batchmode; lldb_batchmode.main()
LLDB batch-mode script
----------------------
Debugger commands script is '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/destructured-local.lldb/destructured-local.debugger.script'.
Target executable is '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/destructured-local.lldb/a'.
Current working directory is '/Users/runner/work/rust/rust'
Creating a target for '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/destructured-local.lldb/a'
settings set auto-confirm true

settings set target.inherit-tcc true

version
lldb-1703.0.236.21 Apple Swift version 6.2.3 (swiftlang-6.2.3.3.21 clang-1700.6.3.2) 
command script import /Users/runner/work/rust/rust/src/etc/lldb_lookup.py
# LLDB iterates through these in reverse order to discover summaries/synthetics that means the top
# of the list can be "overwritten" by items lower on the list. Be careful when reordering items.
# Forces test-compliant formatting to all other types
type synthetic add -l lldb_lookup.synthetic_lookup -x ".*" --category Rust
# Std String
type synthetic add -l lldb_lookup.StdStringSyntheticProvider -x "^(alloc::([a-z_]+::)+)String$" --category Rust
type summary add -F lldb_lookup.StdStringSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)String$" --category Rust
# Std str
type synthetic add -l lldb_lookup.StdSliceSyntheticProvider -x "^&(mut )?str$" --category Rust
type summary add -F lldb_lookup.StdStrSummaryProvider -e -x -h "^&(mut )?str$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCStrSyntheticProvider -x "^ref(_mut)?\$<str\$>$" --category Rust
type summary add -F lldb_lookup.StdStrSummaryProvider -e -h -x "^ref(_mut)?\$<str\$>$" --category Rust
# Array/Slice
type synthetic add -l lldb_lookup.StdSliceSyntheticProvider -x "^&(mut )?\\[.+\\]$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^&(mut )?\\[.+\\]$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCStdSliceSyntheticProvider -x "^ref(_mut)?\$<slice2\$<.+> >" --category Rust
type summary add -F lldb_lookup.StdSliceSummaryProvider -e -x -h "^ref(_mut)?\$<slice2\$<.+> >" --category Rust
# OsString
type summary add -F lldb_lookup.StdOsStringSummaryProvider -e -x -h "^(std::ffi::([a-z_]+::)+)OsString$" --category Rust
# Vec
type synthetic add -l lldb_lookup.StdVecSyntheticProvider -x "^(alloc::([a-z_]+::)+)Vec<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Vec<.+>$" --category Rust
# VecDeque
type synthetic add -l lldb_lookup.StdVecDequeSyntheticProvider -x "^(alloc::([a-z_]+::)+)VecDeque<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)VecDeque<.+>$" --category Rust
# HashMap
type synthetic add -l lldb_lookup.classify_hashmap -x "^(std::collections::([a-z_]+::)+)HashMap<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(std::collections::([a-z_]+::)+)HashMap<.+>$" --category Rust
# HashSet
type synthetic add -l lldb_lookup.classify_hashset -x "^(std::collections::([a-z_]+::)+)HashSet<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(std::collections::([a-z_]+::)+)HashSet<.+>$" --category Rust
# Rc
type synthetic add -l lldb_lookup.StdRcSyntheticProvider -x "^(alloc::([a-z_]+::)+)Rc<.+>$" --category Rust
type summary add -F lldb_lookup.StdRcSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Rc<.+>$" --category Rust
# Arc
type synthetic add -l lldb_lookup.arc_synthetic -x "^(alloc::([a-z_]+::)+)Arc<.+>$" --category Rust
type summary add -F lldb_lookup.StdRcSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Arc<.+>$" --category Rust
# Cell
type synthetic add -l lldb_lookup.StdCellSyntheticProvider -x "^(core::([a-z_]+::)+)Cell<.+>$" --category Rust
# RefCell
type synthetic add -l lldb_lookup.StdRefSyntheticProvider -x "^(core::([a-z_]+::)+)Ref(Cell|Mut)?<.+>$" --category Rust
type summary add -F lldb_lookup.StdRefSummaryProvider -e -x -h "^(core::([a-z_]+::)+)Ref(Cell|Mut)?<.+>$" --category Rust
# NonZero
type summary add -F lldb_lookup.StdNonZeroNumberSummaryProvider -e -x -h "^(core::([a-z_]+::)+)NonZero(<.+>|I\d{0,3}|U\d{0,3})$" --category Rust
# PathBuf
type summary add -F lldb_lookup.StdPathBufSummaryProvider -e -x -h "^(std::([a-z_]+::)+)PathBuf$" --category Rust
# Path
type summary add -F lldb_lookup.StdPathSummaryProvider -e -x -h "^&(mut )?(std::([a-z_]+::)+)Path$" --category Rust
# Enum
# type summary add -F lldb_lookup.ClangEncodedEnumSummaryProvider -e -h "lldb_lookup.is_sum_type_enum" --recognizer-function --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCEnumSyntheticProvider -x "^enum2\$<.+>$" --category Rust
type summary add -F lldb_lookup.MSVCEnumSummaryProvider -e -x -h "^enum2\$<.+>$" --category Rust
## MSVC Variants
type synthetic add -l lldb_lookup.synthetic_lookup -x "^enum2\$<.+>::.*$" --category Rust
# Tuple
type synthetic add -l lldb_lookup.TupleSyntheticProvider -x "^\(.*\)$" --category Rust
type summary add -F lldb_lookup.TupleSummaryProvider -x "^\(.*\)$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCTupleSyntheticProvider -x "^tuple\$<.+>$" --category Rust
type summary add -F lldb_lookup.TupleSummaryProvider -e -x -h "^tuple\$<.+>$" --category Rust
type category enable Rust

breakpoint set --file 'destructured-local.rs' --line 317
DEBUG: breakpoint added, id = 1
Breakpoint 1: where = a`destructured_local::main + 972 at destructured-local.rs:317:5, address = 0x0000000100000c6c 
DEBUG: registering breakpoint callback, id = 1
Error while trying to register breakpoint callback, id = 1, message = error: could not get num args: can't find callable: breakpoint_callback

run
Process 30738 launched: '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/destructured-local.lldb/a' (arm64) Process 30738 stopped * thread #1, name = 'main', queue = 'com.apple.main-thread', stop reason = breakpoint 1.1 frame #0: 0x0000000100000c6c a`destructured_local::main at destructured-local.rs:317:5 314 // tuple struct with ref binding 315 let &TupleStruct(mm, ref nn) = &TupleStruct(55.0, 56); 316 -> 317 zzz(); // #break ^ 318 } 319 320 fn zzz() { () } Target 0: (a) stopped. 
v a
(long) a = 1 
v b
(bool) b = false 
v c
---
(unsigned short) e = 4 
v f
(long) f = 5 
v g
((u32, u32)) g = (6, 7) 
v h
(short) h = 8 
v i
(destructured_local::Struct) i = { a = 9 b = 10 } 
v j
(short) j = 11 
v k
(long) k = 12 
v l
(int) l = 13 
v m
---
(long) p = 19 
v q
(int) q = 20 
v r
(destructured_local::Struct) r = { a = 21 b = 22 } 
v s
(int) s = 24 
v t
(long) t = 23 
v u
(int) u = 25 
v v
(int) v = 26 
v w
(int) w = 27 
v x
(int) x = 28 
v y
(long) y = 29 
v z
(int) z = 30 
v ae
(long) ae = 31 
v oe
(int) oe = 32 
v ue
(int) ue = 33 
v aa
((i32, i32)) aa = (34, 35) 
v bb
((i32, i32)) bb = (36, 37) 
v cc
(int) cc = 38 
v dd
((i32, i32, i32)) dd = (40, 41, 42) 
v *ee
((i32, i32, i32)) *ee = (43, 44, 45) 
v *ff
(int) *ff = 46 
v gg
((i32, i32)) gg = (47, 48) 
v *hh
(int) *hh = 50 
v ii
(int) ii = 51 
v *jj
(int) *jj = 52 
v kk
(double) kk = 53 
v ll
(long) ll = 54 
v mm
(double) mm = 55 
v *nn
(long) *nn = 56 
quit
------------------------------------------
--- stderr -------------------------------
warning: This version of LLDB has no plugin for the language "rust". Inspection of frame variables will be limited.
------------------------------------------

---- [debuginfo-lldb] tests/debuginfo/destructured-local.rs stdout end ----
---- [debuginfo-lldb] tests/debuginfo/simple-tuple.rs stdout ----
NOTE: compiletest thinks it is using LLDB version 1703

error: check directive(s) from `/Users/runner/work/rust/rust/tests/debuginfo/simple-tuple.rs` not found in debugger output. errors:
    (simple-tuple.rs:66) `[...] (-100, 100)`
the following subset of check directive(s) was found successfully:
    (simple-tuple.rs:68) `((i16, i16, u16)) noPadding16 = (0, 1, 2) `
    (simple-tuple.rs:70) `((i32, f32, u32)) noPadding32 = (3, 4.5, 5) `
    (simple-tuple.rs:72) `((i64, f64, u64)) noPadding64 = (6, 7.5, 8) `
    (simple-tuple.rs:75) `((i16, i32)) internalPadding1 = (9, 10) `
    (simple-tuple.rs:77) `((i16, i32, u32, u64)) internalPadding2 = (11, 12, 13, 14) `
    (simple-tuple.rs:80) `((i32, i16)) paddingAtEnd = (15, 16) `
status: exit status: 0
command: LLDB_BATCHMODE_SCRIPT_PATH="/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/simple-tuple.lldb/simple-tuple.debugger.script" LLDB_BATCHMODE_TARGET_PATH="/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/simple-tuple.lldb/a" PYTHONPATH="/Users/runner/work/rust/rust/src/etc" PYTHONUNBUFFERED="1" "lldb" "--one-line" "script --language python -- import lldb_batchmode; lldb_batchmode.main()"
--- stdout -------------------------------
(lldb) script --language python -- import lldb_batchmode; lldb_batchmode.main()
LLDB batch-mode script
----------------------
Debugger commands script is '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/simple-tuple.lldb/simple-tuple.debugger.script'.
Target executable is '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/simple-tuple.lldb/a'.
Current working directory is '/Users/runner/work/rust/rust'
Creating a target for '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/simple-tuple.lldb/a'
settings set auto-confirm true

settings set target.inherit-tcc true

version
lldb-1703.0.236.21 Apple Swift version 6.2.3 (swiftlang-6.2.3.3.21 clang-1700.6.3.2) 
command script import /Users/runner/work/rust/rust/src/etc/lldb_lookup.py
# LLDB iterates through these in reverse order to discover summaries/synthetics that means the top
# of the list can be "overwritten" by items lower on the list. Be careful when reordering items.
# Forces test-compliant formatting to all other types
type synthetic add -l lldb_lookup.synthetic_lookup -x ".*" --category Rust
# Std String
type synthetic add -l lldb_lookup.StdStringSyntheticProvider -x "^(alloc::([a-z_]+::)+)String$" --category Rust
type summary add -F lldb_lookup.StdStringSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)String$" --category Rust
# Std str
type synthetic add -l lldb_lookup.StdSliceSyntheticProvider -x "^&(mut )?str$" --category Rust
type summary add -F lldb_lookup.StdStrSummaryProvider -e -x -h "^&(mut )?str$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCStrSyntheticProvider -x "^ref(_mut)?\$<str\$>$" --category Rust
type summary add -F lldb_lookup.StdStrSummaryProvider -e -h -x "^ref(_mut)?\$<str\$>$" --category Rust
# Array/Slice
type synthetic add -l lldb_lookup.StdSliceSyntheticProvider -x "^&(mut )?\\[.+\\]$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^&(mut )?\\[.+\\]$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCStdSliceSyntheticProvider -x "^ref(_mut)?\$<slice2\$<.+> >" --category Rust
type summary add -F lldb_lookup.StdSliceSummaryProvider -e -x -h "^ref(_mut)?\$<slice2\$<.+> >" --category Rust
# OsString
type summary add -F lldb_lookup.StdOsStringSummaryProvider -e -x -h "^(std::ffi::([a-z_]+::)+)OsString$" --category Rust
# Vec
type synthetic add -l lldb_lookup.StdVecSyntheticProvider -x "^(alloc::([a-z_]+::)+)Vec<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Vec<.+>$" --category Rust
# VecDeque
type synthetic add -l lldb_lookup.StdVecDequeSyntheticProvider -x "^(alloc::([a-z_]+::)+)VecDeque<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)VecDeque<.+>$" --category Rust
# HashMap
type synthetic add -l lldb_lookup.classify_hashmap -x "^(std::collections::([a-z_]+::)+)HashMap<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(std::collections::([a-z_]+::)+)HashMap<.+>$" --category Rust
# HashSet
type synthetic add -l lldb_lookup.classify_hashset -x "^(std::collections::([a-z_]+::)+)HashSet<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(std::collections::([a-z_]+::)+)HashSet<.+>$" --category Rust
# Rc
type synthetic add -l lldb_lookup.StdRcSyntheticProvider -x "^(alloc::([a-z_]+::)+)Rc<.+>$" --category Rust
type summary add -F lldb_lookup.StdRcSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Rc<.+>$" --category Rust
# Arc
type synthetic add -l lldb_lookup.arc_synthetic -x "^(alloc::([a-z_]+::)+)Arc<.+>$" --category Rust
type summary add -F lldb_lookup.StdRcSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Arc<.+>$" --category Rust
# Cell
type synthetic add -l lldb_lookup.StdCellSyntheticProvider -x "^(core::([a-z_]+::)+)Cell<.+>$" --category Rust
# RefCell
type synthetic add -l lldb_lookup.StdRefSyntheticProvider -x "^(core::([a-z_]+::)+)Ref(Cell|Mut)?<.+>$" --category Rust
type summary add -F lldb_lookup.StdRefSummaryProvider -e -x -h "^(core::([a-z_]+::)+)Ref(Cell|Mut)?<.+>$" --category Rust
# NonZero
type summary add -F lldb_lookup.StdNonZeroNumberSummaryProvider -e -x -h "^(core::([a-z_]+::)+)NonZero(<.+>|I\d{0,3}|U\d{0,3})$" --category Rust
# PathBuf
type summary add -F lldb_lookup.StdPathBufSummaryProvider -e -x -h "^(std::([a-z_]+::)+)PathBuf$" --category Rust
# Path
type summary add -F lldb_lookup.StdPathSummaryProvider -e -x -h "^&(mut )?(std::([a-z_]+::)+)Path$" --category Rust
# Enum
# type summary add -F lldb_lookup.ClangEncodedEnumSummaryProvider -e -h "lldb_lookup.is_sum_type_enum" --recognizer-function --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCEnumSyntheticProvider -x "^enum2\$<.+>$" --category Rust
type summary add -F lldb_lookup.MSVCEnumSummaryProvider -e -x -h "^enum2\$<.+>$" --category Rust
## MSVC Variants
type synthetic add -l lldb_lookup.synthetic_lookup -x "^enum2\$<.+>::.*$" --category Rust
# Tuple
type synthetic add -l lldb_lookup.TupleSyntheticProvider -x "^\(.*\)$" --category Rust
type summary add -F lldb_lookup.TupleSummaryProvider -x "^\(.*\)$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCTupleSyntheticProvider -x "^tuple\$<.+>$" --category Rust
type summary add -F lldb_lookup.TupleSummaryProvider -e -x -h "^tuple\$<.+>$" --category Rust
type category enable Rust

breakpoint set --file 'simple-tuple.rs' --line 162
DEBUG: breakpoint added, id = 1
Breakpoint 1: where = a`simple_tuple::main + 684 at simple-tuple.rs:162:5, address = 0x0000000100000ad0 
DEBUG: registering breakpoint callback, id = 1
Error while trying to register breakpoint callback, id = 1, message = error: could not get num args: can't find callable: breakpoint_callback

run
Process 35664 launched: '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/simple-tuple.lldb/a' (arm64) Process 35664 stopped * thread #1, name = 'main', queue = 'com.apple.main-thread', stop reason = breakpoint 1.1 frame #0: 0x0000000100000ad0 a`simple_tuple::main at simple-tuple.rs:162:5 159 PADDING_AT_END = (116, 117); 160 } 161 -> 162 zzz(); // #break ^ 163 } 164 165 fn zzz() {()} Target 0: (a) stopped. 
v/d noPadding8
((i8, u8)) noPadding8 = ('\x9c', 'd') 
v noPadding16
((i16, i16, u16)) noPadding16 = (0, 1, 2) 
v noPadding32
((i32, f32, u32)) noPadding32 = (3, 4.5, 5) 
v noPadding64
((i64, f64, u64)) noPadding64 = (6, 7.5, 8) 
v internalPadding1
((i16, i32)) internalPadding1 = (9, 10) 
v internalPadding2
((i16, i32, u32, u64)) internalPadding2 = (11, 12, 13, 14) 
v paddingAtEnd
((i32, i16)) paddingAtEnd = (15, 16) 
quit
------------------------------------------
--- stderr -------------------------------
warning: This version of LLDB has no plugin for the language "rust". Inspection of frame variables will be limited.
------------------------------------------

---- [debuginfo-lldb] tests/debuginfo/simple-tuple.rs stdout end ----
---- [debuginfo-lldb] tests/debuginfo/vec-slices.rs stdout ----
NOTE: compiletest thinks it is using LLDB version 1703

error: check directive(s) from `/Users/runner/work/rust/rust/tests/debuginfo/vec-slices.rs` not found in debugger output. errors:
    (vec-slices.rs:70) `[...] size=2 { [0] = (6, 7) { 0 = 6 1 = 7 } [1] = (8, 9) { 0 = 8 1 = 9 } }`
the following subset of check directive(s) was found successfully:
    (vec-slices.rs:58) `(&[i64]) empty = size=0 `
    (vec-slices.rs:61) `(&[i64]) singleton = size=1 { [0] = 1 } `
    (vec-slices.rs:64) `(&[i64]) multiple = size=4 { [0] = 2 [1] = 3 [2] = 4 [3] = 5 } `
    (vec-slices.rs:67) `(&[i64]) slice_of_slice = size=2 { [0] = 3 [1] = 4 } `
    (vec-slices.rs:73) `(&[vec_slices::AStruct]) padded_struct = size=2 { [0] = { x = 10 y = 11 z = 12 } [1] = { x = 13 y = 14 z = 15 } } `
status: exit status: 0
command: LLDB_BATCHMODE_SCRIPT_PATH="/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/vec-slices.lldb/vec-slices.debugger.script" LLDB_BATCHMODE_TARGET_PATH="/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/vec-slices.lldb/a" PYTHONPATH="/Users/runner/work/rust/rust/src/etc" PYTHONUNBUFFERED="1" "lldb" "--one-line" "script --language python -- import lldb_batchmode; lldb_batchmode.main()"
--- stdout -------------------------------
(lldb) script --language python -- import lldb_batchmode; lldb_batchmode.main()
LLDB batch-mode script
----------------------
Debugger commands script is '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/vec-slices.lldb/vec-slices.debugger.script'.
Target executable is '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/vec-slices.lldb/a'.
Current working directory is '/Users/runner/work/rust/rust'
Creating a target for '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/vec-slices.lldb/a'
settings set auto-confirm true

settings set target.inherit-tcc true

version
lldb-1703.0.236.21 Apple Swift version 6.2.3 (swiftlang-6.2.3.3.21 clang-1700.6.3.2) 
command script import /Users/runner/work/rust/rust/src/etc/lldb_lookup.py
# LLDB iterates through these in reverse order to discover summaries/synthetics that means the top
# of the list can be "overwritten" by items lower on the list. Be careful when reordering items.
# Forces test-compliant formatting to all other types
type synthetic add -l lldb_lookup.synthetic_lookup -x ".*" --category Rust
# Std String
type synthetic add -l lldb_lookup.StdStringSyntheticProvider -x "^(alloc::([a-z_]+::)+)String$" --category Rust
type summary add -F lldb_lookup.StdStringSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)String$" --category Rust
# Std str
type synthetic add -l lldb_lookup.StdSliceSyntheticProvider -x "^&(mut )?str$" --category Rust
type summary add -F lldb_lookup.StdStrSummaryProvider -e -x -h "^&(mut )?str$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCStrSyntheticProvider -x "^ref(_mut)?\$<str\$>$" --category Rust
type summary add -F lldb_lookup.StdStrSummaryProvider -e -h -x "^ref(_mut)?\$<str\$>$" --category Rust
# Array/Slice
type synthetic add -l lldb_lookup.StdSliceSyntheticProvider -x "^&(mut )?\\[.+\\]$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^&(mut )?\\[.+\\]$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCStdSliceSyntheticProvider -x "^ref(_mut)?\$<slice2\$<.+> >" --category Rust
type summary add -F lldb_lookup.StdSliceSummaryProvider -e -x -h "^ref(_mut)?\$<slice2\$<.+> >" --category Rust
# OsString
type summary add -F lldb_lookup.StdOsStringSummaryProvider -e -x -h "^(std::ffi::([a-z_]+::)+)OsString$" --category Rust
# Vec
type synthetic add -l lldb_lookup.StdVecSyntheticProvider -x "^(alloc::([a-z_]+::)+)Vec<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Vec<.+>$" --category Rust
# VecDeque
type synthetic add -l lldb_lookup.StdVecDequeSyntheticProvider -x "^(alloc::([a-z_]+::)+)VecDeque<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)VecDeque<.+>$" --category Rust
# HashMap
type synthetic add -l lldb_lookup.classify_hashmap -x "^(std::collections::([a-z_]+::)+)HashMap<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(std::collections::([a-z_]+::)+)HashMap<.+>$" --category Rust
# HashSet
type synthetic add -l lldb_lookup.classify_hashset -x "^(std::collections::([a-z_]+::)+)HashSet<.+>$" --category Rust
type summary add -F lldb_lookup.SizeSummaryProvider -e -x -h "^(std::collections::([a-z_]+::)+)HashSet<.+>$" --category Rust
# Rc
type synthetic add -l lldb_lookup.StdRcSyntheticProvider -x "^(alloc::([a-z_]+::)+)Rc<.+>$" --category Rust
type summary add -F lldb_lookup.StdRcSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Rc<.+>$" --category Rust
# Arc
type synthetic add -l lldb_lookup.arc_synthetic -x "^(alloc::([a-z_]+::)+)Arc<.+>$" --category Rust
type summary add -F lldb_lookup.StdRcSummaryProvider -e -x -h "^(alloc::([a-z_]+::)+)Arc<.+>$" --category Rust
# Cell
type synthetic add -l lldb_lookup.StdCellSyntheticProvider -x "^(core::([a-z_]+::)+)Cell<.+>$" --category Rust
# RefCell
type synthetic add -l lldb_lookup.StdRefSyntheticProvider -x "^(core::([a-z_]+::)+)Ref(Cell|Mut)?<.+>$" --category Rust
type summary add -F lldb_lookup.StdRefSummaryProvider -e -x -h "^(core::([a-z_]+::)+)Ref(Cell|Mut)?<.+>$" --category Rust
# NonZero
type summary add -F lldb_lookup.StdNonZeroNumberSummaryProvider -e -x -h "^(core::([a-z_]+::)+)NonZero(<.+>|I\d{0,3}|U\d{0,3})$" --category Rust
# PathBuf
type summary add -F lldb_lookup.StdPathBufSummaryProvider -e -x -h "^(std::([a-z_]+::)+)PathBuf$" --category Rust
# Path
type summary add -F lldb_lookup.StdPathSummaryProvider -e -x -h "^&(mut )?(std::([a-z_]+::)+)Path$" --category Rust
# Enum
# type summary add -F lldb_lookup.ClangEncodedEnumSummaryProvider -e -h "lldb_lookup.is_sum_type_enum" --recognizer-function --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCEnumSyntheticProvider -x "^enum2\$<.+>$" --category Rust
type summary add -F lldb_lookup.MSVCEnumSummaryProvider -e -x -h "^enum2\$<.+>$" --category Rust
## MSVC Variants
type synthetic add -l lldb_lookup.synthetic_lookup -x "^enum2\$<.+>::.*$" --category Rust
# Tuple
type synthetic add -l lldb_lookup.TupleSyntheticProvider -x "^\(.*\)$" --category Rust
type summary add -F lldb_lookup.TupleSummaryProvider -x "^\(.*\)$" --category Rust
## MSVC
type synthetic add -l lldb_lookup.MSVCTupleSyntheticProvider -x "^tuple\$<.+>$" --category Rust
type summary add -F lldb_lookup.TupleSummaryProvider -e -x -h "^tuple\$<.+>$" --category Rust
type category enable Rust

breakpoint set --file 'vec-slices.rs' --line 103
Breakpoint 1: where = a`vec_slices::main + 328 at vec-slices.rs:103:5, address = 0x00000001000009bc 
DEBUG: breakpoint added, id = 1
run
Process 37288 launched: '/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/debuginfo/vec-slices.lldb/a' (arm64) Process 37288 stopped * thread #1, name = 'main', queue = 'com.apple.main-thread', stop reason = breakpoint 1.1 frame #0: 0x00000001000009bc a`vec_slices::main at vec-slices.rs:103:5 100 101 let mut_slice: &mut [i64] = &mut [1, 2, 3, 4, 5]; 102 -> 103 zzz(); // #break ^ 104 } 105 106 fn zzz() { Target 0: (a) stopped. 
DEBUG: registering breakpoint callback, id = 1
Error while trying to register breakpoint callback, id = 1, message = error: could not get num args: can't find callable: breakpoint_callback

v empty
(&[i64]) empty = size=0 
v singleton
(&[i64]) singleton = size=1 { [0] = 1 } 
v multiple
(&[i64]) multiple = size=4 { [0] = 2 [1] = 3 [2] = 4 [3] = 5 } 
v slice_of_slice
(&[i64]) slice_of_slice = size=2 { [0] = 3 [1] = 4 } 
v padded_tuple
(&[(i32, i16)]) padded_tuple = size=2 { [0] = (6, 7) [1] = (8, 9) } 
v padded_struct
(&[vec_slices::AStruct]) padded_struct = size=2 { [0] = { x = 10 y = 11 z = 12 } [1] = { x = 13 y = 14 z = 15 } } 
quit
------------------------------------------
--- stderr -------------------------------
warning: This version of LLDB has no plugin for the language "rust". Inspection of frame variables will be limited.
------------------------------------------

---- [debuginfo-lldb] tests/debuginfo/vec-slices.rs stdout end ----

failures:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants