News for hackers. Stuff that matters.
Re:WebAssembly without the browser by aerismio on Monday August 17, 2020 @07:13AM (#24186090)
Hard-realtime performance is very important for Microcontrollers. Do you think WASM can do hard-realtime?
Re:WebAssembly without the browser by tym0 on Monday August 17, 2020 @07:43AM (#24186262)
I think WASM can do hard-realtime but that's not really the goal of wasm3, they advertise 14x slow-down compared to "native". However I think a lot of usages of MCU are not actually "hard-realtime", my connected light bulb for example uses the ESP32, I don't think you would get a noticeable difference in perf by using wasm3 but you probably get a lot of benefits, OTA for example, running an interpreter.
Re:WebAssembly without the browser by hinkley on Tuesday August 18, 2020 @12:07PM (#24200398)
Hard real-time is fundamentally about never agreeing to start something you can’t finish.

It has nothing at all to do with throughput. What matters is whether there are any unbounded or loosely bounded operations in your call tree. Like memory management bookkeeping.

I worked with Aicas’ hard real-time VM for three years, although we were not using those features. Among other things, they had to implement their own amortizing garbage collector to do it. You’d need something similar for Rust to handle object life cycles. It’s also common to divide memory into regions so that different classes of traffic can’t exhaust system memory.

Re:WebAssembly without the browser by maxgraey on Monday August 17, 2020 @09:37AM (#24187069)
Did you see this repo? https://github.com/vshymanskyy/Wasm3_RGB_Lamp

It's realtime wasm3 led strip animation on 16 MHz Cortex-M0