src/rda/unix ChangeLog lwp-pool.c lwp-pool.h t ...
jimb@sourceware.org
jimb@sourceware.org
Mon Nov 29 19:36:00 GMT 2004
CVSROOT: /cvs/src
Module name: src
Branch: jimb-rda-nptl-branch
Changes by: jimb@sourceware.org 2004-11-29 19:36:23
Modified files:
rda/unix : ChangeLog lwp-pool.c lwp-pool.h thread-db.c
Log message:
Move libthread_db event-based thread death logic from lwp-pool.c
to thread-db.c, so the former can stay innocent of libthread_db's
details, and limit itself to kernel behavior.
* lwp-pool.h (lwp_pool_continue_and_drop): New declaration.
(lwp_pool_thread_db_death_event,
lwp_pool_thread_db_death_notified): Declarations deleted.
* lwp-pool.c (enum death_state): Move to thread-db.c.
(struct lwp): Delete 'death_state' member.
(hash_find): Don't initialize it.
(interesting_queue): Don't provide an initializer for it.
(check_stop_pending): Don't abort if wait_and_handle didn't put
the thread in a stopped state; that could be caused by kernel
behavior (say, threads exiting silently), not necessarily a logic
flaw in lwp-pool.c.
(death_state_str, debug_report_death_state_change): Move to
thread-db.c.
(lwp_pool_thread_db_death_event,
lwp_pool_thread_db_death_notified): Move to thread-db.c, and
rename (see below).
(check_for_exiting_nptl_lwp): Delete.
(lwp_pool_continue_all, lwp_pool_continue_lwp): Don't call
check_for_exiting_nptl_lwp.
(lwp_pool_continue_and_drop_lwp): New function.
* thread-db.c (enum death_state): Moved here from lwp-pool.c.
(struct gdbserv_thread): New member death_state.
(add_thread_to_list): Initialize it.
(death_state_str, debug_report_death_state_change): Moved here
from lwp-pool.c.
(death_state_got_event, death_state_notified): Renamed from
lwp_pool_thread_db_death_event and lwp_pool_thread_db_death_notified,
and changed to update the death state of a 'struct gdbserv_thread'
instead of a 'struct lwp'.
(handle_thread_db_event): Call death_state_got_event instead of
lwp_pool_thread_db_death_event, and death_state_notified instead
of lwp_pool_thread_db_death_notified.
(continue_thread): If the thread's death state indicates that it's
going to disappear without further ado when continued, continue it
with lwp_pool_continue_and_drop_lwp, not lwp_pool_continue_lwp.
Patches:
http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/rda/unix/ChangeLog.diff?cvsroot=src&only_with_tag=jimb-rda-nptl-branch&r1=1.36.2.17&r2=1.36.2.18
http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/rda/unix/lwp-pool.c.diff?cvsroot=src&only_with_tag=jimb-rda-nptl-branch&r1=1.1.2.2&r2=1.1.2.3
http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/rda/unix/lwp-pool.h.diff?cvsroot=src&only_with_tag=jimb-rda-nptl-branch&r1=1.1.2.2&r2=1.1.2.3
http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/rda/unix/thread-db.c.diff?cvsroot=src&only_with_tag=jimb-rda-nptl-branch&r1=1.9.2.7&r2=1.9.2.8
More information about the Src-cvs
mailing list