dotgnu-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Fwd: [DotGNU]Hacking - TODOs in the engine.]


From: Jonathan P Springer
Subject: Re: [Fwd: [DotGNU]Hacking - TODOs in the engine.]
Date: Fri, 3 May 2002 20:55:34 -0400
User-agent: Mutt/1.3.28i

On Sat, May 04, 2002 at 10:18:00AM +1000, Rhys Weatherley wrote:
> Subject: Re: [DotGNU]Hacking - TODOs in the engine.
> Jonathan P Springer wrote:
> 
> > I added dynamic frame array reallocation and command line argument -F to
> > allow one to set the frame size.  This because I'm trying to get a
> > recursive program to overrun the stack rather than the frame.  Success
> > there, but not where I wanted it.
> 
> There are two stacks that come into play: the frame stack
> and the operation stack.  The frame stack stores information
> for returning from methods, and can be dynamically reallocated.
> But the operation stack (where pushes and pops occur) cannot.

OK.  I'll actually implement the frame stack reallocations (which are
currently TODOs).  I'll just let them go until the reallocation fails.
(Just a simple allocate twice what you've got and copy approach).

> This is because of managed pointers: it is possible to take the
> address of a local variable (using IL's ldloca) and push it onto
> the stack as a pointer.  If the stack is reallocated, the local
> may be moved in memory, which will cause the pointer to now
> point at garbage.

Gotcha.  This all started because I'm trying to write test programs that
will fire every StackOverflow exception (implemented and not) in the VM.
 
> Since the frame stack can reallocate at will, there isn't much
> need for an option to set the size.  It would be nice to have an
> option to specify the operation stack size though.

No problem.  I'm pretty sure I can squeeze that in with 5 minutes effort
and 5 hours testing.
 
> > Anyone else in the engine right now?  Should I steer clear?
> 
> I'm always in the engine, but which part of it varies from day
> to day.  But that isn't necessarily a problem.  Patches are
> normally localized, and are unlikely to be localized to exactly
> where I am right now.

Well, I certainly know you'll know when I break it :-).

> 
> Cheers,
> 
> Rhys.
> 

Cheers,
-jon

-- 
-Jonathan P Springer <address@hidden>
------------------------------------------------------------------------------
"A standard is an arbitrary solution to a recurring problem." - Joe Hazen


reply via email to

[Prev in Thread] Current Thread [Next in Thread]