FAQ
I have been wanting to do this but I have been wondering if there is going
to be an easy way to deal with memory management.

Should I recompile the language with allocation or write the memory
management in ASM? Thoughts, ideas?

--

Search Discussions

  • Bryanturley at Sep 20, 2012 at 6:42 pm
    Are you asking if there should be a go version for making operating systems
    separate from the normal go?
    I may be wrong but I am sure the answer to that is no.
    There have been a few os attempts in go that I am aware of you should
    search them out.
    On Thursday, September 20, 2012 1:04:45 PM UTC-5, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is going
    to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    --
  • Kyle Lemons at Sep 20, 2012 at 6:44 pm
    The go runtime and standard library depend on system calls, which are
    handled by a kernel. If you want to write a kernel in Go, you will need a
    runtime that doesn't. There was such a beast at one point (called "tiny")
    but it was a toy and was never maintained, and thus removed.
    On Thu, Sep 20, 2012 at 11:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is going
    to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?

    --

    --
  • Steven Rice at Sep 20, 2012 at 7:23 pm
    Yeah. Perhaps I should write basics in C and ASM, then put Go on top of it.
    On Thursday, September 20, 2012 1:44:13 PM UTC-5, Kyle Lemons wrote:

    The go runtime and standard library depend on system calls, which are
    handled by a kernel. If you want to write a kernel in Go, you will need a
    runtime that doesn't. There was such a beast at one point (called "tiny")
    but it was a toy and was never maintained, and thus removed.

    On Thu, Sep 20, 2012 at 11:04 AM, Steven Rice <stevenw...@gmail.com<javascript:>
    wrote:
    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?

    --

    --
  • Rob Pike at Sep 20, 2012 at 7:57 pm

    On Fri, Sep 21, 2012 at 4:57 AM, Steven Rice wrote:
    Yeah. Perhaps I should write basics in C and ASM, then put Go on top of it.
    Worked for us.

    -rob

    --
  • Paulo Pinto at Sep 21, 2012 at 7:44 am
    You just need a tiny bit of ASM, everything could be written in Go.

    Have a look how Native Oberon was implemented. Go is quite similar to
    Oberon.

    www.inf.ethz.ch/personal/wirth/books/ProjectOberon.pdf

    Although only used at ETHZ, it was a quite capable desktop OS for its
    time (middle 90's),
    http://en.wikipedia.org/wiki/Oberon_%28operating_system%29

    Here you can have a look at BlueBottle, which is a successor to Native
    Oberon, implemented in
    Active Oberon, which is basically Oberon + Actors.

    http://bluebottle.ethz.ch/
    http://www.ocp.inf.ethz.ch/forum/

    You can get a few VM images from this discussion thread,
    http://www.ocp.inf.ethz.ch/forum/index.php/topic,692.0.html

    Some screenshots available at http://www.ocp.inf.ethz.ch/wiki/Documentation/WindowManager

    Good luck,

    --
    Paulo
    On Sep 20, 8:57 pm, Steven Rice wrote:
    Yeah. Perhaps I should write basics in C and ASM, then put Go on top of it.






    On Thursday, September 20, 2012 1:44:13 PM UTC-5, Kyle Lemons wrote:

    The go runtime and standard library depend on system calls, which are
    handled by a kernel.  If you want to write a kernel in Go, you will need a
    runtime that doesn't.  There was such a beast at one point (called "tiny")
    but it was a toy and was never maintained, and thus removed.
    On Thu, Sep 20, 2012 at 11:04 AM, Steven Rice <stevenw...@gmail.com<javascript:>
    wrote:
    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.
    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    --
    --
  • Jan Mercl at Sep 21, 2012 at 8:59 am
  • Anssi Porttikivi at Sep 21, 2012 at 12:17 pm
    I've been waiting that Rob et al. will announce Plan 10, in Go...;-) Or
    perhaps Inferno 2?

    --
  • Anssi Porttikivi at Sep 21, 2012 at 12:21 pm
    Just wonder, if that will come before or after the GoScript browser
    environment. ;-)

    perjantai, 21. syyskuuta 2012 15.11.40 UTC+3 Anssi Porttikivi kirjoitti:
    I've been waiting that Rob et al. will announce Plan 10, in Go...;-) Or
    perhaps Inferno 2?
    --
  • Bogdan Radacina at Sep 22, 2012 at 5:00 am

    On Friday, 21 September 2012 06:14:46 UTC-6, Anssi Porttikivi wrote:
    Just wonder, if that will come before or after the GoScript browser
    environment. ;-)

    perjantai, 21. syyskuuta 2012 15.11.40 UTC+3 Anssi Porttikivi kirjoitti:
    I've been waiting that Rob et al. will announce Plan 10, in Go...;-) Or
    perhaps Inferno 2?
    I propose to call it GoST :)

    --
  • David Symonds at Sep 21, 2012 at 1:28 pm

    On Fri, Sep 21, 2012 at 10:11 PM, Anssi Porttikivi wrote:

    I've been waiting that Rob et al. will announce Plan 10, in Go...;-) Or perhaps Inferno 2?
    We have nothing to announce at this stage.

    --
  • Anssi Porttikivi at Sep 23, 2012 at 7:41 am
    Anyway, the current OS market is similar to the programming language market: dominant dinosaurs and limited niche products. There is as much hidden need for a modern, elegant, general purpose OS as there was for a language. Let's just use Go as leverage and bring Plan 9 back from the grave. That modern system from the early 90's ;-)

    --
  • Steven Rice at Sep 21, 2012 at 1:27 pm
    Also http://www.google.com

    I do frequent osdev.org though.
    On Friday, September 21, 2012 3:59:18 AM UTC-5, Jan Mercl wrote:

    Obligatory link: http://wiki.osdev.org/Main_Page

    -j
    --
  • Tibor at Sep 25, 2012 at 1:51 am
    Is there any chance for "tiny" to resurrect at some point? Is there a
    source repo from which one can learn?
    On Thursday, September 20, 2012 11:44:13 AM UTC-7, Kyle Lemons wrote:

    The go runtime and standard library depend on system calls, which are
    handled by a kernel. If you want to write a kernel in Go, you will need a
    runtime that doesn't. There was such a beast at one point (called "tiny")
    but it was a toy and was never maintained, and thus removed.

    On Thu, Sep 20, 2012 at 11:04 AM, Steven Rice <stevenw...@gmail.com<javascript:>
    wrote:
    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?

    --

    --
  • Harley Laue at Sep 25, 2012 at 4:53 am
    It's still in the mercurial repo. Checkout 7243:6185df48facb and tiny is still
    in the source tree. It'll likely take some work to get it working (because it
    was broken when it wasn't working IIRC when removed in commit 7244)
    On Monday, September 24, 2012 06:51:09 PM Tibor wrote:
    Is there any chance for "tiny" to resurrect at some point? Is there a
    source repo from which one can learn?
    On Thursday, September 20, 2012 11:44:13 AM UTC-7, Kyle Lemons wrote:
    The go runtime and standard library depend on system calls, which are
    handled by a kernel. If you want to write a kernel in Go, you will need a
    runtime that doesn't. There was such a beast at one point (called "tiny")
    but it was a toy and was never maintained, and thus removed.

    On Thu, Sep 20, 2012 at 11:04 AM, Steven Rice
    <stevenw...@gmail.com<javascript:>>
    wrote:
    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    --
  • Uriel at Sep 25, 2012 at 5:26 am

    On Tue, Sep 25, 2012 at 6:53 AM, Harley Laue wrote:
    It's still in the mercurial repo. Checkout 7243:6185df48facb and tiny is still
    in the source tree. It'll likely take some work to get it working (because it
    was broken when it wasn't working IIRC when removed in commit 7244)
    There is also:

    http://code.google.com/p/tinygo/

    --
  • Steven Rice at Sep 25, 2012 at 1:22 pm
    I'm going to start a GitHub repo, it will be slow at the start for sure. I
    would like others to contribute if they wish but I will definitely need to
    lay down a basic idea/structure first. I will also put tiny on GitHub, I
    will most likely play with getting it working before the OS so lots of
    source code reading ahead :)
    On Monday, September 24, 2012 8:51:09 PM UTC-5, Tibor wrote:

    Is there any chance for "tiny" to resurrect at some point? Is there a
    source repo from which one can learn?
    On Thursday, September 20, 2012 11:44:13 AM UTC-7, Kyle Lemons wrote:

    The go runtime and standard library depend on system calls, which are
    handled by a kernel. If you want to write a kernel in Go, you will need a
    runtime that doesn't. There was such a beast at one point (called "tiny")
    but it was a toy and was never maintained, and thus removed.
    On Thu, Sep 20, 2012 at 11:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?

    --

    --
  • Harley Laue at Sep 25, 2012 at 1:58 pm
    I wish you luck and will likely watch your progress. :)
    On Tue, Sep 25, 2012 at 8:22 AM, Steven Rice wrote:
    I'm going to start a GitHub repo, it will be slow at the start for sure. I
    would like others to contribute if they wish but I will definitely need to
    lay down a basic idea/structure first. I will also put tiny on GitHub, I
    will most likely play with getting it working before the OS so lots of
    source code reading ahead :)

    On Monday, September 24, 2012 8:51:09 PM UTC-5, Tibor wrote:

    Is there any chance for "tiny" to resurrect at some point? Is there a
    source repo from which one can learn?
    On Thursday, September 20, 2012 11:44:13 AM UTC-7, Kyle Lemons wrote:

    The go runtime and standard library depend on system calls, which are
    handled by a kernel. If you want to write a kernel in Go, you will need a
    runtime that doesn't. There was such a beast at one point (called "tiny")
    but it was a toy and was never maintained, and thus removed.

    On Thu, Sep 20, 2012 at 11:04 AM, Steven Rice <stevenw...@gmail.com>
    wrote:
    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?

    --
    --
    --
  • Tibor at Sep 27, 2012 at 6:24 am
    Good luck man!! I'll try to look into that and contribute if I can!
    On Tuesday, September 25, 2012 6:22:01 AM UTC-7, Steven Rice wrote:

    I'm going to start a GitHub repo, it will be slow at the start for sure. I
    would like others to contribute if they wish but I will definitely need to
    lay down a basic idea/structure first. I will also put tiny on GitHub, I
    will most likely play with getting it working before the OS so lots of
    source code reading ahead :)
    On Monday, September 24, 2012 8:51:09 PM UTC-5, Tibor wrote:

    Is there any chance for "tiny" to resurrect at some point? Is there a
    source repo from which one can learn?
    On Thursday, September 20, 2012 11:44:13 AM UTC-7, Kyle Lemons wrote:

    The go runtime and standard library depend on system calls, which are
    handled by a kernel. If you want to write a kernel in Go, you will need a
    runtime that doesn't. There was such a beast at one point (called "tiny")
    but it was a toy and was never maintained, and thus removed.
    On Thu, Sep 20, 2012 at 11:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?

    --

    --
  • Minux at Sep 21, 2012 at 4:31 am

    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is going
    to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.

    Do you seriously want to use Go to write an OS? What do you plan to do?
    I'm interested.

    --
  • Steven Rice at Sep 21, 2012 at 2:33 pm
    I want to use it as a learning experience, and as a project I think is just
    extremely interesting. I think Go is a powerful language for writing
    services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:


    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice <stevenw...@gmail.com<javascript:>
    wrote:
    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.

    Do you seriously want to use Go to write an OS? What do you plan to do?
    I'm interested.
    --
  • Archos at Sep 23, 2012 at 7:27 am
    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).

    Then, that language would be the key piece to create kernels, kernel
    modules, DBMS, windows systems, etc.

    El viernes, 21 de septiembre de 2012 14:25:28 UTC+1, Steven Rice escribió:
    I want to use it as a learning experience, and as a project I think is
    just extremely interesting. I think Go is a powerful language for writing
    services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:

    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.

    Do you seriously want to use Go to write an OS? What do you plan to do?
    I'm interested.
    --
  • Jesse McNelis at Sep 23, 2012 at 7:44 am

    On Sun, Sep 23, 2012 at 5:27 PM, Archos wrote:
    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).
    That language exists. It's commonly referred to as C.



    --
    =====================
    http://jessta.id.au

    --
  • Archos at Sep 23, 2012 at 9:52 am
    To make true that affirmation, C should

    + remove preprocessor directives and macros to get a fast compilation like
    Go using its build system (no makefiles).
    + add iotas, helping to simplify the addition of constants
    + have simple names for types like Go, instead of to have large types like
    " signed long long int"
    + have concurrency (C11 has support for multithreading)
    + have methods in functions
    ...

    El domingo, 23 de septiembre de 2012 08:44:35 UTC+1, Jesse McNelis escribió:
    On Sun, Sep 23, 2012 at 5:27 PM, Archos <raul...@sent.com <javascript:>>
    wrote:
    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).
    That language exists. It's commonly referred to as C.



    --
    =====================
    http://jessta.id.au
    --
  • Chris dollin at Sep 23, 2012 at 7:54 am

    On 23 September 2012 08:27, Archos wrote:
    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).
    I don't think you've thought through the implications of
    removing the GC on slices, strings, closures, and maps.

    Chris

    --
    Chris "allusive" Dollin

    --
  • Archos at Sep 23, 2012 at 9:56 am
    It could not have the types that depend of the GC like slices, maps; the
    strings should be handled like in C. But with some basic libraries (fmt,
    log, strings, bytes) I think would be enough to build things at low level
    (that I already said).

    El domingo, 23 de septiembre de 2012 08:54:34 UTC+1, chris dollin escribió:
    On 23 September 2012 08:27, Archos <raul...@sent.com <javascript:>>
    wrote:
    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).
    I don't think you've thought through the implications of
    removing the GC on slices, strings, closures, and maps.

    Chris

    --
    Chris "allusive" Dollin
    --
  • DisposaBoy at Sep 23, 2012 at 9:54 am

    On Sunday, September 23, 2012 10:50:32 AM UTC+1, Archos wrote:
    It could not have the types that depend of the GC like slices, maps; the
    strings should be handled like in C. But with some basic libraries (fmt,
    log, strings, bytes) I think would be enough to build things at low level
    (that I already said).
    If that's the case then how would it be any different from C with an
    appropriately designed library. Hell, I'm pretty sure even GLib gets you
    very close already.

    --
  • Thomas Bushnell, BSG at Sep 23, 2012 at 8:05 am
    It's perfectly feasible to write a kernel in a garbage collected language.
    On Sep 23, 2012 12:27 AM, "Archos" wrote:

    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).

    Then, that language would be the key piece to create kernels, kernel
    modules, DBMS, windows systems, etc.

    El viernes, 21 de septiembre de 2012 14:25:28 UTC+1, Steven Rice escribió:
    I want to use it as a learning experience, and as a project I think is
    just extremely interesting. I think Go is a powerful language for writing
    services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:

    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.

    Do you seriously want to use Go to write an OS? What do you plan to do?
    I'm interested.
    --
    --
  • Michael Jones at Sep 23, 2012 at 9:22 am
    ...as Smalltalk proved. ;-)

    On Sun, Sep 23, 2012 at 4:05 AM, Thomas Bushnell, BSG
    wrote:
    It's perfectly feasible to write a kernel in a garbage collected language.
    On Sep 23, 2012 12:27 AM, "Archos" wrote:

    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).

    Then, that language would be the key piece to create kernels, kernel
    modules, DBMS, windows systems, etc.

    El viernes, 21 de septiembre de 2012 14:25:28 UTC+1, Steven Rice escribió:
    I want to use it as a learning experience, and as a project I think is
    just extremely interesting. I think Go is a powerful language for writing
    services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:


    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice <stevenw...@gmail.com>
    wrote:
    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.

    Do you seriously want to use Go to write an OS? What do you plan to do?
    I'm interested.
    --
    --


    --
    Michael T. Jones | Chief Technology Advocate | mtj@google.com | +1
    650-335-5765

    --
  • Archos at Sep 23, 2012 at 9:56 am
    The fact that it is possible is different to get an acceptable performance

    http://wiki.osdev.org/Languages#Can_I_use_language_XYZ.3F


    El domingo, 23 de septiembre de 2012 09:05:22 UTC+1, Thomas Bushnell, BSG
    escribió:
    It's perfectly feasible to write a kernel in a garbage collected language.
    On Sep 23, 2012 12:27 AM, "Archos" <raul...@sent.com <javascript:>> wrote:

    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).

    Then, that language would be the key piece to create kernels, kernel
    modules, DBMS, windows systems, etc.

    El viernes, 21 de septiembre de 2012 14:25:28 UTC+1, Steven Rice escribió:
    I want to use it as a learning experience, and as a project I think is
    just extremely interesting. I think Go is a powerful language for writing
    services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:

    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.

    Do you seriously want to use Go to write an OS? What do you plan to do?
    I'm interested.
    --
    --
  • Paulo Pinto at Sep 23, 2012 at 10:41 am
    Well, Native Oberon and Bluebottle are fast enough for a desktop OS.
    On Sep 23, 11:56 am, Archos wrote:
    The fact that it is possible is different to get an acceptable performance

    http://wiki.osdev.org/Languages#Can_I_use_language_XYZ.3F

    El domingo, 23 de septiembre de 2012 09:05:22 UTC+1, Thomas Bushnell, BSG
    escribió:








    It's perfectly feasible to write a kernel in a garbage collected language.
    On Sep 23, 2012 12:27 AM, "Archos" <raul...@sent.com <javascript:>> wrote:

    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).
    Then, that language would be the key piece to create kernels, kernel
    modules, DBMS, windows systems, etc.
    El viernes, 21 de septiembre de 2012 14:25:28 UTC+1, Steven Rice escribió:
    I want to use it as a learning experience, and as a project I think is
    just extremely interesting. I think Go is a powerful language for writing
    services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:
    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.
    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.
    Do you seriously want to use Go to write an OS? What do you plan to do?
    I'm interested.
    --
    --
  • Thomas Bushnell, BSG at Sep 23, 2012 at 3:01 pm
    I must never have used a lispm at all, I guess.
    On Sep 23, 2012 2:56 AM, "Archos" wrote:

    The fact that it is possible is different to get an acceptable performance

    http://wiki.osdev.org/Languages#Can_I_use_language_XYZ.3F


    El domingo, 23 de septiembre de 2012 09:05:22 UTC+1, Thomas Bushnell, BSG
    escribió:
    It's perfectly feasible to write a kernel in a garbage collected language.
    On Sep 23, 2012 12:27 AM, "Archos" wrote:

    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).

    Then, that language would be the key piece to create kernels, kernel
    modules, DBMS, windows systems, etc.

    El viernes, 21 de septiembre de 2012 14:25:28 UTC+1, Steven Rice
    escribió:
    I want to use it as a learning experience, and as a project I think is
    just extremely interesting. I think Go is a powerful language for writing
    services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:

    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.

    Do you seriously want to use Go to write an OS? What do you plan to do?
    I'm interested.
    --
    --
    --
  • Archos at Sep 23, 2012 at 4:16 pm
    The Lisp machines had hardware support for various primitive Lisp
    Operations and also hardware support for incremental garbage collection.

    http://www.thefullwiki.org/Lisp_machine

    El domingo, 23 de septiembre de 2012 16:01:27 UTC+1, Thomas Bushnell, BSG
    escribió:
    I must never have used a lispm at all, I guess.
    On Sep 23, 2012 2:56 AM, "Archos" <raul...@sent.com <javascript:>> wrote:

    The fact that it is possible is different to get an acceptable performance

    http://wiki.osdev.org/Languages#Can_I_use_language_XYZ.3F


    El domingo, 23 de septiembre de 2012 09:05:22 UTC+1, Thomas Bushnell, BSG
    escribió:
    It's perfectly feasible to write a kernel in a garbage collected
    language.
    On Sep 23, 2012 12:27 AM, "Archos" wrote:

    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).

    Then, that language would be the key piece to create kernels, kernel
    modules, DBMS, windows systems, etc.

    El viernes, 21 de septiembre de 2012 14:25:28 UTC+1, Steven Rice
    escribió:
    I want to use it as a learning experience, and as a project I think is
    just extremely interesting. I think Go is a powerful language for writing
    services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:

    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.

    Do you seriously want to use Go to write an OS? What do you plan to
    do?
    I'm interested.
    --
    --
    --
  • Paulo Pinto at Sep 23, 2012 at 4:23 pm
    Sure, but you nicely forgot that shortly thereafter there was hardware
    available that was capable of offering similar performance without
    those special instructions.

    The Smalltalk environments did not require any special hardware
    instructions
    for example.
    On Sep 23, 6:16 pm, Archos wrote:
    The Lisp machines had hardware support for various primitive Lisp
    Operations and also hardware support for incremental garbage collection.

    http://www.thefullwiki.org/Lisp_machine

    El domingo, 23 de septiembre de 2012 16:01:27 UTC+1, Thomas Bushnell, BSG
    escribió:








    I must never have used a lispm at all, I guess.
    On Sep 23, 2012 2:56 AM, "Archos" <raul...@sent.com <javascript:>> wrote:

    The fact that it is possible is different to get an acceptable performance
    El domingo, 23 de septiembre de 2012 09:05:22 UTC+1, Thomas Bushnell, BSG
    escribió:
    It's perfectly feasible to write a kernel in a garbage collected
    language.
    On Sep 23, 2012 12:27 AM, "Archos" wrote:

    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).
    Then, that language would be the key piece to create kernels, kernel
    modules, DBMS, windows systems, etc.
    El viernes, 21 de septiembre de 2012 14:25:28 UTC+1, Steven Rice
    escribió:
    I want to use it as a learning experience, and as a project I think is
    just extremely interesting. I think Go is a powerful language for writing
    services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:
    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is
    going to be an easy way to deal with memory management.
    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.
    Do you seriously want to use Go to write an OS? What do you plan to
    do?
    I'm interested.
    --
    --
    --
  • Thomas Bushnell, BSG at Sep 23, 2012 at 4:30 pm
    The garbage collector, however, was written in Lisp, with the inner loops
    in assembly language.

    This is not that different than any kernel. To use Go as a kernel
    programming language, you would need to write a specialized version of the
    runtime, and you would probably write it in a combination of Go, C, and
    assembly, just as the current runtime is. This is perfectly normal: the C
    library is not written in pure C (nor could it be), and the Linux kernel
    must have its own specialized version of it.

    There's nothing special about kernel programming here: to implement Go you
    need to write a garbage collector, and you're (probably) going to write it
    in a language other than Go.

    The link you refer to does *not *say anything about performance, though if
    you think that garbage collection is some kind of bar to performance--even
    hard real time performance--I'd suggest you read up on real-time garbage
    collection techniques. Of course, the standard Go implementation now does
    not support these things, but Go is not like Python or Ruby: it is not
    defined by a particular implementation, but by a specification.

    Thomas

    On Sun, Sep 23, 2012 at 9:16 AM, Archos wrote:

    The Lisp machines had hardware support for various primitive Lisp
    Operations and also hardware support for incremental garbage collection.

    http://www.thefullwiki.org/Lisp_machine

    El domingo, 23 de septiembre de 2012 16:01:27 UTC+1, Thomas Bushnell, BSG
    escribió:
    I must never have used a lispm at all, I guess.
    On Sep 23, 2012 2:56 AM, "Archos" wrote:

    The fact that it is possible is different to get an acceptable
    performance

    http://wiki.osdev.org/**Languages#Can_I_use_language_**XYZ.3F<http://wiki.osdev.org/Languages#Can_I_use_language_XYZ.3F>


    El domingo, 23 de septiembre de 2012 09:05:22 UTC+1, Thomas Bushnell,
    BSG escribió:
    It's perfectly feasible to write a kernel in a garbage collected
    language.
    On Sep 23, 2012 12:27 AM, "Archos" wrote:

    I think that could be usefull to the community if somebody creates a
    language based in Go; using both sintaxis, features and types of Go but
    without the garbage collector like C, to manage manually the memory
    (free/malloc).

    Then, that language would be the key piece to create kernels, kernel
    modules, DBMS, windows systems, etc.

    El viernes, 21 de septiembre de 2012 14:25:28 UTC+1, Steven Rice
    escribió:
    I want to use it as a learning experience, and as a project I think
    is just extremely interesting. I think Go is a powerful language for
    writing services and would be really fun to use in this type of project.
    On Thursday, September 20, 2012 11:31:17 PM UTC-5, minux wrote:

    On Fri, Sep 21, 2012 at 2:04 AM, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there
    is going to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    This is possible, but not as easy as recompilation.

    Do you seriously want to use Go to write an OS? What do you plan to
    do?
    I'm interested.
    --
    --
    --
    --
  • Russel Winder at Sep 23, 2012 at 5:57 pm
    On Sun, 2012-09-23 at 09:30 -0700, Thomas Bushnell, BSG wrote:
    […]
    not support these things, but Go is not like Python or Ruby: it is not
    defined by a particular implementation, but by a specification.
    Just for the record: Python is defined by a specification owned by the
    Python Software Foundation. CPython, PyPy and Jython are but
    implementations of the specification.

    --
    Russel.
    =============================================================================
    Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder@ekiga.net
    41 Buckmaster Road m: +44 7770 465 077 xmpp: russel@winder.org.uk
    London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
  • Russel Winder at Sep 23, 2012 at 5:54 pm

    On Sun, 2012-09-23 at 09:16 -0700, Archos wrote:
    The Lisp machines had hardware support for various primitive Lisp
    Operations and also hardware support for incremental garbage collection.

    http://www.thefullwiki.org/Lisp_machine
    Of course even the IBM 704 had specialized hardware to support Lisp and
    that was in 1954: there was the content address register to support the
    car function and the content data register to support the cdr function.

    :-)

    Long live cons lists.

    And recursion. Who needs iteration.

    ;-)

    --
    Russel.
    =============================================================================
    Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder@ekiga.net
    41 Buckmaster Road m: +44 7770 465 077 xmpp: russel@winder.org.uk
    London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
  • Dan Cross at Sep 24, 2012 at 12:18 am

    On Sun, Sep 23, 2012 at 1:54 PM, Russel Winder wrote:
    On Sun, 2012-09-23 at 09:16 -0700, Archos wrote:
    The Lisp machines had hardware support for various primitive Lisp
    Operations and also hardware support for incremental garbage collection.

    http://www.thefullwiki.org/Lisp_machine
    Of course even the IBM 704 had specialized hardware to support Lisp and
    that was in 1954: there was the content address register to support the
    car function and the content data register to support the cdr function.

    [...]
    I think you have it backwards; Lisp's cons cells mapped nicely to 704
    instructions, but the IBM 704 predated Lisp. That is, car and cdr
    were so-named because of the address and decrement registers on the
    IBM 704; those were not created to support Lisp. See, e.g.,
    http://www-formal.stanford.edu/jmc/history/lisp/node2.html

    I'm afraid this is only tangentially related to Go.

    - Dan C.

    --
  • Steven Rice at Sep 24, 2012 at 5:39 am
    I am probably going to fork Go and instead of removing GC, I will just add
    manual memory management. I need to change specific things anyways. I also
    plan on building an shell that is scripted with Go.

    To all the people who said "Then it would be C" Is your opinion of Go
    really as as simple as "C with garbage collection"? If so, you are
    overlooking very important and amazing features of the language.

    --
  • Paulo Pinto at Sep 24, 2012 at 6:28 am

    On Sep 24, 7:39 am, Steven Rice wrote:
    I am probably going to fork Go and instead of removing GC, I will just add
    manual memory management. I need to change specific things anyways. I also
    plan on building an shell that is scripted with Go.
    If you follow this route, there isn't much to be learned from the
    process. We already
    have enough hobby OS developed in GC-less languages.

    Spend some time researching about how Native Oberon(Oberon), Blue
    Bottle(Active Oberon), Spin (Modula-3),
    Singularity(Sing#), Jnode (Java), Home(Haskell), Symbolics(Lisp
    Machine), Smalltalk(Smalltalk),
    XCP(OCaml), Cosmos(C#) and many others got implemented.

    Many of those systems make use of ASM for the bootloader, hardware
    interfaces for driver IO and GC, while
    everything else gets done in the respective language. In some cases
    the GC gets coded in C or C++ instead,
    but if you read the papers mostly it was done to speedup bootstraping
    and not because the language did not
    provide the required functionality.

    Before you consider those operating systems as irrelevant, because
    they are either research operating systems,
    or commercial failures, consider that the reasons why they didn't went
    further are mostly something else that
    having a systems programming language with GC.
    To all the people who said "Then it would be C" Is your opinion of Go
    really as as simple as "C with garbage collection"? If so, you are
    overlooking very important and amazing features of the language.
    Such as? Many of such features rely in GC availability, if you remove
    the GC then it is like C or a Pascal dialect
    like Turbo/Free Pascal.

    --
  • Steven Rice at Sep 24, 2012 at 1:24 pm
    Such as orthogonality, fast compilation, the lack of header files, lack of
    generics, lack of method overloading, lack of pointer arithmetic, lack of
    assertions, interfaces without annoying "implements" statements. Then there
    are the little features that make a big difference in the feel of the
    language, like the ":=" assignment.
    On Monday, September 24, 2012 1:28:10 AM UTC-5, Paulo Pinto wrote:

    Such as? Many of such features rely in GC availability, if you remove
    the GC then it is like C or a Pascal dialect
    like Turbo/Free Pascal.
    --
  • Paulo Pinto at Sep 24, 2012 at 1:33 pm
    Most of those features are available in Turbo Pascal family which was
    part of my comment.

    Only the interfaces and type inference don't apply.

    As for lack of generics and method overloading I disagree it is a
    feature.
    On Sep 24, 3:24 pm, Steven Rice wrote:
    Such as orthogonality, fast compilation, the lack of header files, lack of
    generics, lack of method overloading, lack of pointer arithmetic, lack of
    assertions, interfaces without annoying "implements" statements. Then there
    are the little features that make a big difference in the feel of the
    language, like the ":=" assignment.






    On Monday, September 24, 2012 1:28:10 AM UTC-5, Paulo Pinto wrote:

    Such as? Many of such features rely in GC availability, if you remove
    the GC then it is like C or a Pascal dialect
    like Turbo/Free Pascal.
    --
  • Steven Rice at Sep 24, 2012 at 2:38 pm
    //most// Anyways as for your opinion of what is a feature, just because you
    disagree with a feature does not mean it isn't a feature. I assure you that
    those two were not left out by accident.
    On Monday, September 24, 2012 8:33:19 AM UTC-5, Paulo Pinto wrote:

    Most of those features are available in Turbo Pascal family which was
    part of my comment.

    Only the interfaces and type inference don't apply.

    As for lack of generics and method overloading I disagree it is a
    feature.
    On Sep 24, 3:24 pm, Steven Rice wrote:
    Such as orthogonality, fast compilation, the lack of header files, lack of
    generics, lack of method overloading, lack of pointer arithmetic, lack of
    assertions, interfaces without annoying "implements" statements. Then there
    are the little features that make a big difference in the feel of the
    language, like the ":=" assignment.






    On Monday, September 24, 2012 1:28:10 AM UTC-5, Paulo Pinto wrote:

    Such as? Many of such features rely in GC availability, if you remove
    the GC then it is like C or a Pascal dialect
    like Turbo/Free Pascal.
    --
  • Tibor at Sep 25, 2012 at 1:47 am
    I'm also very interested. Please notify this thread of your achievements
    and how we can contribute. Thanks!
    On Thursday, September 20, 2012 11:04:45 AM UTC-7, Steven Rice wrote:

    I have been wanting to do this but I have been wondering if there is going
    to be an easy way to deal with memory management.

    Should I recompile the language with allocation or write the memory
    management in ASM? Thoughts, ideas?
    --

Related Discussions

People

Translate

site design / logo © 2022 Grokbase