[M3devel] friendly reminder/request for cooperative suspend

Jay jay.krell at cornell.edu
Fri Sep 14 23:24:49 CEST 2012


A C backend offers lots of optimizations via the C compiler..

 - Jay (briefly/pocket-sized-computer-aka-phone)

On Sep 14, 2012, at 8:10 AM, Antony Hosking <hosking at cs.purdue.edu> wrote:

> Yes, this is on the top of my list of things to do.
> Plus fix some atomics bugs.
> atomics plus cooperative suspend gives us a much better story on locks too.
> We could even have a proper memory model like C++11.
> 
> LLVM would also be great (better even than the C backend) because we’d get some decent optimization passes.
> 
> 
> On Sep 14, 2012, at 4:01 AM, Jay K <jay.krell at cornell.edu> wrote:
> 
>> friendly reminder/request: I'd like to see the system changed to use cooperative suspend.
>> 
>> 
>> Combined with a C backend, that would greatly expand portability and remove existing target-dependent code (i.e. already ported) from the system.
>> 
>> 
>> I'm not confident that GetThreadContext works on "wow64".
>> It'd fix that.
>> 
>> 
>> We can compute the top/bottom of the stack fairly portably -- address of locals.
>> We can capture current context/registers via setjmp.
>> Or maybe getcontext.
>> (We should find out about setjmp/longjmp munging -- what gets munged? Everything? Just non-gc-roots? Only after longjmp?)
>> Itanium is special -- there is a second stack growing up from the same base.
>> 
>> 
>> I'd like this way more than LLVM.
>> 
>> 
>> Maybe I can work on. Maybe.
>> 
>> 
>> I believe typical production Java VMs use cooperative suspend.
>> 
>> 
>>  - Jay
> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20120914/1476d958/attachment-0002.html>


More information about the M3devel mailing list