V
2  
Tags
There are no tags for this page.
Attachments
Perl 6
SMOP Stackless

At first, a question must be made, which is "why do I need to get rid of the C stack"? The answer resides in the Perl 6 feature set, more than anything else. My inspiration on this is the stackless python project (which was not adopted by the mainstream python) because it makes the support for continuations and co-routines much easier. It would be possible to implement it using the C stack, but this would require mixing the manipulation of the C stack with the manipulation of the Perl 6 stack, which may be very complex. Let's think about the gather/take operators. They may be called from a very deep level of the stack. Mixing that with interpreted code and the C stack would be very much complex.

The solution would be to simply remove the C stack from the story. This would make a single frame stack to exist, and considering it's separated from the C stack, it's more easily manipulated. But how to implement a simple stackless C code that supports that? The solution is actually quite simple and is completely inspired in the stackless project. The key thing is, instead of calling a function, you just prepare it by sending it to the interpreter. The "machine" runs by iterating the messages and calling them. The difference here is that: if this call would call another message, instead of calling it directly, it push the call to the stack and returns immediatly. The "machine" would again pop from the stack and now it would call the deeper method, having the Perl stack complete but without feeding the C stack.


 

Upload Files

Click "Browse" to find the file you want to upload. When you click "Upload file" your file will be uploaded and added to the list of attachments for this page.

Maximum file size: 50MB

 
 
 
File Name Author Date Uploaded Size

Save Page As

Enter a meaningful and distinctive title for your page.

Page Title:

Tip: You'll be able to find this page later by using the title you choose.

Page Already Exists

There is already a page named XXX. Would you like to:

Save with a different name:

Save the page with the name "XXX"

Append your text to the bottom of the existing page named: "XXX"

Upload Files

Click "Browse" to find the file you want to upload. When you click "Add file" this file will be added to the list of attachments for this page, and uploaded when you save the page.

 
 
 
Add Tags

Enter a tag and click "Add tag". The tag will be saved when you save the page.

Tag: 

Suggestions: