Live data from Hacker News

Cyclone Scheme – Cheney on the MTA with Native Threads

justinethier.github.io

11–19 of 19 posts

Re: Cyclone Scheme – Cheney on the MTA with Native Threads

#11
post #10

Can anyone point me in the direction some call with continuation and stack and heap explainer? It would be great if it was brief and visual but I'm willing to read up. I just want to make sure that an explanation of call/cc is forthcoming.

What exactly about them do you want explained? I'll do my best to do it, or give a link, but I'm not sure if you want a general explanation of all three, or an explanation of the connection beteen them.

Re: Cyclone Scheme – Cheney on the MTA with Native Threads

#12

This is a pretty cool project, but it doesn't have the library support of other schemes. Given CHICKEN's already Cheney based, I wonder if Felix could somehow integrate this work? Green-Threaded pre-emptive cooroutines are all well and good, but sometimes you want OS threads...

Cyclone author here. R7RS libraries and SRFI's will help to some extent, for example hashtable support was more or less plug and play. As Cyclone matures it could potentially support R7RS-large which is going to include quite a bit. But we'll have to see how much of that can handle "real" things like database, graphics, etc.

It would require major changes to the CHICKEN runtime to support native threads, but Cyclone does map out a potential solution.

Re: Cyclone Scheme – Cheney on the MTA with Native Threads

#13
post #10

Can anyone point me in the direction some call with continuation and stack and heap explainer? It would be great if it was brief and visual but I'm willing to read up. I just want to make sure that an explanation of call/cc is forthcoming.

Here is a basic introduction to the stack and heap, with examples in C: http://gribblelab.org/CBootcamp/7_Memory_Stack_vs_Heap.html

This might help with continuations: https://en.wikipedia.org/wiki/Continuation

Here is a really simple example of simulating a C return using call/cc:

  (display
    (call/cc
      (lambda (return)
        (display "hello ")
        (return "world")
        (display "never reached"))))

Re: Cyclone Scheme – Cheney on the MTA with Native Threads

#14

This is a pretty cool project, but it doesn't have the library support of other schemes. Given CHICKEN's already Cheney based, I wonder if Felix could somehow integrate this work? Green-Threaded pre-emptive cooroutines are all well and good, but sometimes you want OS threads...

Cyclone author here. R7RS libraries and SRFI's will help to some extent, for example hashtable support was more or less plug and play. As Cyclone matures it could potentially support R7RS-large which is going to include quite a bit. But we'll have to see how much of that can handle "real" things like database, graphics, etc. It would require major changes to the CHICKEN runtime to support native threads, but Cyclone…

There is 1000$ bounty for enhacing CHICKEN with native threads. Maybe your work will trigger now someone :) .

Re: Cyclone Scheme – Cheney on the MTA with Native Threads

#15

This is a pretty cool project, but it doesn't have the library support of other schemes. Given CHICKEN's already Cheney based, I wonder if Felix could somehow integrate this work? Green-Threaded pre-emptive cooroutines are all well and good, but sometimes you want OS threads...

Cyclone author here. R7RS libraries and SRFI's will help to some extent, for example hashtable support was more or less plug and play. As Cyclone matures it could potentially support R7RS-large which is going to include quite a bit. But we'll have to see how much of that can handle "real" things like database, graphics, etc. It would require major changes to the CHICKEN runtime to support native threads, but Cyclone…

>R7RS libraries and SRFI's will help to some extent, for example hashtable support was more or less plug and play. As Cyclone matures it could potentially support R7RS-large which is going to include quite a bit. But we'll have to see how much of that can handle "real" things like database, graphics, etc.

Good news!

>It would require major changes to the CHICKEN runtime to support native threads, but Cyclone does map out a potential solution

Oh well. Well, at least there is hope.

Re: Cyclone Scheme – Cheney on the MTA with Native Threads

#16
post #10

Can anyone point me in the direction some call with continuation and stack and heap explainer? It would be great if it was brief and visual but I'm willing to read up. I just want to make sure that an explanation of call/cc is forthcoming.

Here is a basic introduction to the stack and heap, with examples in C: http://gribblelab.org/CBootcamp/7_Memory_Stack_vs_Heap.html This might help with continuations: https://en.wikipedia.org/wiki/Continuation Here is a really simple example of simulating a C return using call/cc: (display (call/cc (lambda (return) (display "hello ") (return "world") (display "never reached"))))

For continuations, I would actually recomend "LAMBDA: The Ultimate Imperative" (http://repository.readscheme.org/ftp/papers/ai-lab-pubs/AIM-...). It's not exactly light reading, but it gives the best explanation of continuations that I've seen.

If you just want the simple explanation: A continuation is a copy of the return stack at the instant it was captured. When a continuation is invoked, that copy replaces the stack.

Re: Cyclone Scheme – Cheney on the MTA with Native Threads

#17

Earlier quoted context omitted.

Here is a basic introduction to the stack and heap, with examples in C: http://gribblelab.org/CBootcamp/7_Memory_Stack_vs_Heap.html This might help with continuations: https://en.wikipedia.org/wiki/Continuation Here is a really simple example of simulating a C return using call/cc: (display (call/cc (lambda (return) (display "hello ") (return "world") (display "never reached"))))

For continuations, I would actually recomend "LAMBDA: The Ultimate Imperative" ( http://repository.readscheme.org/ftp/papers/ai-lab-pubs/AIM-... ). It's not exactly light reading, but it gives the best explanation of continuations that I've seen. If you just want the simple explanation: A continuation is a copy of the return stack at the instant it was captured. When a continuation is invoked, that copy replaces the…

This is perfect! Thank you!

Re: Cyclone Scheme – Cheney on the MTA with Native Threads

#18
post #10

Can anyone point me in the direction some call with continuation and stack and heap explainer? It would be great if it was brief and visual but I'm willing to read up. I just want to make sure that an explanation of call/cc is forthcoming.

Here is a basic introduction to the stack and heap, with examples in C: http://gribblelab.org/CBootcamp/7_Memory_Stack_vs_Heap.html This might help with continuations: https://en.wikipedia.org/wiki/Continuation Here is a really simple example of simulating a C return using call/cc: (display (call/cc (lambda (return) (display "hello ") (return "world") (display "never reached"))))

Thanks!
Post reply on HN