RE: Safely implementing Thread.Abort

Gopal V <gopalv82-/[email protected]>
Newsgroups gmane.comp.gnu.dotgnu.developer
Message-ID <[email protected]>
Hi,

> > > Outputting abort check instructions on every
> backward
> > > branch is OK with me, as long as you only do it
> in
> > > programs that use Thread.Abort.  This can be
> detected
> > > by the loader (any assembly with a MemberRef to
> > > Thread.Abort is a candidate).
> > 
....

Having every backward jump check for thread->aborted
would be a initial "make it work" solution. 

Not to mention that we could have an 
"--expect-no-thread-aborts"  which would
avoid this check ? . for example, when running 
pnetmark ? ;-)

> I pc register is specified explicitly.  Both windows
> and some unixes do
> provide a CONTEXT/signalcontext that will give you
> the values of these
> registers at the time of interrupt.  Is it not
> possible to simply restore
> the appropriate registers and then jump to the right
> place in the new
> abort-aware code?

That would be a GCC + (x86/arm/ppc) specific hack ,
which would still not speed it up on all platforms.

But my question is whether , that much work for
just speeding it up in 3 MAJOR platforms is 
worth the effort ;)

Gopal


	
		
__________________________________
Do you Yahoo!?
Yahoo! Domains – Claim yours for only $14.70/year
http://smallbusiness.promotions.yahoo.com/offer
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.