YMMV.
In most cases, MCU IDE's like the classic Arduino one don't even give you an allocator, all data must be statically allocated beforehand.
IIRC it doesn't use the stack either. The main() and loop() functions initialize all their variables statically.
When you have 2KB of memory to share between code, data and stack, allocating and using stack for function calls is luxury that only introduces problems.
Hence, I've never ever ever seen an MCU crash from segfaults or OOMs.
On the plus side they will also use vastly less energy. 10 Milliamps is enough to drive a ESP8266 or ESP32, in deep sleep you start counting microamps. A single battery cell can easily last a month.
I'm guessing industry hasn't produced this in a streamlined (reasonable) device because it will never be certified, and open source is just a codeword for subverting the regulatory process. Which, from a diabetes sufferer POV, is understandable.
The dark cloud on the horizon is that if the FCC throws a hissy fit because you can install new software on your wireless router, imagine what the FDA will do if you market your device as compatible with this open source software that claims to automagically control your insulin pump.
No cables at all (and no infusion set cord if you use an Omnipod pump!)
I myself use Loop. It's an iOS app that uses a RF-to-BT bridge to talk with the pump and intercepts the CGM reading from the official Dexcom app (there are forks that support different methods, being the Dexcom source the "official" one). The bridge is the size of a 9V battery, I never stopped to see which processor uses but it's probably 8 bit.
Each system support different pumps, sometimes people want to use one but are stuck with a different one to be able to use their pumps.