Several of you have been following our adventures on Github issues in the past 6 months.
Status.im is betting on Nim for a next-gen mobile friendly Ethereum client called Nimbus.
Announcement is here.
Feel free to ask me anything. Let's start by the most obvious questions:
A. What does it mean for Nim?
Obviously more visibility, the blockchain community is growing at a rapid pace, with unique challenge and they are no afraid of adopting new things.
More libraries, with a mobile device focus, especially state-of-the art binary blob, networking, big integer, cryptographic, testing and logging libraries. Note that those will be security audited to work in adversarial settings and protect users' money.
- Samples:
- nim-chronicles, super-charged logging library
- nimcrypto, native crypto and hashing library, supports: Blake2, AES (Rijndael), PBKDF2, SHA2, SHA3, Keccak and several other schemes, ...
- Stint, The fastest portable Uint128, Uint256, Uint512, ... Uint[PowerOf2] library. Carefully tuned for best assembly generated and using state-of-the-art bigint algorithms. All fixed size stack allocated and allows compile-time calculation of every unsigned operations.
- Ranges, the memory range/span/slice/blob swiss-army knife library. Also serve as a playground for what might be needed by openarrays in the future.
- Byteutils A small utility library to work with memory blobs and their hex representation.
- AsyncDispatch2, an alternative to asyncdispatch, tradeoffs and design in the README.
- Daemon, a daemonization library
- Besides pure Nim libraries, several wrappers were also created:
- RocksDB, a state-of-the-art key-value store
- MpDecimal, a fixed precision decimal library. This is the default library used by Python to handle arbitrary precision integers and floats.
Honorary mention:
- Quicktest A Quickcheck/hypothesis testing to test assertions with random inputs.
B. Why Nim?
- Opportunity: Ethereum 2.0 is still at a pure research phase, and due to changes, this is will be a completely fresh start.
- Performance: The original Status client backend is the official one written in Go. Unfortunately for mobile devices benchmarks showed that Nim could improve performance (and so power consumption)
- C interface: Even though Nim ecosystem is small, it's easy to tap into existing C code, which is especially important for cryptography, and also to quickly test the waters before dedicating more time to a native Nim implementation.
- Research: The Ethereum Foundation research is done in Python, Nim enables us to quickly reproduce research for our own proof-of-concepts or bridge the gap between research and production.
You are also very welcome to contribute, sorry for the state of documentation in some projects, we're always available on Gitter/IRC in any case.