Amazing thread. Certainly writing an OS in Julia wouldn't be easy (for basically the same reasons that it's impossible to write an OS with standard CPython -- the Julia interpreter needs an underlying operating system to run). But people have written an OS with Python! Cleese: https://github.com/jtauber/cleese/
So maybe it would be possible to do something similar in Julia? I have basically no idea what would be involved. The idea with Cleese is that they modified the Python bytecode interpreter to work on bare metal (basically, they wrote a microkernel). On Wednesday, March 19, 2014 6:12:36 PM UTC-4, Dahua Lin wrote: > > One aspect that makes Rust more suitable for low-level systems is the > flexibility in memory management. For example, they have several different > kinds of pointers that have different ways to manage their life cycle. > > On Wednesday, March 19, 2014 2:10:31 PM UTC-5, Stefan Karpinski wrote: >> >> People have certainly written OSes in some unusual languages (Lisp, >> Haskell), but I have to say that using such a dynamic language with >> automatic garbage collection strikes me as not the best endeavor. Since >> Julia Evans (the blog post author) has dabbled in both Julia and Rust, you >> could maybe ask her why she chose Rust for her OS project, rather than >> Julia. >> >> >> On Wed, Mar 19, 2014 at 1:33 PM, Collin Glass <[email protected]>wrote: >> >>> Thanks John and Johan. I get it. >>> >>> >>> On Wednesday, March 19, 2014 10:55:31 AM UTC-4, Johan Sigfrids wrote: >>>> >>>> I'm no expert on writing OSes but without an OS you have no memory >>>> management, so no heap. I don't think Julia's memory model would work. >>>> There is a reason OS kernels are written in C. You need a language which >>>> lets you read and write directly to memory addresses. If you want >>>> something >>>> better than C to write a kernel in I think Rust is low level enough to >>>> give >>>> you what you want. >>>> >>>> On Wednesday, March 19, 2014 4:37:22 PM UTC+2, Collin Glass wrote: >>>>> >>>>> Hi All, >>>>> >>>>> I am new to Julia, although already addicted :). My imagination does >>>>> outweigh my understanding for now but I wanted to know why it wouldn't be >>>>> possible to right an Operating System, or at least a very small one in >>>>> Julia. Noted by Tim holy in this post: https://groups.google. >>>>> com/forum/#!searchin/julia-users/gui/julia-users/PakwjAB- >>>>> 14s/tEpBkGf-KgwJ >>>>> >>>>> I was looking around a little bit before finding that post and I found >>>>> this dated package: https://github.com/toivoh/julia-kernels >>>>> >>>>> I contacted Toivo and he said the package was likely dated now and >>>>> pointed me to devectorized Julia code to do this: https://github.com/ >>>>> lindahua/Devectorize.jl >>>>> >>>>> My vision is to write something equivalent to this to start: >>>>> http://jvns.ca/blog/2014/03/12/the-rust-os-story/ >>>>> >>>>> My first question is can it be done? If it can then I want to open up >>>>> this feed to discussions on the design. Or maybe if it can't, will this >>>>> ever be in the scope of Julia. >>>>> >>>>> Any resources or rants would be great! >>>>> >>>> >>
