Bug 410651 - support gdb's "frame filter" feature
Summary: support gdb's "frame filter" feature
Status: NEW
Alias: None
Product: CDT
Classification: Tools
Component: cdt-debug-dsf-gdb (show other bugs)
Version: 8.2   Edit
Hardware: PC Linux
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact: Jonah Graham CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-12 15:14 EDT by Tom Tromey CLA
Modified: 2020-09-04 15:24 EDT (History)
6 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Tromey CLA 2013-06-12 15:14:03 EDT
I wasn't sure which component to file this against.

gdb recently added a "frame filters" feature, which lets Python code modify stack traces in some ways.

This feature is exposed to MI, but it requires a special enabling request, and AFAIK Eclipse CDT doesn't yet support it.  I think it should.

Docs here: http://sourceware.org/gdb/current/onlinedocs/gdb/GDB_002fMI-Stack-Manipulation.html#GDB_002fMI-Stack-Manipulation
See "-enable-frame-filters"
Comment 1 Simon Marchi CLA 2013-06-27 14:13:53 EDT
When you say Eclipse CDT should support frame filters, do you mean simply sending -enable-frame-filters to GDB? What would you be able to do that you can't do now? To be useful, the user would need some new UI to define frame filters and display the modified stack traces. It is interesting, but it seems like a big task.

If -enable-frame-filters is sent to GDB, we need to make sure to use --no-frame-filters with the -stack-list-* family of commands whenever we want the normal output (e.g. for the default views), to avoid having user-defined frame filters breaking the UI.

Does that make sense?
Comment 2 Tom Tromey CLA 2013-06-27 14:41:57 EDT
(In reply to comment #1)
> When you say Eclipse CDT should support frame filters, do you mean simply
> sending -enable-frame-filters to GDB? 

Yes.

> What would you be able to do that you
> can't do now?

Users could see a filtered view of the frames.  For best results (IMO), Eclipse could hide elided frames by default and let users click to see them.

The filters need not be editable from Eclipse.  We plan to ship some pre-canned filters in the OS; these will be auto-activated the same way that Python pretty-printers are.

> If -enable-frame-filters is sent to GDB, we need to make sure to use
> --no-frame-filters with the -stack-list-* family of commands whenever we
> want the normal output (e.g. for the default views), to avoid having
> user-defined frame filters breaking the UI.

At least in the case where the user wants the raw view.  I think new features should generally be enabled by default.