Skip to content

Use same context picker for breakpoints, symbols and path maps - #39

Merged
aragners merged 4 commits into
intel:mainfrom
aragners:context-picker-updates
Nov 26, 2026
Merged

aragners merged 4 commits into
intel:mainfrom
aragners:context-picker-updates

Conversation

@aragners

Copy link
Copy Markdown
Contributor
  • Now shows agent path map rules in Path Maps view, just as for Symbol files.
  • Share the context picker for symbol files and path maps with breakpoints.
  • Update context picker to allow selection by selecting contexts or using context queries.

@aragners
aragners requested a review from clillies November 26, 2026 08:04
@aragners
aragners requested a review from a team as a code owner November 26, 2026 08:04
The agent can have path map rules that this session did not add, for
example from add-pathmap-entry in Simics or from another client. The
session already uses them to map paths, but the view did not show
them. This made it hard to see why a path was mapped.

Show them read-only under "Added Elsewhere", like the Symbol Files
view does. Rules for another host are listed too, but marked as not
used, since this client ignores them.

Signed-off-by: Andreas Ragnerstam <andreas.ragnerstam@intel.com>
Symbol files had their own picker that took one context, while
function breakpoints had a checklist for several. Both now use the
same checklist, so they look and work the same. For symbol files it
can switch to a context query and accept IDs or names the agent does
not list.

A symbol file can apply to several contexts with a "contexts" list.
MemoryMap.set takes one context, so the region is set in the map of
each context. The old "context" string still works but is deprecated.

"contexts" and "contextQuery" can no longer be set together. One
choice is easier to understand and to edit. Old configurations with
both are ignored with an error.

The launch configurations form gets a Contexts column for symbol
files: all contexts, a list of contexts, or a query. It can pick the
contexts from a running session to the same agent.

Signed-off-by: Andreas Ragnerstam <andreas.ragnerstam@intel.com>
Breakpoints could only be scoped to listed contexts, and symbol files
hid their context query behind a small title bar button. A menu first
makes the choice clear: all contexts, the selected call-stack context,
a checklist of contexts, or a context query. It works like the scope
picker of the Path Map view and the dropdown in the launch form.

Function breakpoints keep their scope in their name, so a query is
written after " @? ", which no symbol contains. It is sent as the TCF
ContextQuery breakpoint property. Agents that say they do not support
it get an error, so the breakpoint is never set in all contexts.

Signed-off-by: Andreas Ragnerstam <andreas.ragnerstam@intel.com>
The Path Maps view and Locate Source File had their own scope picker
that took a single context ID. Using the same picker as breakpoints
and symbol files makes all of them look and work the same.

To pick several contexts, path map rules get a "contexts" list. The
TCF context query syntax cannot select one of several IDs, so a rule
with several contexts is sent to the agent as one rule per context,
like symbol files get one memory map region per context. The old
"context" still works but is deprecated.

The launch configurations form gets the same Contexts column for
path map rules as for symbol files.

Signed-off-by: Andreas Ragnerstam <andreas.ragnerstam@intel.com>
@aragners
aragners force-pushed the context-picker-updates branch from 2ed31a0 to 2d7f016 Compare November 26, 2026 08:06
@aragners

Copy link
Copy Markdown
Contributor Author

As mentioned in #38 README.md should be restructured. That has not been done here, but will be done afterwards. It's not made for humans, any readme that is useful for an agent should be moved to it's own file.

@clillies

Copy link
Copy Markdown
Contributor

The list of contexts that a symbol file belongs to (printed per symbol file, with the complete list in mouse-over),
could that be context names instead of context id?
I guess it will be more text, and having both is not an option.
Or is there some other means of showing both context id and name.
Otherwise, that's fine.

image

@clillies

clillies commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

For the breakpoints, it is slightly confusing that the pen icon on a single breakpoint
can edit condition, while the pen icon in the main breakpoints bar means editing
contexts. If we had control over the icon:

  1. The breakpoints main bar.
  2. The Symbol Files - per symbol-file entry
image

Then we could choose some other icon, but this can be fixed later.

@clillies

Copy link
Copy Markdown
Contributor

Function breakpoints where the function cannot be resolved, when mouseover on that breakpoint
shows the typical TCF message At col 1: Undefined f. Invalid expression.
This can be fixed later.

@clillies clillies left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I had mainly questions, and nothing that cannot be fixed after this PR.

@aragners

Copy link
Copy Markdown
Contributor Author

For the breakpoints, it is slightly confusing that the pen icon on a single breakpoint can edit condition, while the pen icon in the main breakpoints bar means editing contexts. If we had control over the icon:

  1. The breakpoints main bar.
  2. The Symbol Files - per symbol-file entry

Then we could choose some other icon, but this can be fixed later.

I agree, but nothing that is new to this patch, so better in a separate patch.

@aragners

Copy link
Copy Markdown
Contributor Author

Function breakpoints where the function cannot be resolved, when mouseover on that breakpoint shows the typical TCF message At col 1: Undefined f. Invalid expression. This can be fixed later.

Yes, this message is not useful, but nothing that should be new to this PR either.

@aragners

Copy link
Copy Markdown
Contributor Author

None of the comments should be anything this PR has changed. But they are valid comments and should be looked at later.

@aragners
aragners merged commit 4e41ec7 into intel:main Nov 26, 2026
5 checks passed
@aragners
aragners deleted the context-picker-updates branch November 26, 2026 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants