Bug 7573 - cache frame_info in thread_info
Summary: cache frame_info in thread_info
Status: REOPENED
Alias: None
Product: gdb
Classification: Unclassified
Component: threads (show other bugs)
Version: unknown
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-04-06 06:58 UTC by ac131313
Modified: 2013-11-18 17:47 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ac131313 2002-04-06 14:58:00 UTC
[Converted from Gnats 468]

At present there is a single global frame cache.  If the selected thread is changed, the cache is discarded.

Instead, have per-thread selected_frame, current_frame (better name?) and just switch between them when the thread changes.

Long term, this should be handled naturally by always using a ``thread'' object.  Short term, it can be handled by managing the selected thread's frame using the access methods:
    get_current_frame()
 +  get_selected_frame()
These functions can track the inferior_tpid vs the one currently selected by the frame.c code.

flush_cached_frames() would iterate over all the threads invalidating all current frames.

Release:
2002-04-05
Comment 1 Tom Tromey 2010-06-10 16:51:10 UTC

*** This bug has been marked as a duplicate of 8627 ***
Comment 2 Tom Tromey 2013-11-18 17:47:58 UTC
Un-duping.  Not sure why I did that.

I think it might be preferable to have a thread-aware
frame cache (and frame stash) attached to the address space,
than to have it be explicitly on the thread_info.