[SAoC] "Druntime for Microcontrollers" project thread

IGotD- nise at nise.com
Mon Sep 21 16:48:28 UTC 2020

On Monday, 14 September 2020 at 07:59:08 UTC, Severin Teona wrote:
> Milestone 2:  Try to have a small object.d implementation
> - Continue removing any functionality a small class doesn’t 
> need.
> - Try to test the new ‘object.d’ on the microcontroller after a 
> successful build of the file.

If you are going to port the garbage collector, then what is the 
point of changing object.d. Yes, each class comes with extra 
typeinfo which takes up space but if that's a big problem then 
you are in a microcontroller size class that is not suitable for 
D. Then betterC and C is a better choice. I'm thinking about 
something like systems with 512KB RAM/Flash and more, then is the 
extra type information that big of a problem? D is great as it 
allows dynamic RTTI (C++ term) by default and by removing 
typeinfo you will remove such functionality.

Systems that has 32KB of RAM and such, forget about D all 
together and use C (not even C++). BetterC might work though.

I haven't done any size comparison what you really save by 
removing the extra meta data. Do anyone really know how much it 
really is?

More information about the Digitalmars-d mailing list