Basically we use the CPUID instruction, present on the original Pentium and above (and what if you want to run Factor on a 486? Sucks to be you! You'll need an FPU, at least, but it will work. Just pass the
-no-sse2switch to skip detection altogether). The code for this was written by Doug, with a bit of explanation on my part regarding some (presently undocumented) compiler internals. It serves as a simple demonstration of defining a new compiler intrinsic. Check it out.
... and what about the ARM port? There was a "day 4", but I didn't blog about it, because it was boring... all I did was fix some bugs and define some intrinsics. However I was doing all this in QEMU, because my Gumstix was borked (I corrupted the root fs). QEMU was too slow to be usable and it was quite frustrating to use, so I put the port aside. I ordered a serial daughterboard for my Gumstix, which arrived today, and I successfully reflashed it. So the porting work will continue, and in fact the only thing that remains is FFI support.
A major core feature I implemented in the last few days is an automatically growing data heap. You can still specify a heap size larger than the default on startup, but its not necessary because it will grow as needed.
Lots of hacking all around.