nimkernel VS cosmonim

Compare nimkernel vs cosmonim and see what are their differences.

nimkernel

A small kernel written in Nim (by dom96)

cosmonim

A Nim template to compile your code with the Cosmopolitan libc (by Yardanico)
InfluxDB - Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
www.influxdata.com
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
nimkernel cosmonim
4 3
607 116
- -
0.0 2.5
over 2 years ago about 1 year ago
Nim Nim
GNU General Public License v3.0 or later MIT License
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

nimkernel

Posts with mentions or reviews of nimkernel. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-12-03.
  • D Programming Language
    13 projects | news.ycombinator.com | 3 Dec 2023
    > kernel developers do not allow third party runtimes in the kernel. Even meager Rust's "panic" runtime is a contentious

    Much in Linux is contentious :-) which is why the module system is nice. A kernel module for C code requires no permission from Linux-core unless you need it distributed with the kernel (which, yes, might be required for "credibility" - but critically also might not). It may require many decls to access various kernel APIs, but those can be (semi-)automated or just done as-needed. So, Linux kernel policy is not so relevant (at best) which is what I meant by "no special support" (admittedly brief). Kernel coding is always a bit trickier, and you may need to build up some support code to make integration nice, though as well as decl generators.

    > Can one disable runtime in Nim completely -- no GC, no exceptions?

    To answer your question, and as discussed elsewhere in this subthread, Nim has many options for memory management.. only stdlib seq/string really needs automatic methods. One can disable the runtime completely via os:standalone and statically check that no exceptions are raised with Nim's effect system (and there are also both setjmp & goto based exception impls which may/may not be workable in Linux/BSD kernel module settings). As "proof more by example", a few people have written OS kernels in Nim recently[1,2] and there was another toy kernel long ago[3].

    People have also written OS kernels in Go which "has a GC and runtime".[4] So, I acknowledge it's not quite the same example, but I also see no fundamental blockers for kernel modules.

    [1] https://github.com/khaledh/axiom

    [2] https://prosepoetrycode.potterpcs.net/2023/01/a-barebones-ke...

    [3] https://github.com/dom96/nimkernel

    [4] https://github.com/mit-pdos/biscuit/

  • Ask HN: Why did Nim not catch-on like wild fire as Rust did?
    16 projects | news.ycombinator.com | 25 Jun 2023
    Niceness is subjective, but Nim is just as valid an addition to that group. Nim compiles to C and has had an --os=standalone mode for like 10 years from its git history, and as mentioned else-thread (https://news.ycombinator.com/item?id=36506087) can be used for Linux kernel modules. Multiple people have written "stub OSes" in it (https://github.com/dom96/nimkernel & further along https://github.com/khaledh/axiom).

    While it can use clang as a backend, Nim does not rely upon LLVM support like Zig or Rust (pre-gcc-rust working). Use on embedded devices is fairly popular: https://forum.nim-lang.org/search?q=embedded (or web search).

    Latency-wise, for a time, video game programming was a perceived "adoption niche" or maybe "hook" for Nim and games often have stringent frame rendering deadlines. If you are interested in video games, you might appreciate https://github.com/shish/rosettaboy which covers all but Ada in your list with Nim being fastest (on one CPU/version/compiler/etc). Note, however, that cross-PL comparisons are often done by those with much "porting energy" but limited familiarity with any but a few of the PLs. A better way to view it is that "Nim responds well to optimization effort" (like C/Ada/C++/Rust/Zig).

  • OSDev in Nim
    1 project | /r/nim | 8 Aug 2022
  • A small kernel written in Nim
    1 project | news.ycombinator.com | 14 Jan 2022

cosmonim

Posts with mentions or reviews of cosmonim. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-12-03.
  • D Programming Language
    13 projects | news.ycombinator.com | 3 Dec 2023
    In a word, yes.

    In more words: You should be able to use Cosmopolitan libc: https://github.com/Yardanico/cosmonim

    If something does not work for you, Yardanico is super duper helpful in all things Nim.

    Nim also compiles to Javascript (nim js) and C++ for integration with legacy codebases, but that is probably more to the side of your interests.

  • Patching GCC to Build Portable Executables
    13 projects | news.ycombinator.com | 13 Jul 2023
    I haven't used Nim much, but I remember a repo on Github had setup a build script for compiling Nim with Cosmopolitan Libc. https://github.com/Yardanico/cosmonim

    This gcc patch makes such build scripts simpler, because you will need to change less of your code -- let me know how it works!

  • Using Cosmopolitan Libc with Nim
    1 project | news.ycombinator.com | 2 Apr 2021

What are some alternatives?

When comparing nimkernel and cosmonim you can also consider the following projects:

procs - Unix process&system query&format lib&multi-command CLI in Nim

rust-ape-example - A simple example with Rust and Cosmopolitan Libc

iomrascalai - Iomrascálaí is an AI for the game of Go/Weiqi/Baduk written in Rust

blink - tiniest x86-64-linux emulator

wasmer - 🚀 The leading Wasm Runtime supporting WASIX, WASI and Emscripten

superconfigure - wrap autotools configure scripts to build with Cosmopolitan Libc

rosettaboy - A gameboy emulator in several different languages

ripgrep - ripgrep recursively searches directories for a regex pattern while respecting your gitignore

axiom - A 64-bit kernel implemented in Nim

gcc

vos - Vinix is an effort to write a modern, fast, and useful operating system in the V programming language

go - The Go programming language