This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Ada] redesign a-rttiev.adb


Tested on i686-linux, committed on trunk.

This is part of a new design for the implementation of the
package.  The new design provides for automatic termination of
applications using this package and also corrects a design flaw
preventing an event handler from re-activating the handled event.
In the prior implementation, termination of the application would
await the termination of the internal "timer" task located within
the package body.  Because that internal task would never
terminate, the application could never terminate.  The appropriate
run-time library calls are now made within the implementation so
that the internal task will automatically terminate if the entire
application is ready to terminate.
The design flaw prevented a protected procedure event handler from
calling Set_Handler on the event being handled so that the
event would again be handled in the future (unless canceled in
the future).  This "reactivation" is expected to be a common
design idiom.

2006-10-31  Pat Rogers  <rogers@adacore.com>

	* a-rttiev.ads, a-rttiev.adb: 
	This is a significant redesign primarily for the sake of automatic
	timer task termination but also to fix a design flaw.
	Therefore we are now using an RTS lock, instead of a protected
	object, to provide mutual exclusion to the queue of pending events
	and the type Timing_Event is no longer a protected type.

Attachment: difs
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]