![]() |
|
![]() |
| Yep I've done that before, it's how I know linking to the C runtime is what bloats the binary. For most real projects I wouldn't disable linking it, but it's fun to see the output get so small. |
![]() |
| Yes they could have just defined their own global operator new/delete to have a micro-runtime. Same as you'd do if you were doing a kernel in C++. Super easy, barely an inconvenience |
![]() |
| Sure, but there are also microcontrollers with a lot more space. This probably won’t ever usefully target the small ones, but that doesn’t mean it isn’t useful in the space at all. |
![]() |
| If you get rid of the runtime, which most compilers allow you to do, C++ is just as suitable for this task as C. Not as good as hand-rolled assembly, but usable |
![]() |
| > Considering that a C program with an empty main function is 6kB on this system, {fmt} now adds less than 10kB to the binary.
Interesting, I've never done this test! |
Chuckles