Another week quickly passed, I was working hard on the macro system for skime last week. It is a little tough, but now I finally managed to finish it. I wrote a summary[Chinese] on the implementation of the hygienic macro system of skime.
skime should be a fairly feature-complete pure-Python Scheme fallback for Schemepy after that. I’ve moved the source to the Schemepy repository. And now the backend wrapper (yes, pure-Python fallback still need backend wrapper) is also finished and most of the existing test cases have passed on that.
I committed almost nothing to the Thousand Parsec repository this week. That’s because I’m mainly working on skime — a pure-Python VM for Scheme. After one-week hard working, the basic shape of the VM is already there.
Although there are still many work (e.g. the macro system) to do before it can be a really useful VM, I decide to write a simple layer to fit the Schemepy API and run the benchmarks to see whether the time spent on a new fallback is worth.
The result looks promising. Firstly, there’s the time spent to load the VM (mzscheme is not included in the benchmarks shown below. The mzscheme package in Debian sid upgraded to version 4.x, but even the mzscheme executable failed to start in my local box. I still haven’t got time to inspect the reason.):
I committed almost nothing to the Thousand Parsec repository this week. That’s because I’m mainly working on skime — a pure-Python VM for Scheme. After one-week hard working, the basic shape of the VM is already there.
Although there are still many work (e.g. the macro system) to do before it can be a really useful VM, I decide to write a simple layer to fit the Schemepy API and run the benchmarks to see whether the time spent on a new fallback is worth.
The result looks promising. Firstly, there’s the time spent to load the VM (mzscheme is not included in the benchmarks shown below. The mzscheme package in Debian sid upgraded to version 4.x, but even the mzscheme executable failed to start in my local box. I still haven’t got time to inspect the reason.):
I committed almost nothing to the Thousand Parsec repository this week. That’s because I’m mainly working on skime — a pure-Python VM for Scheme. After one-week hard working, the basic shape of the VM is already there.
Although there are still many work (e.g. the macro system) to do before it can be a really useful VM, I decide to write a simple layer to fit the Schemepy API and run the benchmarks to see whether the time spent on a new fallback is worth.
The result looks promising. Firstly, there’s the time spent to load the VM (mzscheme is not included in the benchmarks shown below. The mzscheme package in Debian sid upgraded to version 4.x, but even the mzscheme executable failed to start in my local box. I still haven’t got time to inspect the reason.):
I was away for several weeks during my final exams. But now I’m in my summer holiday. It seems not having classes is making the everyday life a little boring — you do the same thing every day, you even forget the day of the week. Yes, I don’t know what’s the N in N-th week in Schemepy now, so I changed the title. ![]()
We’re during the Google mid-term evaluation these days. I designed several logo candidates for Schemepy the other day and wrote a brief summary for the work done so far. All students of Thousand Parsec are required to write this summary. I guess all those summaries be available publicly later. So I decide to put aside the task of porting tp-client/tp-server work until I see other students summary, from which I may understand more of the whole thing.
The mid-term evaluation of GSoC 2008 is approaching. We students are requested to write a summary of our work. In the Thousand Parsec project, Mithro said:
This report should be written as if the person who is reading it has no understanding of what Thousand Parsec is or how to play it.
I think I don’t have to introduce what Thousand Parsec is (I myself is not quite sure, in fact) here. However, it is still necessary to describe Schemepy. So I decided to design a logo in order to promote Schemepy. ![]()
There are two guidelines for the logo:
The mid-term evaluation of GSoC 2008 is approaching. We students are requested to write a summary of our work. In the Thousand Parsec project, Mithro said:
This report should be written as if the person who is reading it has no understanding of what Thousand Parsec is or how to play it.
I think I don’t have to introduce what Thousand Parsec is (I myself is not quite sure, in fact) here. However, it is still necessary to describe Schemepy. So I decided to design a logo in order to promote Schemepy. ![]()
There are two guidelines for the logo:
The mid-term evaluation of GSoC 2008 is approaching. We students are requested to write a summary of our work. In the Thousand Parsec project, Mithro said:
This report should be written as if the person who is reading it has no understanding of what Thousand Parsec is or how to play it.
I think I don’t have to introduce what Thousand Parsec is (I myself is not quite sure, in fact) here. However, it is still necessary to describe Schemepy. So I decided to design a logo in order to promote Schemepy. ![]()
There are two guidelines for the logo:
Mithro is just collecting the first-month-status of various Thousand Parsec related GSoC projects. However, since I started early, this is already the end of my 8th week working on Schemepy for me. But as I mentioned before, I spent most of time preparing my final exams. I’ll take my first exam the day after tomorrow. So not too much work has been done this week.
Firstly, I added a (very) simple homepage for Schemepy. It is available here. We’ll setup a shorter URL (like schemepy.thouspandparsec.net) later.
Mithro is just collecting the first-month-status of various Thousand Parsec related GSoC projects. However, since I started early, this is already the end of my 8th week working on Schemepy for me. But as I mentioned before, I spent most of time preparing my final exams. I’ll take my first exam the day after tomorrow. So not too much work has been done this week.
Firstly, I added a (very) simple homepage for Schemepy. It is available here. We’ll setup a shorter URL (like schemepy.thouspandparsec.net) later.
There’s not too much done in this week. Basically, I looked a bit at the tpserver-py and tried to run it in my local box. If I can successfully run it and test the features, then I can go ahead to port it from pyscheme to Schemepy. In the best case, there should be some regression test cases so that I can simply run the test cases before and after porting to guarantee I don’t broke something. Unfortunately, it seems that I need to test the functionality manually.
On the other hand, my final exams are approaching. Generally, I’ll need to spend time to review the text books to prepare for the exams. And I’ll also spend time to finish various course projects. That’s why less time is spent on Schemepy this week (and in the following two to three weeks).
There’s not too much done in this week. Basically, I looked a bit at the tpserver-py and tried to run it in my local box. If I can successfully run it and test the features, then I can go ahead to port it from pyscheme to Schemepy. In the best case, there should be some regression test cases so that I can simply run the test cases before and after porting to guarantee I don’t broke something. Unfortunately, it seems that I need to test the functionality manually.
On the other hand, my final exams are approaching. Generally, I’ll need to spend time to review the text books to prepare for the exams. And I’ll also spend time to finish various course projects. That’s why less time is spent on Schemepy this week (and in the following two to three weeks).
As I said in the last status report, although I finished the mzscheme backend, I found the currently commonly used version is in fact of another memory model. My original code was written against the CGC memory model, so I need to re-implement part of the backend to adopt the new 3m model.
At first, I have no idea of how to implement it totally. The mzscheme GC is moving the memory, I need to register all local pointers to it — but it is unrealistic for a Python program. So I asked for help on this. I got answer from both the schemepy mailing list and the mzscheme mailing list — use immobile.
As I said in the last status report, although I finished the mzscheme backend, I found the currently commonly used version is in fact of another memory model. My original code was written against the CGC memory model, so I need to re-implement part of the backend to adopt the new 3m model.
At first, I have no idea of how to implement it totally. The mzscheme GC is moving the memory, I need to register all local pointers to it — but it is unrealistic for a Python program. So I asked for help on this. I got answer from both the schemepy mailing list and the mzscheme mailing list — use immobile.
I finally finished the mzscheme backend. As I said before, I should have finished it before writing the last week’s status report. However, I’m still pleased to see the result though a little late than scheduled. So I’ll write a follow up of the last status report.
With the experience of implementing the guile backend. It should be not too hard to write yet another backend. It is true for most parts. However, there are many differences between different Scheme implementations. Here are some examples:
I finally finished the mzscheme backend. As I said before, I should have finished it before writing the last week’s status report. However, I’m still pleased to see the result though a little late than scheduled. So I’ll write a follow up of the last status report.
With the experience of implementing the guile backend. It should be not too hard to write yet another backend. It is true for most parts. However, there are many differences between different Scheme implementations. Here are some examples:
I finally finished the mzscheme backend. As I said before, I should have finished it before writing the last week’s status report. However, I’m still pleased to see the result though a little late than scheduled. So I’ll write a follow up of the last status report.
With the experience of implementing the guile backend. It should be not too hard to write yet another backend. It is true for most parts. However, there are many differences between different Scheme implementations. Here are some examples:
I finally finished the mzscheme backend. As I said before, I should have finished it before writing the last week’s status report. However, I’m still pleased to see the result though a little late than scheduled. So I’ll write a follow up of the last status report.
With the experience of implementing the guile backend. It should be not too hard to write yet another backend. It is true for most parts. However, there are many differences between different Scheme implementations. Here are some examples:
I was all doing the mzscheme backend the last week. I had complained much about the interface before. However, after that, (at least I think) I have figured out how to do various things to finish the backend by reading the document, reading the source code and guessing.
For example, the namespace mechanism is mentioned very vaguely in the Inside PLT MzScheme. Firstly, I guess I can use module to do the namespace. But it doesn’t work. Then I discovered there’s a make_namespace procedure, though not documented, I guess is what I was finding. But I still get some strange errors (related to some #%-prefixed modules). I’m not sure how the namespace should be used. And I’m also having some segment faults.
There’s not too much done in this week for Schemepy. At first I was trying to port libtpclient-py from pyscheme to Schemepy. However, the code base of libtpclient-py is not too big, and I only found little code that used pyscheme. I thought I should learn the basic behavior of the lib and the client before I start hacking it. Unfortunately, I have no idea of what 4x game is. I tried several times but still not figured out how to play a TP game.
Then I decide to work on another backend. Maybe guile is the most easy one because it is designed to be embedded into another program. Other Scheme implementations are not so easy when it comes to embedding. By comparing mzscheme with chicken, I decided to work on mzscheme first. Both are great Scheme implementations, but I think the C interface of mzscheme is not so friendly.