Small and simple C compiler for x86 (DOS, Windows, Linux, Mac OS X) and MIPS (RetroBSD).
To make the experience fit your profile, pick a username and tell us what interests you.
The compiler can now self-host on Mac OS X and cross-compile for it, hooray!
Just added strtof(), strtod(), atof() and float parsing in *scanf()!
I've adapted the D-Flat Windowing System for compilation with Smaller C.
Here's a screenshot of a demo application, MemoPad, using it.
Unreal mode is now supported in the compiler! This is a screen capture from DOSBox running tests/vesalfb.c compiled using the -dosu option. VirtualBox produces similar results (different color palette, no text message).
I've adapted ucpp 1.3.2 for use with Smaller C. No need for workarounds such as invoking gcc (e.g. with the -ppg option). smlrpp should now be invoked automatically and it should just work.
Just added an SDL clock demo for Windows.
I've merged the work-in-progress branch into master and now most of floating point support is available on x86 too (this includes functions from <math.h>).
The Mandelbrot set image you're seeing here has been generated by a new test/demo program, which uses floating point.
Late last year we made a series of improvements in RetroBSD and Smaller C (switched to compiling apps and libraries as MIPS16e, made numerous fixes and improvements in the emulator (including MIPS16e support) and shrank one large array in the compiler), which significantly reduced the compiler in size, like by 20+ KB. That extra space made me think of what else could be implemented or improved in Smaller C.
Of the largest language debts stood out floating point. I looked at it and decided to give it a try and it was perfect timing as the long Xmas/NY break was approaching. So, over the period of several weeks I've implemented and tested basic support for float. RetroBSD builds with double equivalent to float (32-bit single precision, software implementation as the PIC32MX CPU does not contain an FPU) and Smaller C follows suit.
This still is a work in progress and there are a few other limitations like several operators still unsupported with floats (++, --, +=, -=, *=, /=), but other than that things seem to be working quite well.
Evolution / source code visualization of Smaller C. I have no idea why someone would make one for my project.
Become a member to follow this project and never miss any updates