Open guenchi opened 4 years ago
What do you have in mind? Would you like to write code that emits machine code for a Lisp machine?
I was also interested in getting chez to run on bare metal. Chez won't build for bare metal targets so, it requires workarounds. Probably the best way of getting it to build would be to use newlib and make the appropriate patches from there. It's a considered effort.
I think Dr. Burger's hint to write a compiler for your target instead of directly using chez would be better to look into. The problem is complicated and the solution may require it's own lisp and vm. Although, that doesn't answer the question of how to run chez on bare metal targets.
Here are my thoughts: (and implementations in progress).
One option is to create a new machine type in Chez Scheme. You will need to have a C compiler and run-time libraries for the C side of Chez Scheme. You'll need to write the assembler for your architecture in Scheme (see arm32.ss, ppc32.ss, x86.ss, and x86_64.ss). It's a significant undertaking.
One option is to create a new machine type in Chez Scheme. You will need to have a C compiler and run-time libraries for the C side of Chez Scheme. You'll need to write the assembler for your architecture in Scheme (see arm32.ss, ppc32.ss, x86.ss, and x86_64.ss). It's a significant undertaking.
thanks :)
I think if the new system is compatible with Unix, maybe there is no need to change the Chez Scheme?
It would certainly minimize the porting effort if the system is Posix-like and uses one of the already supported CPUs.
I'm not trying to discourage anyone from using Chez Scheme, but if you truly want a scheme for bare-metal you should check out Loko (Bare Metal). It's designed to be entirely self hosting and has no dependencies on C libraries. It's also only amd64, so other targets will require significant work.
It would certainly minimize the porting effort if the system is Posix-like and uses one of the already supported CPUs.
Ya, that was the plan.
I'm not trying to discourage anyone from using Chez Scheme, but if you truly want a scheme for bare-metal you should check out Loko (Bare Metal). It's designed to be entirely self hosting and has no dependencies on C libraries. It's also only amd64, so other targets will require significant work.
It’s quite useful, thanks!
Let me suggest also Samuel and Marc's experience report. Their paper and video should be up soon.
Back in the day Flatt has MzScheme on “bare metal” using OSKit. Maybe OSKit is an option today too?
https://www.cs.utah.edu/flux/oskit/
fre. 6. dec. 2019 kl. 22.54 skrev guenchi notifications@github.com:
I'm trying to build a Lisp Machine base on Chez Scheme.
Please give some advice...
thanks very much!
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/cisco/ChezScheme/issues/480?email_source=notifications&email_token=AADQXRNN4JXCTZLNTU7UERDQXLC2TA5CNFSM4JXCC652YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4H6YMXBQ, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADQXROXFYRBCQ4RAI6DB23QXLC2TANCNFSM4JXCC65Q .
-- -- Jens Axel Søgaard
Let me suggest also Samuel and Marc's experience report. Their paper and video should be up soon.
that's very cool...
I'm trying to build a Lisp Machine base on Chez Scheme.
Please give some advice...
thanks very much!