shithub: femtolisp

ref: 4f5436b163da902ca24743b9836309c8cc724b3f
dir: /main_plan9.c/

View raw version
#include "llt.h"

static char boot[] =
#include "flisp.boot.h"
;

void
main(int argc, char **argv)
{
	argv0 = argv[0];
	setfcr(FPPDBL|FPRNR|FPOVFL);
	tmfmtinstall();

	*(uint32_t*)&F_PNAN = 0x7fc00000;
	*(uint32_t*)&F_NNAN = 0xffc00000;
	*(uint32_t*)&F_PINF = 0x7f800000;
	*(uint32_t*)&F_NINF = 0xff800000;

	exit(flmain(boot, sizeof(boot), argc, argv));
}