You can subscribe to this list here.
| 2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(56) |
Sep
(40) |
Oct
(30) |
Nov
(144) |
Dec
(23) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2006 |
Jan
(41) |
Feb
(29) |
Mar
(31) |
Apr
(39) |
May
(193) |
Jun
(45) |
Jul
(19) |
Aug
(3) |
Sep
(23) |
Oct
(83) |
Nov
(92) |
Dec
(123) |
| 2007 |
Jan
(90) |
Feb
(267) |
Mar
(120) |
Apr
(51) |
May
(40) |
Jun
(121) |
Jul
(109) |
Aug
(173) |
Sep
(77) |
Oct
(52) |
Nov
(121) |
Dec
(62) |
| 2008 |
Jan
(76) |
Feb
(53) |
Mar
(98) |
Apr
(87) |
May
(26) |
Jun
(27) |
Jul
(23) |
Aug
(136) |
Sep
(79) |
Oct
(68) |
Nov
(29) |
Dec
(14) |
| 2009 |
Jan
(7) |
Feb
(2) |
Mar
(11) |
Apr
(75) |
May
(1) |
Jun
(95) |
Jul
(19) |
Aug
(4) |
Sep
(8) |
Oct
(93) |
Nov
(43) |
Dec
(21) |
| 2010 |
Jan
(20) |
Feb
(23) |
Mar
(18) |
Apr
(6) |
May
(20) |
Jun
(23) |
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2011 |
Jan
(2) |
Feb
(6) |
Mar
(15) |
Apr
(5) |
May
(9) |
Jun
(14) |
Jul
(9) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2012 |
Jan
|
Feb
(3) |
Mar
|
Apr
|
May
(2) |
Jun
(17) |
Jul
(37) |
Aug
|
Sep
(1) |
Oct
(6) |
Nov
|
Dec
|
| 2013 |
Jan
|
Feb
|
Mar
(5) |
Apr
(2) |
May
(7) |
Jun
(11) |
Jul
(8) |
Aug
|
Sep
(1) |
Oct
(2) |
Nov
|
Dec
|
| 2014 |
Jan
|
Feb
(2) |
Mar
(1) |
Apr
|
May
(1) |
Jun
(1) |
Jul
(7) |
Aug
(2) |
Sep
|
Oct
(5) |
Nov
(2) |
Dec
(4) |
| 2015 |
Jan
|
Feb
(2) |
Mar
(2) |
Apr
|
May
|
Jun
(9) |
Jul
(1) |
Aug
|
Sep
|
Oct
(4) |
Nov
(1) |
Dec
|
| 2016 |
Jan
(2) |
Feb
(1) |
Mar
(1) |
Apr
(1) |
May
(1) |
Jun
(2) |
Jul
(1) |
Aug
|
Sep
(5) |
Oct
|
Nov
|
Dec
|
| 2017 |
Jan
(1) |
Feb
(3) |
Mar
(3) |
Apr
(7) |
May
(2) |
Jun
(2) |
Jul
(5) |
Aug
(1) |
Sep
(2) |
Oct
(17) |
Nov
(4) |
Dec
(7) |
| 2018 |
Jan
(5) |
Feb
(14) |
Mar
(2) |
Apr
(5) |
May
(2) |
Jun
(5) |
Jul
|
Aug
(2) |
Sep
|
Oct
(3) |
Nov
(5) |
Dec
|
| 2019 |
Jan
(4) |
Feb
(2) |
Mar
(3) |
Apr
(1) |
May
(8) |
Jun
(14) |
Jul
(2) |
Aug
|
Sep
(2) |
Oct
(2) |
Nov
(15) |
Dec
(2) |
| 2020 |
Jan
(10) |
Feb
(3) |
Mar
(1) |
Apr
|
May
(9) |
Jun
(4) |
Jul
(16) |
Aug
(10) |
Sep
(4) |
Oct
(3) |
Nov
|
Dec
|
| 2021 |
Jan
(11) |
Feb
(2) |
Mar
(2) |
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
(5) |
Sep
|
Oct
(6) |
Nov
(4) |
Dec
(4) |
| 2022 |
Jan
(4) |
Feb
(2) |
Mar
(2) |
Apr
|
May
(6) |
Jun
(3) |
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2023 |
Jan
|
Feb
|
Mar
|
Apr
(2) |
May
(5) |
Jun
(1) |
Jul
(4) |
Aug
(1) |
Sep
|
Oct
(1) |
Nov
(13) |
Dec
|
| 2024 |
Jan
(1) |
Feb
|
Mar
(5) |
Apr
|
May
(10) |
Jun
|
Jul
|
Aug
(3) |
Sep
|
Oct
|
Nov
(1) |
Dec
(14) |
| 2025 |
Jan
(3) |
Feb
|
Mar
(1) |
Apr
|
May
(2) |
Jun
(3) |
Jul
|
Aug
|
Sep
(2) |
Oct
(3) |
Nov
|
Dec
|
|
From: Stephen W. <sw...@ml...> - 2006-05-09 19:49:06
|
Quelled gcc warning "right shift count >= width of type".
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/gc/int-inf.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/gc/int-inf.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/gc/int-inf.c 2006-05-10 02:29:29 UTC (rev 4512)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/gc/int-inf.c 2006-05-10 02:49:06 UTC (rev 4513)
@@ -65,7 +65,13 @@
}
for (unsigned int i = 0; i < LIMBS_PER_OBJPTR; i++) {
space[i] = (mp_limb_t)arg;
- arg = arg >> (CHAR_BIT * sizeof(mp_limb_t));
+ // The conditional below is to quell a gcc warning:
+ // right shift count >= width of type
+ // When 1 == LIMBS_PEROBJPTR, the for loop will not continue, so the
+ // shift doesn't matter.
+ arg = arg >> (1 == LIMBS_PER_OBJPTR ?
+ 0 :
+ CHAR_BIT * sizeof(mp_limb_t));
}
}
} else {
|
|
From: Matthew F. <fl...@ml...> - 2006-05-09 19:29:30
|
Moved conditional define of O_DYSNC and O_RSYNC to platform-independent code ---------------------------------------------------------------------- U mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.h ---------------------------------------------------------------------- Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.h =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.h 2006-05-10 02:04:28 UTC (rev 4511) +++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.h 2006-05-10 02:29:29 UTC (rev 4512) @@ -33,14 +33,6 @@ #define MLton_Platform_OS_host "darwin" -// MacOS doesn't support these... yet. -#ifndef O_RSYNC -#define O_RSYNC O_SYNC -#endif -#ifndef O_DSYNC -#define O_DSYNC O_SYNC -#endif - // MacOS only defines this if POSIX_C_SOURCE is defined. // However, defining that breaks half the osx system headers. // They couldn't possibly change the number at this point anyways. |
|
From: Matthew F. <fl...@ml...> - 2006-05-09 19:04:28
|
Finished first round of FreeBSD port. (Much overlap with the Darwin
port.) The runtime now compiles.
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/freebsd.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/freebsd.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/freebsd.c 2006-05-10 02:02:27 UTC (rev 4510)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/freebsd.c 2006-05-10 02:04:28 UTC (rev 4511)
@@ -23,11 +23,12 @@
sa->sa_sigaction = (void (*)(int, siginfo_t*, void*))catcher;
}
-W32 GC_totalRam (GC_state s) {
- int mem, len;
+size_t GC_totalRam (void) {
+ unsigned int mem;
+ size_t len;
len = sizeof (int);
if (-1 == sysctlbyname ("hw.physmem", &mem, &len, NULL, 0))
diee ("sysctl failed");
- return mem;
+ return (size_t)mem;
}
|
|
From: Matthew F. <fl...@ml...> - 2006-05-09 19:02:29
|
Defined all of the SIG and tty constants with #ifndef in the platform-independent code, so that each platform doesn't have to define the missing ones. Also defined O_BINARY, O_DSYNC, O_RSYNC, and O_TEXT with #ifndef in the platform-independent code. ---------------------------------------------------------------------- U mlton/branches/on-20050822-x86_64-branch/runtime/Posix/FileSys/FileSys-consts.c U mlton/branches/on-20050822-x86_64-branch/runtime/Posix/Signal-consts.c U mlton/branches/on-20050822-x86_64-branch/runtime/Posix/TTY-consts.c ---------------------------------------------------------------------- Modified: mlton/branches/on-20050822-x86_64-branch/runtime/Posix/FileSys/FileSys-consts.c =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/Posix/FileSys/FileSys-consts.c 2006-05-10 01:28:35 UTC (rev 4509) +++ mlton/branches/on-20050822-x86_64-branch/runtime/Posix/FileSys/FileSys-consts.c 2006-05-10 02:02:27 UTC (rev 4510) @@ -9,23 +9,27 @@ const C_Int_t Posix_FileSys_O_RDWR = O_RDWR; const C_Int_t Posix_FileSys_O_WRONLY = O_WRONLY; +const C_Int_t Posix_FileSys_O_APPEND = O_APPEND; #ifndef O_BINARY #define O_BINARY 0 #endif - -#ifndef O_TEXT -#define O_TEXT 0 -#endif - -const C_Int_t Posix_FileSys_O_APPEND = O_APPEND; const C_Int_t Posix_FileSys_O_BINARY = O_BINARY; const C_Int_t Posix_FileSys_O_CREAT = O_CREAT; +#ifndef O_DSYNC +#define O_DSYNC 0 +#endif const C_Int_t Posix_FileSys_O_DSYNC = O_DSYNC; const C_Int_t Posix_FileSys_O_EXCL = O_EXCL; const C_Int_t Posix_FileSys_O_NOCTTY = O_NOCTTY; const C_Int_t Posix_FileSys_O_NONBLOCK = O_NONBLOCK; +#ifndef O_RSYNC +#define O_RSYNC 0 +#endif const C_Int_t Posix_FileSys_O_RSYNC = O_RSYNC; const C_Int_t Posix_FileSys_O_SYNC = O_SYNC; +#ifndef O_TEXT +#define O_TEXT 0 +#endif const C_Int_t Posix_FileSys_O_TEXT = O_TEXT; const C_Int_t Posix_FileSys_O_TRUNC = O_TRUNC; Modified: mlton/branches/on-20050822-x86_64-branch/runtime/Posix/Signal-consts.c =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/Posix/Signal-consts.c 2006-05-10 01:28:35 UTC (rev 4509) +++ mlton/branches/on-20050822-x86_64-branch/runtime/Posix/Signal-consts.c 2006-05-10 02:02:27 UTC (rev 4510) @@ -12,31 +12,115 @@ const C_Int_t Posix_Signal_SIG_SETMASK = SIG_SETMASK; const C_Int_t Posix_Signal_SIG_UNBLOCK = SIG_UNBLOCK; +#ifndef SIGABRT +#define SIGABRT -1 +#endif const C_Signal_t Posix_Signal_SIGABRT = SIGABRT; +#ifndef SIGALRM +#define SIGALRM -1 +#endif const C_Signal_t Posix_Signal_SIGALRM = SIGALRM; +#ifndef SIGBUS +#define SIGBUS -1 +#endif const C_Signal_t Posix_Signal_SIGBUS = SIGBUS; +#ifndef SIGCHLD +#define SIGCHLD -1 +#endif const C_Signal_t Posix_Signal_SIGCHLD = SIGCHLD; +#ifndef SIGCONT +#define SIGCONT -1 +#endif const C_Signal_t Posix_Signal_SIGCONT = SIGCONT; +#ifndef SIGFPE +#define SIGFPE -1 +#endif const C_Signal_t Posix_Signal_SIGFPE = SIGFPE; +#ifndef SIGHUP +#define SIGHUP -1 +#endif const C_Signal_t Posix_Signal_SIGHUP = SIGHUP; +#ifndef SIGILL +#define SIGILL -1 +#endif const C_Signal_t Posix_Signal_SIGILL = SIGILL; +#ifndef SIGINT +#define SIGINT -1 +#endif const C_Signal_t Posix_Signal_SIGINT = SIGINT; +#ifndef SIGKILL +#define SIGKILL -1 +#endif const C_Signal_t Posix_Signal_SIGKILL = SIGKILL; +#ifndef SIGPIPE +#define SIGPIPE -1 +#endif const C_Signal_t Posix_Signal_SIGPIPE = SIGPIPE; +#ifndef SIGQUIT +#define SIGQUIT -1 +#endif const C_Signal_t Posix_Signal_SIGQUIT = SIGQUIT; +#ifndef SIGSEGV +#define SIGSEGV -1 +#endif const C_Signal_t Posix_Signal_SIGSEGV = SIGSEGV; +#ifndef SIGSTOP +#define SIGSTOP -1 +#endif const C_Signal_t Posix_Signal_SIGSTOP = SIGSTOP; +#ifndef SIGTERM +#define SIGTERM -1 +#endif const C_Signal_t Posix_Signal_SIGTERM = SIGTERM; +#ifndef SIGTSTP +#define SIGTSTP -1 +#endif const C_Signal_t Posix_Signal_SIGTSTP = SIGTSTP; +#ifndef SIGTTIN +#define SIGTTIN -1 +#endif const C_Signal_t Posix_Signal_SIGTTIN = SIGTTIN; +#ifndef SIGTTOU +#define SIGTTOU -1 +#endif const C_Signal_t Posix_Signal_SIGTTOU = SIGTTOU; +#ifndef SIGUSR1 +#define SIGUSR1 -1 +#endif const C_Signal_t Posix_Signal_SIGUSR1 = SIGUSR1; +#ifndef SIGUSR2 +#define SIGUSR2 -1 +#endif const C_Signal_t Posix_Signal_SIGUSR2 = SIGUSR2; +#ifndef SIGPOLL +#define SIGPOLL -1 +#endif const C_Signal_t Posix_Signal_SIGPOLL = SIGPOLL; +#ifndef SIGPROF +#define SIGPROF -1 +#endif const C_Signal_t Posix_Signal_SIGPROF = SIGPROF; +#ifndef SIGSYS +#define SIGSYS -1 +#endif const C_Signal_t Posix_Signal_SIGSYS = SIGSYS; +#ifndef SIGTRAP +#define SIGTRAP -1 +#endif const C_Signal_t Posix_Signal_SIGTRAP = SIGTRAP; +#ifndef SIGURG +#define SIGURG -1 +#endif const C_Signal_t Posix_Signal_SIGURG = SIGURG; +#ifndef SIGVTALRM +#define SIGVTALRM -1 +#endif const C_Signal_t Posix_Signal_SIGVTALRM = SIGVTALRM; +#ifndef SIGXCPU +#define SIGXCPU -1 +#endif const C_Signal_t Posix_Signal_SIGXCPU = SIGXCPU; +#ifndef SIGXFSZ +#define SIGXFSZ -1 +#endif const C_Signal_t Posix_Signal_SIGXFSZ = SIGXFSZ; Modified: mlton/branches/on-20050822-x86_64-branch/runtime/Posix/TTY-consts.c =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/Posix/TTY-consts.c 2006-05-10 01:28:35 UTC (rev 4509) +++ mlton/branches/on-20050822-x86_64-branch/runtime/Posix/TTY-consts.c 2006-05-10 02:02:27 UTC (rev 4510) @@ -2,108 +2,399 @@ const C_Int_t Posix_TTY_V_NCCS = NCCS; +#ifndef VEOF +#define VEOF -1 +#endif const C_Int_t Posix_TTY_V_VEOF = VEOF; +#ifndef VEOL +#define VEOL -1 +#endif const C_Int_t Posix_TTY_V_VEOL = VEOL; +#ifndef VERASE +#define VERASE -1 +#endif const C_Int_t Posix_TTY_V_VERASE = VERASE; +#ifndef VINTR +#define VINTR -1 +#endif const C_Int_t Posix_TTY_V_VINTR = VINTR; +#ifndef VKILL +#define VKILL -1 +#endif const C_Int_t Posix_TTY_V_VKILL = VKILL; +#ifndef VMIN +#define VMIN -1 +#endif const C_Int_t Posix_TTY_V_VMIN = VMIN; +#ifndef VQUIT +#define VQUIT -1 +#endif const C_Int_t Posix_TTY_V_VQUIT = VQUIT; +#ifndef VSTART +#define VSTART -1 +#endif const C_Int_t Posix_TTY_V_VSTART = VSTART; +#ifndef VSTOP +#define VSTOP -1 +#endif const C_Int_t Posix_TTY_V_VSTOP = VSTOP; +#ifndef VSUSP +#define VSUSP -1 +#endif const C_Int_t Posix_TTY_V_VSUSP = VSUSP; +#ifndef VTIME +#define VTIME -1 +#endif const C_Int_t Posix_TTY_V_VTIME = VTIME; +#ifndef BRKINT +#define BRKINT -1 +#endif const C_TCFlag_t Posix_TTY_I_BRKINT = BRKINT; +#ifndef ICRNL +#define ICRNL -1 +#endif const C_TCFlag_t Posix_TTY_I_ICRNL = ICRNL; +#ifndef IGNBRK +#define IGNBRK -1 +#endif const C_TCFlag_t Posix_TTY_I_IGNBRK = IGNBRK; +#ifndef IGNCR +#define IGNCR -1 +#endif const C_TCFlag_t Posix_TTY_I_IGNCR = IGNCR; +#ifndef IGNPAR +#define IGNPAR -1 +#endif const C_TCFlag_t Posix_TTY_I_IGNPAR = IGNPAR; +#ifndef INLCR +#define INLCR -1 +#endif const C_TCFlag_t Posix_TTY_I_INLCR = INLCR; +#ifndef INPCK +#define INPCK -1 +#endif const C_TCFlag_t Posix_TTY_I_INPCK = INPCK; +#ifndef ISTRIP +#define ISTRIP -1 +#endif const C_TCFlag_t Posix_TTY_I_ISTRIP = ISTRIP; +#ifndef IXANY +#define IXANY -1 +#endif const C_TCFlag_t Posix_TTY_I_IXANY = IXANY; +#ifndef IXOFF +#define IXOFF -1 +#endif const C_TCFlag_t Posix_TTY_I_IXOFF = IXOFF; +#ifndef IXON +#define IXON -1 +#endif const C_TCFlag_t Posix_TTY_I_IXON = IXON; +#ifndef PARMRK +#define PARMRK -1 +#endif const C_TCFlag_t Posix_TTY_I_PARMRK = PARMRK; +#ifndef OPOST +#define OPOST -1 +#endif const C_TCFlag_t Posix_TTY_O_OPOST = OPOST; +#ifndef ONLCR +#define ONLCR -1 +#endif const C_TCFlag_t Posix_TTY_O_ONLCR = ONLCR; +#ifndef OCRNL +#define OCRNL -1 +#endif const C_TCFlag_t Posix_TTY_O_OCRNL = OCRNL; +#ifndef ONOCR +#define ONOCR -1 +#endif const C_TCFlag_t Posix_TTY_O_ONOCR = ONOCR; +#ifndef ONLRET +#define ONLRET -1 +#endif const C_TCFlag_t Posix_TTY_O_ONLRET = ONLRET; +#ifndef OFILL +#define OFILL -1 +#endif const C_TCFlag_t Posix_TTY_O_OFILL = OFILL; +#ifndef NLDLY +#define NLDLY -1 +#endif const C_TCFlag_t Posix_TTY_O_NLDLY = NLDLY; +#ifndef NL0 +#define NL0 -1 +#endif const C_TCFlag_t Posix_TTY_O_NL0 = NL0; +#ifndef NL1 +#define NL1 -1 +#endif const C_TCFlag_t Posix_TTY_O_NL1 = NL1; +#ifndef CRDLY +#define CRDLY -1 +#endif const C_TCFlag_t Posix_TTY_O_CRDLY = CRDLY; +#ifndef CR0 +#define CR0 -1 +#endif const C_TCFlag_t Posix_TTY_O_CR0 = CR0; +#ifndef CR1 +#define CR1 -1 +#endif const C_TCFlag_t Posix_TTY_O_CR1 = CR1; +#ifndef CR2 +#define CR2 -1 +#endif const C_TCFlag_t Posix_TTY_O_CR2 = CR2; +#ifndef CR3 +#define CR3 -1 +#endif const C_TCFlag_t Posix_TTY_O_CR3 = CR3; +#ifndef TABDLY +#define TABDLY -1 +#endif const C_TCFlag_t Posix_TTY_O_TABDLY = TABDLY; +#ifndef TAB0 +#define TAB0 -1 +#endif const C_TCFlag_t Posix_TTY_O_TAB0 = TAB0; +#ifndef TAB1 +#define TAB1 -1 +#endif const C_TCFlag_t Posix_TTY_O_TAB1 = TAB1; +#ifndef TAB2 +#define TAB2 -1 +#endif const C_TCFlag_t Posix_TTY_O_TAB2 = TAB2; +#ifndef TAB3 +#define TAB3 -1 +#endif const C_TCFlag_t Posix_TTY_O_TAB3 = TAB3; +#ifndef BSDLY +#define BSDLY -1 +#endif const C_TCFlag_t Posix_TTY_O_BSDLY = BSDLY; +#ifndef BS0 +#define BS0 -1 +#endif const C_TCFlag_t Posix_TTY_O_BS0 = BS0; +#ifndef BS1 +#define BS1 -1 +#endif const C_TCFlag_t Posix_TTY_O_BS1 = BS1; +#ifndef VTDLY +#define VTDLY -1 +#endif const C_TCFlag_t Posix_TTY_O_VTDLY = VTDLY; +#ifndef VT0 +#define VT0 -1 +#endif const C_TCFlag_t Posix_TTY_O_VT0 = VT0; +#ifndef VT1 +#define VT1 -1 +#endif const C_TCFlag_t Posix_TTY_O_VT1 = VT1; +#ifndef FFDLY +#define FFDLY -1 +#endif const C_TCFlag_t Posix_TTY_O_FFDLY = FFDLY; +#ifndef FF0 +#define FF0 -1 +#endif const C_TCFlag_t Posix_TTY_O_FF0 = FF0; +#ifndef FF1 +#define FF1 -1 +#endif const C_TCFlag_t Posix_TTY_O_FF1 = FF1; +#ifndef CSIZE +#define CSIZE -1 +#endif const C_TCFlag_t Posix_TTY_C_CSIZE = CSIZE; +#ifndef CS5 +#define CS5 -1 +#endif const C_TCFlag_t Posix_TTY_C_CS5 = CS5; +#ifndef CS6 +#define CS6 -1 +#endif const C_TCFlag_t Posix_TTY_C_CS6 = CS6; +#ifndef CS7 +#define CS7 -1 +#endif const C_TCFlag_t Posix_TTY_C_CS7 = CS7; +#ifndef CS8 +#define CS8 -1 +#endif const C_TCFlag_t Posix_TTY_C_CS8 = CS8; +#ifndef CSTOPB +#define CSTOPB -1 +#endif const C_TCFlag_t Posix_TTY_C_CSTOPB = CSTOPB; +#ifndef CREAD +#define CREAD -1 +#endif const C_TCFlag_t Posix_TTY_C_CREAD = CREAD; +#ifndef PARENB +#define PARENB -1 +#endif const C_TCFlag_t Posix_TTY_C_PARENB = PARENB; +#ifndef PARODD +#define PARODD -1 +#endif const C_TCFlag_t Posix_TTY_C_PARODD = PARODD; +#ifndef HUPCL +#define HUPCL -1 +#endif const C_TCFlag_t Posix_TTY_C_HUPCL = HUPCL; +#ifndef CLOCAL +#define CLOCAL -1 +#endif const C_TCFlag_t Posix_TTY_C_CLOCAL = CLOCAL; +#ifndef ECHO +#define ECHO -1 +#endif const C_TCFlag_t Posix_TTY_L_ECHO = ECHO; +#ifndef ECHOE +#define ECHOE -1 +#endif const C_TCFlag_t Posix_TTY_L_ECHOE = ECHOE; +#ifndef ECHOK +#define ECHOK -1 +#endif const C_TCFlag_t Posix_TTY_L_ECHOK = ECHOK; +#ifndef ECHONL +#define ECHONL -1 +#endif const C_TCFlag_t Posix_TTY_L_ECHONL = ECHONL; +#ifndef ICANON +#define ICANON -1 +#endif const C_TCFlag_t Posix_TTY_L_ICANON = ICANON; +#ifndef IEXTEN +#define IEXTEN -1 +#endif const C_TCFlag_t Posix_TTY_L_IEXTEN = IEXTEN; +#ifndef ISIG +#define ISIG -1 +#endif const C_TCFlag_t Posix_TTY_L_ISIG = ISIG; +#ifndef NOFLSH +#define NOFLSH -1 +#endif const C_TCFlag_t Posix_TTY_L_NOFLSH = NOFLSH; +#ifndef TOSTOP +#define TOSTOP -1 +#endif const C_TCFlag_t Posix_TTY_L_TOSTOP = TOSTOP; +#ifndef B0 +#define B0 -1 +#endif const C_Speed_t Posix_TTY_B0 = B0; +#ifndef B50 +#define B50 -1 +#endif const C_Speed_t Posix_TTY_B50 = B50; +#ifndef B75 +#define B75 -1 +#endif const C_Speed_t Posix_TTY_B75 = B75; +#ifndef B110 +#define B110 -1 +#endif const C_Speed_t Posix_TTY_B110 = B110; +#ifndef B134 +#define B134 -1 +#endif const C_Speed_t Posix_TTY_B134 = B134; +#ifndef B150 +#define B150 -1 +#endif const C_Speed_t Posix_TTY_B150 = B150; +#ifndef B200 +#define B200 -1 +#endif const C_Speed_t Posix_TTY_B200 = B200; +#ifndef B300 +#define B300 -1 +#endif const C_Speed_t Posix_TTY_B300 = B300; +#ifndef B600 +#define B600 -1 +#endif const C_Speed_t Posix_TTY_B600 = B600; +#ifndef B1200 +#define B1200 -1 +#endif const C_Speed_t Posix_TTY_B1200 = B1200; +#ifndef B1800 +#define B1800 -1 +#endif const C_Speed_t Posix_TTY_B1800 = B1800; +#ifndef B2400 +#define B2400 -1 +#endif const C_Speed_t Posix_TTY_B2400 = B2400; +#ifndef B4800 +#define B4800 -1 +#endif const C_Speed_t Posix_TTY_B4800 = B4800; +#ifndef B9600 +#define B9600 -1 +#endif const C_Speed_t Posix_TTY_B9600 = B9600; +#ifndef B19200 +#define B19200 -1 +#endif const C_Speed_t Posix_TTY_B19200 = B19200; +#ifndef B38400 +#define B38400 -1 +#endif const C_Speed_t Posix_TTY_B38400 = B38400; +#ifndef TCSADRAIN +#define TCSADRAIN -1 +#endif const C_Int_t Posix_TTY_TC_TCSADRAIN = TCSADRAIN; +#ifndef TCSAFLUSH +#define TCSAFLUSH -1 +#endif const C_Int_t Posix_TTY_TC_TCSAFLUSH = TCSAFLUSH; +#ifndef TCSANOW +#define TCSANOW -1 +#endif const C_Int_t Posix_TTY_TC_TCSANOW = TCSANOW; +#ifndef TCIOFF +#define TCIOFF -1 +#endif const C_Int_t Posix_TTY_TC_TCIOFF = TCIOFF; +#ifndef TCION +#define TCION -1 +#endif const C_Int_t Posix_TTY_TC_TCION = TCION; +#ifndef TCOOFF +#define TCOOFF -1 +#endif const C_Int_t Posix_TTY_TC_TCOOFF = TCOOFF; +#ifndef TCOON +#define TCOON -1 +#endif const C_Int_t Posix_TTY_TC_TCOON = TCOON; +#ifndef TCIFLUSH +#define TCIFLUSH -1 +#endif const C_Int_t Posix_TTY_TC_TCIFLUSH = TCIFLUSH; +#ifndef TCIOFLUSH +#define TCIOFLUSH -1 +#endif const C_Int_t Posix_TTY_TC_TCIOFLUSH = TCIOFLUSH; +#ifndef TCOFLUSH +#define TCOFLUSH -1 +#endif const C_Int_t Posix_TTY_TC_TCOFLUSH = TCOFLUSH; |
|
From: Matthew F. <fl...@ml...> - 2006-05-09 18:28:36
|
Wesley's patches for powerpc-darwin
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/Posix/ProcEnv/sysconf-consts.c
U mlton/branches/on-20050822-x86_64-branch/runtime/gc/objptr.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.h
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/getText.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform.h
U mlton/branches/on-20050822-x86_64-branch/runtime/util/Makefile
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/Posix/ProcEnv/sysconf-consts.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/Posix/ProcEnv/sysconf-consts.c 2006-05-10 01:19:57 UTC (rev 4508)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/Posix/ProcEnv/sysconf-consts.c 2006-05-10 01:28:35 UTC (rev 4509)
@@ -489,7 +489,7 @@
#define _SC_XOPEN_SHM -1
#endif
const C_Int_t Posix_ProcEnv_SC_XOPEN_SHM = _SC_XOPEN_SHM;
-#ifndef __SC_XOPEN_STREAMS
+#ifndef _SC_XOPEN_STREAMS
#define _SC_XOPEN_STREAMS -1
#endif
#ifndef _SC_XOPEN_STREAMS
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/gc/objptr.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/gc/objptr.c 2006-05-10 01:19:57 UTC (rev 4508)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/gc/objptr.c 2006-05-10 01:28:35 UTC (rev 4509)
@@ -23,7 +23,7 @@
uintptr_t P_;
pointer P;
- if GC_MODEL_USEBASE {
+ if (GC_MODEL_USEBASE) {
B_ = (uintptr_t)B;
} else {
B_ = 0;
@@ -44,7 +44,7 @@
uintptr_t O_;
objptr O;
- if GC_MODEL_USEBASE {
+ if (GC_MODEL_USEBASE) {
B_ = (uintptr_t)B;
} else {
B_ = 0;
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.c 2006-05-10 01:19:57 UTC (rev 4508)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.c 2006-05-10 01:28:35 UTC (rev 4509)
@@ -8,21 +8,20 @@
#include "mmap-protect.c"
#include "use-mmap.c"
-void *getTextEnd () {
- return (void*)(get_etext ());
+const void *GC_getTextEnd (void) {
+ return (const void*)(long)(get_etext ());
}
-void *getTextStart () {
- unsigned long address;
- void *module;
- struct mach_header *mh;
+const void *GC_getTextStart (void) {
+ void *address;
+ const struct mach_header *mh;
- _dyld_lookup_and_bind ("_main", &address, &module);
+ _dyld_lookup_and_bind ("_main", &address, 0);
mh = _dyld_get_image_header_containing_address (address);
return mh;
}
-void GC_displayMem () {
+void GC_displayMem (void) {
/* FIXME: this won't actually work. */
static char buffer[256];
@@ -41,7 +40,7 @@
sa->sa_sigaction = (void (*)(int, siginfo_t*, void*))catcher;
}
-W32 GC_totalRam (GC_state s) {
+size_t GC_totalRam (void) {
int mem;
size_t len;
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.h
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.h 2006-05-10 01:19:57 UTC (rev 4508)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.h 2006-05-10 01:28:35 UTC (rev 4509)
@@ -32,3 +32,18 @@
#define HAS_TIME_PROFILING TRUE
#define MLton_Platform_OS_host "darwin"
+
+// MacOS doesn't support these... yet.
+#ifndef O_RSYNC
+#define O_RSYNC O_SYNC
+#endif
+#ifndef O_DSYNC
+#define O_DSYNC O_SYNC
+#endif
+
+// MacOS only defines this if POSIX_C_SOURCE is defined.
+// However, defining that breaks half the osx system headers.
+// They couldn't possibly change the number at this point anyways.
+#ifndef SIGPOLL
+#define SIGPOLL 7
+#endif
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/getText.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/getText.c 2006-05-10 01:19:57 UTC (rev 4508)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/getText.c 2006-05-10 01:28:35 UTC (rev 4509)
@@ -2,9 +2,9 @@
extern char _start;
extern char etext;
-void *GC_getTextStart (void) {
+const void *GC_getTextStart (void) {
return &_start;
}
-void *GC_getTextEnd (void) {
+const void *GC_getTextEnd (void) {
return &etext;
}
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform.h
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform.h 2006-05-10 01:19:57 UTC (rev 4508)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform.h 2006-05-10 01:28:35 UTC (rev 4509)
@@ -156,8 +156,8 @@
/* Text Segment */
/* ------------------------------------------------- */
-void *GC_getTextEnd (void);
-void *GC_getTextStart (void);
+const void *GC_getTextEnd (void);
+const void *GC_getTextStart (void);
/* ------------------------------------------------- */
/* SigProf Handler */
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/util/Makefile
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/util/Makefile 2006-05-10 01:19:57 UTC (rev 4508)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/util/Makefile 2006-05-10 01:28:35 UTC (rev 4509)
@@ -71,10 +71,10 @@
DEBUGFLAGS = $(CFLAGS) -Wunused -gstabs+ -g2
CFILES = \
- $(shell find -type f | grep '\.c$$')
+ $(shell find . -type f | grep '\.c$$')
HFILES = \
- $(shell find -type f | grep '\.h$$')
+ $(shell find . -type f | grep '\.h$$')
all: libgc.o libgc-gdb.o
|
|
From: Matthew F. <fl...@ml...> - 2006-05-09 18:19:57
|
Filter missing E constants in ML
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/basis-library/posix/error.sml
U mlton/branches/on-20050822-x86_64-branch/runtime/Posix/Error-consts.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/basis-library/posix/error.sml
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/basis-library/posix/error.sml 2006-05-10 01:01:40 UTC (rev 4507)
+++ mlton/branches/on-20050822-x86_64-branch/basis-library/posix/error.sml 2006-05-10 01:19:57 UTC (rev 4508)
@@ -93,89 +93,95 @@
val wouldblock = EWOULDBLOCK
val xdev = EXDEV
- val errorNames =
- [
- (acces,"acces"),
- (addrinuse,"addrinuse"),
- (addrnotavail,"addrnotavail"),
- (afnosupport,"afnosupport"),
- (again,"again"),
- (already,"already"),
- (badf,"badf"),
- (badmsg,"badmsg"),
- (busy,"busy"),
- (canceled,"canceled"),
- (child,"child"),
- (connaborted,"connaborted"),
- (connrefused,"connrefused"),
- (connreset,"connreset"),
- (deadlk,"deadlk"),
- (destaddrreq,"destaddrreq"),
- (dom,"dom"),
- (dquot,"dquot"),
- (exist,"exist"),
- (fault,"fault"),
- (fbig,"fbig"),
- (hostunreach,"hostunreach"),
- (idrm,"idrm"),
- (ilseq,"ilseq"),
- (inprogress,"inprogress"),
- (intr,"intr"),
- (inval,"inval"),
- (io,"io"),
- (isconn,"isconn"),
- (isdir,"isdir"),
- (loop,"loop"),
- (mfile,"mfile"),
- (mlink,"mlink"),
- (msgsize,"msgsize"),
- (multihop,"multihop"),
- (nametoolong,"nametoolong"),
- (netdown,"netdown"),
- (netreset,"netreset"),
- (netunreach,"netunreach"),
- (nfile,"nfile"),
- (nobufs,"nobufs"),
- (nodata,"nodata"),
- (nodev,"nodev"),
- (noent,"noent"),
- (noexec,"noexec"),
- (nolck,"nolck"),
- (nolink,"nolink"),
- (nomem,"nomem"),
- (nomsg,"nomsg"),
- (noprotoopt,"noprotoopt"),
- (nospc,"nospc"),
- (nosr,"nosr"),
- (nostr,"nostr"),
- (nosys,"nosys"),
- (notconn,"notconn"),
- (notdir,"notdir"),
- (notempty,"notempty"),
- (notsock,"notsock"),
- (notsup,"notsup"),
- (notty,"notty"),
- (nxio,"nxio"),
- (opnotsupp,"opnotsupp"),
- (overflow,"overflow"),
- (perm,"perm"),
- (pipe,"pipe"),
- (proto,"proto"),
- (protonosupport,"protonosupport"),
- (prototype,"prototype"),
- (range,"range"),
- (rofs,"rofs"),
- (spipe,"spipe"),
- (srch,"srch"),
- (stale,"stale"),
- (time,"time"),
- (timedout,"timedout"),
- (toobig,"toobig"),
- (txtbsy,"txtbsy"),
- (wouldblock,"wouldblock"),
- (xdev,"xdev")
- ]
-
+ local
+ infixr 5 ::?
+ fun (n,s) ::? l =
+ if n = C_Int.fromInt ~1
+ then l
+ else (n,s) :: l
+ in
+ val errorNames =
+ (acces,"acces") ::?
+ (addrinuse,"addrinuse") ::?
+ (addrnotavail,"addrnotavail") ::?
+ (afnosupport,"afnosupport") ::?
+ (again,"again") ::?
+ (already,"already") ::?
+ (badf,"badf") ::?
+ (badmsg,"badmsg") ::?
+ (busy,"busy") ::?
+ (canceled,"canceled") ::?
+ (child,"child") ::?
+ (connaborted,"connaborted") ::?
+ (connrefused,"connrefused") ::?
+ (connreset,"connreset") ::?
+ (deadlk,"deadlk") ::?
+ (destaddrreq,"destaddrreq") ::?
+ (dom,"dom") ::?
+ (dquot,"dquot") ::?
+ (exist,"exist") ::?
+ (fault,"fault") ::?
+ (fbig,"fbig") ::?
+ (hostunreach,"hostunreach") ::?
+ (idrm,"idrm") ::?
+ (ilseq,"ilseq") ::?
+ (inprogress,"inprogress") ::?
+ (intr,"intr") ::?
+ (inval,"inval") ::?
+ (io,"io") ::?
+ (isconn,"isconn") ::?
+ (isdir,"isdir") ::?
+ (loop,"loop") ::?
+ (mfile,"mfile") ::?
+ (mlink,"mlink") ::?
+ (msgsize,"msgsize") ::?
+ (multihop,"multihop") ::?
+ (nametoolong,"nametoolong") ::?
+ (netdown,"netdown") ::?
+ (netreset,"netreset") ::?
+ (netunreach,"netunreach") ::?
+ (nfile,"nfile") ::?
+ (nobufs,"nobufs") ::?
+ (nodata,"nodata") ::?
+ (nodev,"nodev") ::?
+ (noent,"noent") ::?
+ (noexec,"noexec") ::?
+ (nolck,"nolck") ::?
+ (nolink,"nolink") ::?
+ (nomem,"nomem") ::?
+ (nomsg,"nomsg") ::?
+ (noprotoopt,"noprotoopt") ::?
+ (nospc,"nospc") ::?
+ (nosr,"nosr") ::?
+ (nostr,"nostr") ::?
+ (nosys,"nosys") ::?
+ (notconn,"notconn") ::?
+ (notdir,"notdir") ::?
+ (notempty,"notempty") ::?
+ (notsock,"notsock") ::?
+ (notsup,"notsup") ::?
+ (notty,"notty") ::?
+ (nxio,"nxio") ::?
+ (opnotsupp,"opnotsupp") ::?
+ (overflow,"overflow") ::?
+ (perm,"perm") ::?
+ (pipe,"pipe") ::?
+ (proto,"proto") ::?
+ (protonosupport,"protonosupport") ::?
+ (prototype,"prototype") ::?
+ (range,"range") ::?
+ (rofs,"rofs") ::?
+ (spipe,"spipe") ::?
+ (srch,"srch") ::?
+ (stale,"stale") ::?
+ (time,"time") ::?
+ (timedout,"timedout") ::?
+ (toobig,"toobig") ::?
+ (txtbsy,"txtbsy") ::?
+ (wouldblock,"wouldblock") ::?
+ (xdev,"xdev") ::?
+ []
+ end
exception SysErr of string * syserror option
val toWord = SysWord.fromLargeInt o C_Int.toLarge
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/Posix/Error-consts.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/Posix/Error-consts.c 2006-05-10 01:01:40 UTC (rev 4507)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/Posix/Error-consts.c 2006-05-10 01:19:57 UTC (rev 4508)
@@ -1,81 +1,319 @@
#include "platform.h"
+#ifndef E2BIG
+#define E2BIG -1
+#endif
const C_Int_t Posix_Error_E2BIG = E2BIG;
+#ifndef EACCES
+#define EACCES -1
+#endif
const C_Int_t Posix_Error_EACCES = EACCES;
+#ifndef EADDRINUSE
+#define EADDRINUSE -1
+#endif
const C_Int_t Posix_Error_EADDRINUSE = EADDRINUSE;
+#ifndef EADDRNOTAVAIL
+#define EADDRNOTAVAIL -1
+#endif
const C_Int_t Posix_Error_EADDRNOTAVAIL = EADDRNOTAVAIL;
+#ifndef EAFNOSUPPORT
+#define EAFNOSUPPORT -1
+#endif
const C_Int_t Posix_Error_EAFNOSUPPORT = EAFNOSUPPORT;
+#ifndef EAGAIN
+#define EAGAIN -1
+#endif
const C_Int_t Posix_Error_EAGAIN = EAGAIN;
+#ifndef EALREADY
+#define EALREADY -1
+#endif
const C_Int_t Posix_Error_EALREADY = EALREADY;
+#ifndef EBADF
+#define EBADF -1
+#endif
const C_Int_t Posix_Error_EBADF = EBADF;
+#ifndef EBADMSG
+#define EBADMSG -1
+#endif
const C_Int_t Posix_Error_EBADMSG = EBADMSG;
+#ifndef EBUSY
+#define EBUSY -1
+#endif
const C_Int_t Posix_Error_EBUSY = EBUSY;
+#ifndef ECANCELED
+#define ECANCELED -1
+#endif
const C_Int_t Posix_Error_ECANCELED = ECANCELED;
+#ifndef ECHILD
+#define ECHILD -1
+#endif
const C_Int_t Posix_Error_ECHILD = ECHILD;
+#ifndef ECONNABORTED
+#define ECONNABORTED -1
+#endif
const C_Int_t Posix_Error_ECONNABORTED = ECONNABORTED;
+#ifndef ECONNREFUSED
+#define ECONNREFUSED -1
+#endif
const C_Int_t Posix_Error_ECONNREFUSED = ECONNREFUSED;
+#ifndef ECONNRESET
+#define ECONNRESET -1
+#endif
const C_Int_t Posix_Error_ECONNRESET = ECONNRESET;
+#ifndef EDEADLK
+#define EDEADLK -1
+#endif
const C_Int_t Posix_Error_EDEADLK = EDEADLK;
+#ifndef EDESTADDRREQ
+#define EDESTADDRREQ -1
+#endif
const C_Int_t Posix_Error_EDESTADDRREQ = EDESTADDRREQ;
+#ifndef EDOM
+#define EDOM -1
+#endif
const C_Int_t Posix_Error_EDOM = EDOM;
+#ifndef EDQUOT
+#define EDQUOT -1
+#endif
const C_Int_t Posix_Error_EDQUOT = EDQUOT;
+#ifndef EEXIST
+#define EEXIST -1
+#endif
const C_Int_t Posix_Error_EEXIST = EEXIST;
+#ifndef EFAULT
+#define EFAULT -1
+#endif
const C_Int_t Posix_Error_EFAULT = EFAULT;
+#ifndef EFBIG
+#define EFBIG -1
+#endif
const C_Int_t Posix_Error_EFBIG = EFBIG;
+#ifndef EHOSTUNREACH
+#define EHOSTUNREACH -1
+#endif
const C_Int_t Posix_Error_EHOSTUNREACH = EHOSTUNREACH;
+#ifndef EIDRM
+#define EIDRM -1
+#endif
const C_Int_t Posix_Error_EIDRM = EIDRM;
+#ifndef EILSEQ
+#define EILSEQ -1
+#endif
const C_Int_t Posix_Error_EILSEQ = EILSEQ;
+#ifndef EINPROGRESS
+#define EINPROGRESS -1
+#endif
const C_Int_t Posix_Error_EINPROGRESS = EINPROGRESS;
+#ifndef EINTR
+#define EINTR -1
+#endif
const C_Int_t Posix_Error_EINTR = EINTR;
+#ifndef EINVAL
+#define EINVAL -1
+#endif
const C_Int_t Posix_Error_EINVAL = EINVAL;
+#ifndef EIO
+#define EIO -1
+#endif
const C_Int_t Posix_Error_EIO = EIO;
+#ifndef EISCONN
+#define EISCONN -1
+#endif
const C_Int_t Posix_Error_EISCONN = EISCONN;
+#ifndef EISDIR
+#define EISDIR -1
+#endif
const C_Int_t Posix_Error_EISDIR = EISDIR;
+#ifndef ELOOP
+#define ELOOP -1
+#endif
const C_Int_t Posix_Error_ELOOP = ELOOP;
+#ifndef EMFILE
+#define EMFILE -1
+#endif
const C_Int_t Posix_Error_EMFILE = EMFILE;
+#ifndef EMLINK
+#define EMLINK -1
+#endif
const C_Int_t Posix_Error_EMLINK = EMLINK;
+#ifndef EMSGSIZE
+#define EMSGSIZE -1
+#endif
const C_Int_t Posix_Error_EMSGSIZE = EMSGSIZE;
+#ifndef EMULTIHOP
+#define EMULTIHOP -1
+#endif
const C_Int_t Posix_Error_EMULTIHOP = EMULTIHOP;
+#ifndef ENAMETOOLONG
+#define ENAMETOOLONG -1
+#endif
const C_Int_t Posix_Error_ENAMETOOLONG = ENAMETOOLONG;
+#ifndef ENETDOWN
+#define ENETDOWN -1
+#endif
const C_Int_t Posix_Error_ENETDOWN = ENETDOWN;
+#ifndef ENETRESET
+#define ENETRESET -1
+#endif
const C_Int_t Posix_Error_ENETRESET = ENETRESET;
+#ifndef ENETUNREACH
+#define ENETUNREACH -1
+#endif
const C_Int_t Posix_Error_ENETUNREACH = ENETUNREACH;
+#ifndef ENFILE
+#define ENFILE -1
+#endif
const C_Int_t Posix_Error_ENFILE = ENFILE;
+#ifndef ENOBUFS
+#define ENOBUFS -1
+#endif
const C_Int_t Posix_Error_ENOBUFS = ENOBUFS;
+#ifndef ENODATA
+#define ENODATA -1
+#endif
const C_Int_t Posix_Error_ENODATA = ENODATA;
+#ifndef ENODEV
+#define ENODEV -1
+#endif
const C_Int_t Posix_Error_ENODEV = ENODEV;
+#ifndef ENOENT
+#define ENOENT -1
+#endif
const C_Int_t Posix_Error_ENOENT = ENOENT;
+#ifndef ENOEXEC
+#define ENOEXEC -1
+#endif
const C_Int_t Posix_Error_ENOEXEC = ENOEXEC;
+#ifndef ENOLCK
+#define ENOLCK -1
+#endif
const C_Int_t Posix_Error_ENOLCK = ENOLCK;
+#ifndef ENOLINK
+#define ENOLINK -1
+#endif
const C_Int_t Posix_Error_ENOLINK = ENOLINK;
+#ifndef ENOMEM
+#define ENOMEM -1
+#endif
const C_Int_t Posix_Error_ENOMEM = ENOMEM;
+#ifndef ENOMSG
+#define ENOMSG -1
+#endif
const C_Int_t Posix_Error_ENOMSG = ENOMSG;
+#ifndef ENOPROTOOPT
+#define ENOPROTOOPT -1
+#endif
const C_Int_t Posix_Error_ENOPROTOOPT = ENOPROTOOPT;
+#ifndef ENOSPC
+#define ENOSPC -1
+#endif
const C_Int_t Posix_Error_ENOSPC = ENOSPC;
+#ifndef ENOSR
+#define ENOSR -1
+#endif
const C_Int_t Posix_Error_ENOSR = ENOSR;
+#ifndef ENOSTR
+#define ENOSTR -1
+#endif
const C_Int_t Posix_Error_ENOSTR = ENOSTR;
+#ifndef ENOSYS
+#define ENOSYS -1
+#endif
const C_Int_t Posix_Error_ENOSYS = ENOSYS;
+#ifndef ENOTCONN
+#define ENOTCONN -1
+#endif
const C_Int_t Posix_Error_ENOTCONN = ENOTCONN;
+#ifndef ENOTDIR
+#define ENOTDIR -1
+#endif
const C_Int_t Posix_Error_ENOTDIR = ENOTDIR;
+#ifndef ENOTEMPTY
+#define ENOTEMPTY -1
+#endif
const C_Int_t Posix_Error_ENOTEMPTY = ENOTEMPTY;
+#ifndef ENOTSOCK
+#define ENOTSOCK -1
+#endif
const C_Int_t Posix_Error_ENOTSOCK = ENOTSOCK;
+#ifndef ENOTSUP
+#define ENOTSUP -1
+#endif
const C_Int_t Posix_Error_ENOTSUP = ENOTSUP;
+#ifndef ENOTTY
+#define ENOTTY -1
+#endif
const C_Int_t Posix_Error_ENOTTY = ENOTTY;
+#ifndef ENXIO
+#define ENXIO -1
+#endif
const C_Int_t Posix_Error_ENXIO = ENXIO;
+#ifndef EOPNOTSUPP
+#define EOPNOTSUPP -1
+#endif
const C_Int_t Posix_Error_EOPNOTSUPP = EOPNOTSUPP;
+#ifndef EOVERFLOW
+#define EOVERFLOW -1
+#endif
const C_Int_t Posix_Error_EOVERFLOW = EOVERFLOW;
+#ifndef EPERM
+#define EPERM -1
+#endif
const C_Int_t Posix_Error_EPERM = EPERM;
+#ifndef EPIPE
+#define EPIPE -1
+#endif
const C_Int_t Posix_Error_EPIPE = EPIPE;
+#ifndef EPROTO
+#define EPROTO -1
+#endif
const C_Int_t Posix_Error_EPROTO = EPROTO;
+#ifndef EPROTONOSUPPORT
+#define EPROTONOSUPPORT -1
+#endif
const C_Int_t Posix_Error_EPROTONOSUPPORT = EPROTONOSUPPORT;
+#ifndef EPROTOTYPE
+#define EPROTOTYPE -1
+#endif
const C_Int_t Posix_Error_EPROTOTYPE = EPROTOTYPE;
+#ifndef ERANGE
+#define ERANGE -1
+#endif
const C_Int_t Posix_Error_ERANGE = ERANGE;
+#ifndef EROFS
+#define EROFS -1
+#endif
const C_Int_t Posix_Error_EROFS = EROFS;
+#ifndef ESPIPE
+#define ESPIPE -1
+#endif
const C_Int_t Posix_Error_ESPIPE = ESPIPE;
+#ifndef ESRCH
+#define ESRCH -1
+#endif
const C_Int_t Posix_Error_ESRCH = ESRCH;
+#ifndef ESTALE
+#define ESTALE -1
+#endif
const C_Int_t Posix_Error_ESTALE = ESTALE;
+#ifndef ETIME
+#define ETIME -1
+#endif
const C_Int_t Posix_Error_ETIME = ETIME;
+#ifndef ETIMEDOUT
+#define ETIMEDOUT -1
+#endif
const C_Int_t Posix_Error_ETIMEDOUT = ETIMEDOUT;
+#ifndef ETXTBSY
+#define ETXTBSY -1
+#endif
const C_Int_t Posix_Error_ETXTBSY = ETXTBSY;
+#ifndef EWOULDBLOCK
+#define EWOULDBLOCK -1
+#endif
const C_Int_t Posix_Error_EWOULDBLOCK = EWOULDBLOCK;
+#ifndef EXDEV
+#define EXDEV -1
+#endif
const C_Int_t Posix_Error_EXDEV = EXDEV;
+
|
|
From: Stephen W. <sw...@ml...> - 2006-05-09 18:01:40
|
Alpha renamed to avoid "shadows a global declaration" warning.
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.c 2006-05-10 00:54:07 UTC (rev 4506)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.c 2006-05-10 01:01:40 UTC (rev 4507)
@@ -28,8 +28,8 @@
binaryReal(pow)
#undef binaryReal
-float frexpf(float x, int *exp) {
- return (float)frexp((double)x, exp);
+float frexpf(float x, int *e) {
+ return (float)frexp((double)x, e);
}
float ldexpf (float x, int i) {
|
|
From: Matthew F. <fl...@ml...> - 2006-05-09 17:54:08
|
Add may_alias attribute
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c 2006-05-09 23:32:49 UTC (rev 4505)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c 2006-05-10 00:54:07 UTC (rev 4506)
@@ -66,7 +66,7 @@
// "typedef void* Pointer;",
// "typedef uintptr_t Pointer;",
// "typedef unsigned char* Pointer;",
- "struct PointerAux { unsigned char z[4]; } __attribute__ ((aligned (4)));",
+ "struct PointerAux { unsigned char z[4]; } __attribute__ ((aligned (4), may_alias));",
"typedef struct PointerAux* Pointer;",
"#define Array(t) Pointer",
"#define Ref(t) Pointer",
|
|
From: Stephen W. <sw...@ml...> - 2006-05-09 16:32:50
|
Tweaked previous commit. The wrong version was commented out.
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c 2006-05-09 23:16:14 UTC (rev 4504)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c 2006-05-09 23:32:49 UTC (rev 4505)
@@ -65,9 +65,9 @@
"/* ML types */",
// "typedef void* Pointer;",
// "typedef uintptr_t Pointer;",
- "typedef unsigned char* Pointer;",
-// "struct PointerAux { unsigned char z[4]; } __attribute__ ((aligned (4)));",
-// "typedef struct PointerAux* Pointer;",
+ // "typedef unsigned char* Pointer;",
+ "struct PointerAux { unsigned char z[4]; } __attribute__ ((aligned (4)));",
+ "typedef struct PointerAux* Pointer;",
"#define Array(t) Pointer",
"#define Ref(t) Pointer",
"#define Vector(t) const Pointer",
|
|
From: Stephen W. <sw...@ml...> - 2006-05-09 16:16:16
|
Expressed alignment constraint on pointers using
__attribute__ ((aligned (4)))
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c 2006-05-09 22:42:55 UTC (rev 4503)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/gen/gen-types.c 2006-05-09 23:16:14 UTC (rev 4504)
@@ -63,9 +63,11 @@
static const char* mlTypesHStd[] = {
"/* ML types */",
- "typedef unsigned char* Pointer;",
// "typedef void* Pointer;",
// "typedef uintptr_t Pointer;",
+ "typedef unsigned char* Pointer;",
+// "struct PointerAux { unsigned char z[4]; } __attribute__ ((aligned (4)));",
+// "typedef struct PointerAux* Pointer;",
"#define Array(t) Pointer",
"#define Ref(t) Pointer",
"#define Vector(t) const Pointer",
|
|
From: Stephen W. <sw...@ml...> - 2006-05-09 15:42:55
|
Added missing float math functions on SunOS 5.8.
----------------------------------------------------------------------
A mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.c
A mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.h
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.h
----------------------------------------------------------------------
Added: mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.c 2006-05-09 20:44:22 UTC (rev 4502)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.c 2006-05-09 22:42:55 UTC (rev 4503)
@@ -0,0 +1,37 @@
+#define unaryReal(func) \
+float func##f (float x) { \
+ return (float)(func((double)x)); \
+}
+unaryReal(acos)
+unaryReal(asin)
+unaryReal(atan)
+unaryReal(cos)
+unaryReal(cosh)
+unaryReal(exp)
+unaryReal(fabs)
+unaryReal(log)
+unaryReal(log10)
+unaryReal(rint)
+unaryReal(sin)
+unaryReal(sinh)
+unaryReal(sqrt)
+unaryReal(tan)
+unaryReal(tanh)
+#undef unaryReal
+
+#define binaryReal(func) \
+float func##f (float x, float y) { \
+ return (float)(func((double)x, (double)y)); \
+}
+binaryReal(atan2)
+binaryReal(nextafter)
+binaryReal(pow)
+#undef binaryReal
+
+float frexpf(float x, int *exp) {
+ return (float)frexp((double)x, exp);
+}
+
+float ldexpf (float x, int i) {
+ return (float)ldexp((double)x, i);
+}
Added: mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.h
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.h 2006-05-09 20:44:22 UTC (rev 4502)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/float-math.h 2006-05-09 22:42:55 UTC (rev 4503)
@@ -0,0 +1,26 @@
+#define unaryReal(func) float func##f (float x);
+unaryReal(acos)
+unaryReal(asin)
+unaryReal(atan)
+unaryReal(cos)
+unaryReal(cosh)
+unaryReal(exp)
+unaryReal(fabs)
+unaryReal(log)
+unaryReal(log10)
+unaryReal(rint)
+unaryReal(sin)
+unaryReal(sinh)
+unaryReal(sqrt)
+unaryReal(tan)
+unaryReal(tanh)
+#undef unaryReal
+
+#define binaryReal(func) float func##f (float x, float y);
+binaryReal(atan2)
+binaryReal(nextafter)
+binaryReal(pow)
+#undef binaryReal
+
+float frexpf(float x, int *e);
+float ldexpf (float x, int i);
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c 2006-05-09 20:44:22 UTC (rev 4502)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c 2006-05-09 22:42:55 UTC (rev 4503)
@@ -2,6 +2,7 @@
#include <ieeefp.h>
+#include "float-math.c"
#include "getText.c"
#include "mkdir2.c"
#include "mmap.c"
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.h
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.h 2006-05-09 20:44:22 UTC (rev 4502)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.h 2006-05-09 22:42:55 UTC (rev 4503)
@@ -22,6 +22,7 @@
#include <ucontext.h>
#include "feround.h"
+#include "float-math.h"
#include "setenv.h"
#define FE_TONEAREST 0
|
|
From: Stephen W. <sw...@ml...> - 2006-05-09 13:44:22
|
Renamed file statics to avoid spurious warnings when building a cross
runtime.
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/basis/Net/Socket/INetSock.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/basis/Net/Socket/INetSock.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/basis/Net/Socket/INetSock.c 2006-05-09 02:47:07 UTC (rev 4501)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/basis/Net/Socket/INetSock.c 2006-05-09 20:44:22 UTC (rev 4502)
@@ -11,21 +11,21 @@
*((socklen_t*)addrlen) = sizeof(struct sockaddr_in);
}
-static int port;
-static struct in_addr in_addr;
+static int fromAddr_port;
+static struct in_addr fromAddr_in_addr;
void Socket_INetSock_fromAddr (Vector(Word8_t) addr) {
struct sockaddr_in *sa = (struct sockaddr_in*)addr;
assert(sa->sin_family == AF_INET);
- port = sa->sin_port;
- in_addr = sa->sin_addr;
+ fromAddr_port = sa->sin_port;
+ fromAddr_in_addr = sa->sin_addr;
}
C_Int_t Socket_INetSock_getPort (void) {
- return port;
+ return fromAddr_port;
}
void Socket_INetSock_getInAddr (Array(Word8_t) addr) {
- *(struct in_addr*)addr = in_addr;
+ *(struct in_addr*)addr = fromAddr_in_addr;
}
|
|
From: Stephen W. <sw...@ml...> - 2006-05-08 19:47:08
|
Added ignores. ---------------------------------------------------------------------- _U mlton/branches/on-20050822-x86_64-branch/runtime/gen/ A mlton/branches/on-20050822-x86_64-branch/runtime/gen/.ignore ---------------------------------------------------------------------- Property changes on: mlton/branches/on-20050822-x86_64-branch/runtime/gen ___________________________________________________________________ Name: svn:ignore + basis-ffi.sml c-types.sml Added: mlton/branches/on-20050822-x86_64-branch/runtime/gen/.ignore =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/gen/.ignore 2006-05-09 02:46:56 UTC (rev 4500) +++ mlton/branches/on-20050822-x86_64-branch/runtime/gen/.ignore 2006-05-09 02:47:07 UTC (rev 4501) @@ -0,0 +1,2 @@ +basis-ffi.sml +c-types.sml |
|
From: Stephen W. <sw...@ml...> - 2006-05-08 19:46:56
|
Linked with libgdtoa, which is now needed by the runtime (for
gdtoa_strtof).
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/bin/add-cross
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/bin/add-cross
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/bin/add-cross 2006-05-09 02:43:13 UTC (rev 4499)
+++ mlton/branches/on-20050822-x86_64-branch/bin/add-cross 2006-05-09 02:46:56 UTC (rev 4500)
@@ -113,6 +113,6 @@
$src/build/bin/mlton -build-constants true |
ssh $machine "cd $tmp/runtime &&
cat >$exe.c &&
- gcc -I. -o $exe $exe.c libmlton.a -lgmp -lm $libs"
+ gcc -I. -o $exe $exe.c libmlton.a libgdtoa.a -lgmp -lm $libs"
ssh $machine "$tmp/runtime/$exe$suf" >"$lib/$crossTarget/constants"
ssh $machine "rm -rf $tmp"
|
|
From: Stephen W. <sw...@ml...> - 2006-05-08 19:43:14
|
Finished first round of Solaris port. The runtime now compiles.
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c 2006-05-09 02:41:50 UTC (rev 4498)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c 2006-05-09 02:43:13 UTC (rev 4499)
@@ -9,19 +9,6 @@
#include "sysconf.c"
#include "setenv.putenv.c"
-static void catcher (int sig, siginfo_t *sip, ucontext_t *ucp) {
- GC_handleSigProf ((pointer) ucp->uc_mcontext.gregs[REG_PC]);
-}
-
-void setSigProfHandler (struct sigaction *sa) {
- sa->sa_flags = SA_ONSTACK | SA_RESTART | SA_SIGINFO;
- sa->sa_sigaction = (void (*)(int, siginfo_t*, void*))catcher;
-}
-
-void decommit (void *base, size_t length) {
- smunmap (base, length);
-}
-
int fegetround () {
int mode;
@@ -69,10 +56,35 @@
die ("Real_class error: invalid class %d\n", c);
}
}
-
+
+/* ------------------------------------------------- */
+/* GC */
+/* ------------------------------------------------- */
+
+void GC_displayMem () {
+ static char buffer[256];
+ sprintf (buffer, "pmap %d\n", (int)(getpid ()));
+ system (buffer);
+}
+
+static void catcher (__attribute__ ((unused)) int sig,
+ __attribute__ ((unused)) siginfo_t *sip,
+ ucontext_t *ucp) {
+ GC_handleSigProf ((pointer) ucp->uc_mcontext.gregs[REG_PC]);
+}
+
+void GC_setSigProfHandler (struct sigaction *sa) {
+ sa->sa_flags = SA_ONSTACK | SA_RESTART | SA_SIGINFO;
+ sa->sa_sigaction = (void (*)(int, siginfo_t*, void*))catcher;
+}
+
+void GC_decommit (void *base, size_t length) {
+ munmap_safe (base, length);
+}
+
/* On Solaris 5.7, MAP_ANON causes EINVAL and mmap requires a file descriptor.
*/
-void *mmapAnon (void *start, size_t length) {
+void *GC_mmapAnon (void *start, size_t length) {
static int fd = -1;
if (-1 == fd)
@@ -80,12 +92,6 @@
return mmap (start, length, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0);
}
-void release (void *base, size_t length) {
- smunmap (base, length);
+void GC_release (void *base, size_t length) {
+ munmap_safe (base, length);
}
-
-void showMem () {
- static char buffer[256];
- sprintf (buffer, "pmap %d\n", (int)(getpid ()));
- system (buffer);
-}
|
|
From: Stephen W. <sw...@ml...> - 2006-05-08 19:41:51
|
Moved GC_mmapAnon_safe, which is defined in a platform-independent
manner (although it calls a platform-dependent function).
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/gc/virtual-memory.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/use-mmap.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/gc/virtual-memory.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/gc/virtual-memory.c 2006-05-09 02:40:31 UTC (rev 4497)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/gc/virtual-memory.c 2006-05-09 02:41:50 UTC (rev 4498)
@@ -6,6 +6,17 @@
* See the file MLton-LICENSE for details.
*/
+void *GC_mmapAnon_safe (void *p, size_t length) {
+ void *result;
+
+ result = GC_mmapAnon (p, length);
+ if ((void*)-1 == result) {
+ GC_displayMem ();
+ die ("Out of memory.");
+ }
+ return result;
+}
+
static inline void GC_memcpy (pointer src, pointer dst, size_t size) {
if (DEBUG_DETAILED)
fprintf (stderr, "GC_memcpy ("FMTPTR", "FMTPTR", %zu)\n",
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/use-mmap.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/use-mmap.c 2006-05-09 02:40:31 UTC (rev 4497)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/use-mmap.c 2006-05-09 02:41:50 UTC (rev 4498)
@@ -11,14 +11,3 @@
void *GC_mmapAnon (void *start, size_t length) {
return mmapAnon (start, length);
}
-
-void *GC_mmapAnon_safe (void *p, size_t length) {
- void *result;
-
- result = GC_mmapAnon (p, length);
- if ((void*)-1 == result) {
- GC_displayMem ();
- die ("Out of memory.");
- }
- return result;
-}
|
|
From: Stephen W. <sw...@ml...> - 2006-05-08 19:40:32
|
Added __attribute__ ((unused)). Caught up with name changes to
functions. No testing yet.
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/freebsd.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/hpux.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/mingw.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/netbsd.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/openbsd.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.c 2006-05-09 02:11:41 UTC (rev 4496)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/darwin.c 2006-05-09 02:40:31 UTC (rev 4497)
@@ -8,15 +8,6 @@
#include "mmap-protect.c"
#include "use-mmap.c"
-static void catcher (int sig, siginfo_t *sip, ucontext_t *ucp) {
- GC_handleSigProf ((pointer) ucp->uc_mcontext->ss.srr0);
-}
-
-void setSigProfHandler (struct sigaction *sa) {
- sa->sa_flags = SA_ONSTACK | SA_RESTART | SA_SIGINFO;
- sa->sa_sigaction = (void (*)(int, siginfo_t*, void*))catcher;
-}
-
void *getTextEnd () {
return (void*)(get_etext ());
}
@@ -31,7 +22,7 @@
return mh;
}
-void showMem () {
+void GC_displayMem () {
/* FIXME: this won't actually work. */
static char buffer[256];
@@ -39,7 +30,18 @@
(void)system (buffer);
}
-W32 totalRam (GC_state s) {
+static void catcher (__attribute__ ((unused)) int sig,
+ __attribute__ ((unused)) siginfo_t *sip,
+ ucontext_t *ucp) {
+ GC_handleSigProf ((pointer) ucp->uc_mcontext->ss.srr0);
+}
+
+void GC_setSigProfHandler (struct sigaction *sa) {
+ sa->sa_flags = SA_ONSTACK | SA_RESTART | SA_SIGINFO;
+ sa->sa_sigaction = (void (*)(int, siginfo_t*, void*))catcher;
+}
+
+W32 GC_totalRam (GC_state s) {
int mem;
size_t len;
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/freebsd.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/freebsd.c 2006-05-09 02:11:41 UTC (rev 4496)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/freebsd.c 2006-05-09 02:40:31 UTC (rev 4497)
@@ -5,23 +5,25 @@
#include "mmap-protect.c"
#include "use-mmap.c"
-static void catcher (int sig, siginfo_t *sip, ucontext_t *ucp) {
+void GC_displayMem () {
+ static char buffer[256];
+
+ sprintf (buffer, "/bin/cat /proc/%d/map\n", (int)getpid ());
+ (void)system (buffer);
+}
+
+static void catcher (__attribute__ ((unused)) int sig,
+ __attribute__ ((unused)) siginfo_t *sip,
+ ucontext_t *ucp) {
GC_handleSigProf ((pointer) ucp->uc_mcontext.mc_eip);
}
-void setSigProfHandler (struct sigaction *sa) {
+void GC_setSigProfHandler (struct sigaction *sa) {
sa->sa_flags = SA_ONSTACK | SA_RESTART | SA_SIGINFO;
sa->sa_sigaction = (void (*)(int, siginfo_t*, void*))catcher;
}
-void showMem () {
- static char buffer[256];
-
- sprintf (buffer, "/bin/cat /proc/%d/map\n", (int)getpid ());
- (void)system (buffer);
-}
-
-W32 totalRam (GC_state s) {
+W32 GC_totalRam (GC_state s) {
int mem, len;
len = sizeof (int);
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/hpux.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/hpux.c 2006-05-09 02:11:41 UTC (rev 4496)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/hpux.c 2006-05-09 02:40:31 UTC (rev 4497)
@@ -12,14 +12,16 @@
#include "mkdir2.c"
#include "setenv.putenv.c"
-W32 totalRam (GC_state s) {
- struct pst_static buf;
+extern void *__text_start;
+extern void *etext;
- if (pstat_getstatic (&buf, sizeof(buf), 1, 0) < 0)
- diee ("failed to get physical memory size");
- return buf.physical_memory * buf.page_size;
+void *getTextStart () {
+ return &__text_start;
}
+void *getTextEnd () {
+ return &etext;
+}
struct pstnames {
int type;
@@ -65,7 +67,7 @@
return fname;
}
-void showMem () {
+void GC_displayMem () {
int i;
struct pst_vm_status buf;
size_t page_size = sysconf(_SC_PAGE_SIZE);
@@ -88,22 +90,22 @@
}
-static void catcher (int sig, siginfo_t* sip, void* mystery) {
+static void catcher (__attribute__ ((unused)) int sig,
+ __attribute__ ((unused)) siginfo_t* sip,
+ void* mystery) {
ucontext_t* ucp = (ucontext_t*)mystery;
GC_handleSigProf ((pointer) (ucp->uc_link));
}
-void setSigProfHandler (struct sigaction *sa) {
+void GC_setSigProfHandler (struct sigaction *sa) {
sa->sa_flags = SA_ONSTACK | SA_RESTART | SA_SIGINFO;
sa->sa_sigaction = (void (*)(int, siginfo_t*, void*))catcher;
}
-extern void *__text_start;
-extern void *etext;
+W32 GC_totalRam (GC_state s) {
+ struct pst_static buf;
-void *getTextStart () {
- return &__text_start;
+ if (pstat_getstatic (&buf, sizeof(buf), 1, 0) < 0)
+ diee ("failed to get physical memory size");
+ return buf.physical_memory * buf.page_size;
}
-void *getTextEnd () {
- return &etext;
-}
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/mingw.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/mingw.c 2006-05-09 02:11:41 UTC (rev 4496)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/mingw.c 2006-05-09 02:40:31 UTC (rev 4497)
@@ -4,10 +4,26 @@
#include "windows.c"
-void decommit (void *base, size_t length) {
+void GC_decommit (void *base, size_t length) {
Windows_decommit (base, length);
}
+void *GC_mmapAnon (void *start, size_t length) {
+ return Windows_mmapAnon (start, length);
+}
+
+void GC_release (void *base, size_t length) {
+ Windows_release (base);
+}
+
+Word32 GC_totalRam (GC_state s) {
+ MEMORYSTATUS memStat;
+
+ memStat.dwLength = sizeof(memStat);
+ GlobalMemoryStatus(&memStat);
+ return memStat.dwTotalPhys;
+}
+
HANDLE fileDesHandle (int fd) {
return (HANDLE)(_get_osfhandle (fd));
}
@@ -32,22 +48,6 @@
return _open (file_name, _O_CREAT | _O_RDWR, _S_IREAD | _S_IWRITE);
}
-void *mmapAnon (void *start, size_t length) {
- return Windows_mmapAnon (start, length);
-}
-
-void release (void *base, size_t length) {
- Windows_release (base);
-}
-
-Word32 totalRam (GC_state s) {
- MEMORYSTATUS memStat;
-
- memStat.dwLength = sizeof(memStat);
- GlobalMemoryStatus(&memStat);
- return memStat.dwTotalPhys;
-}
-
/* ------------------------------------------------- */
/* Date */
/* ------------------------------------------------- */
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/netbsd.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/netbsd.c 2006-05-09 02:11:41 UTC (rev 4496)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/netbsd.c 2006-05-09 02:40:31 UTC (rev 4497)
@@ -7,11 +7,13 @@
#include "totalRam.sysctl.c"
#include "use-mmap.c"
-static void catcher (int sig, int code, struct sigcontext *ucp) {
+static void catcher (__attribute__ ((unused)) int sig,
+ __attribute__ ((unused)) int code,
+ struct sigcontext *ucp) {
GC_handleSigProf ((pointer) ucp->sc_eip);
}
-void setSigProfHandler (struct sigaction *sa) {
+void GC_setSigProfHandler (struct sigaction *sa) {
sa->sa_flags = SA_ONSTACK | SA_RESTART;
sa->sa_handler = (void (*)(int))catcher;
}
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/openbsd.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/openbsd.c 2006-05-09 02:11:41 UTC (rev 4496)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/openbsd.c 2006-05-09 02:40:31 UTC (rev 4497)
@@ -7,11 +7,13 @@
#include "totalRam.sysctl.c"
#include "use-mmap.c"
-static void catcher (int sig, siginfo_t *sip, ucontext_t *ucp) {
+static void catcher (__attribute__ ((unused)) int sig,
+ __attribute__ ((unused)) siginfo_t *sip,
+ ucontext_t *ucp) {
GC_handleSigProf ((pointer) ucp->sc_eip);
}
-void setSigProfHandler (struct sigaction *sa) {
+void GC_setSigProfHandler (struct sigaction *sa) {
sa->sa_flags = SA_ONSTACK | SA_RESTART | SA_SIGINFO;
sa->sa_sigaction = (void (*)(int, siginfo_t*, void*))catcher;
}
|
|
From: Stephen W. <sw...@ml...> - 2006-05-08 19:11:43
|
Moved the prototypes for gdtoa_strto{d,f} into platform.h so they can
be used anywhere. Used gdtoa_strtof instead of strtof in gc/init.c
since some platforms (e.g SunOS 5.8) don't have strtof and we will
always have our own gdtoa_strtof.
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/basis/Real/strto.c
U mlton/branches/on-20050822-x86_64-branch/runtime/gc/init.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform.h
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/basis/Real/strto.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/basis/Real/strto.c 2006-05-09 01:10:25 UTC (rev 4495)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/basis/Real/strto.c 2006-05-09 02:11:41 UTC (rev 4496)
@@ -1,8 +1,5 @@
#include "platform.h"
-Real32_t gdtoa_strtof (const char *s, char **endptr);
-Real64_t gdtoa_strtod (const char *s, char **endptr);
-
Real32_t Real32_strto (NullString8_t s) {
char *endptr;
Real32_t res;
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/gc/init.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/gc/init.c 2006-05-09 01:10:25 UTC (rev 4495)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/gc/init.c 2006-05-09 02:11:41 UTC (rev 4496)
@@ -24,7 +24,7 @@
char *endptr;
float f;
- f = strtof (s, &endptr);
+ f = gdtoa_strtof (s, &endptr);
if (s == endptr)
die ("Invalid @MLton float: %s.", s);
return f;
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform.h
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform.h 2006-05-09 01:10:25 UTC (rev 4495)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform.h 2006-05-09 02:11:41 UTC (rev 4496)
@@ -106,6 +106,13 @@
#include "basis-ffi.h"
/* ---------------------------------------------------------------- */
+/* gdtoa */
+/* ---------------------------------------------------------------- */
+
+Real32_t gdtoa_strtof (const char *s, char **endptr);
+Real64_t gdtoa_strtod (const char *s, char **endptr);
+
+/* ---------------------------------------------------------------- */
/* Runtime Init/Exit */
/* ---------------------------------------------------------------- */
|
|
From: Matthew F. <fl...@ml...> - 2006-05-08 18:10:31
|
Drop old compatability functions.
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/basis/Int/PackWord.c
U mlton/branches/on-20050822-x86_64-branch/runtime/platform.h
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/basis/Int/PackWord.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/basis/Int/PackWord.c 2006-05-09 01:09:23 UTC (rev 4494)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/basis/Int/PackWord.c 2006-05-09 01:10:25 UTC (rev 4495)
@@ -62,16 +62,3 @@
#undef mkSubSeqRev
#undef mkUpdate
#undef all
-
-
-Word32_t Word8Array_subWord32Rev (Array(Word8_t) a, C_Ptrdiff_t offset) {
- return PackWord32_subArrRev (a, 4 * offset);
-}
-
-void Word8Array_updateWord32Rev (Array(Word8_t) a, C_Ptrdiff_t offset, Word32_t w) {
- PackWord32_updateRev (a, 4 * offset, w);
-}
-
-Word32_t Word8Vector_subWord32Rev (Vector(Word8_t) v, C_Ptrdiff_t offset) {
- return PackWord32_subVecRev (v, 4 * offset);
-}
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform.h
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform.h 2006-05-09 01:09:23 UTC (rev 4494)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform.h 2006-05-09 01:10:25 UTC (rev 4495)
@@ -203,15 +203,6 @@
extern Bool MLton_Platform_CygwinUseMmap;
/* ------------------------------------------------- */
-/* PackWord */
-/* ------------------------------------------------- */
-
-/* Compat */
-Word32_t Word8Array_subWord32Rev (Array(Word8_t) a, C_Ptrdiff_t offset);
-void Word8Array_updateWord32Rev (Array(Word8_t) a, C_Ptrdiff_t offset, Word32_t w);
-Word32_t Word8Vector_subWord32Rev (Vector(Word8_t) v, C_Ptrdiff_t offset);
-
-/* ------------------------------------------------- */
/* Socket */
/* ------------------------------------------------- */
|
|
From: Matthew F. <fl...@ml...> - 2006-05-08 18:09:24
|
Note that fenv.h is needed, but can't be included ---------------------------------------------------------------------- U mlton/branches/on-20050822-x86_64-branch/runtime/cenv.h ---------------------------------------------------------------------- Modified: mlton/branches/on-20050822-x86_64-branch/runtime/cenv.h =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/cenv.h 2006-05-09 01:00:56 UTC (rev 4493) +++ mlton/branches/on-20050822-x86_64-branch/runtime/cenv.h 2006-05-09 01:09:23 UTC (rev 4494) @@ -26,6 +26,7 @@ // #include <complex.h> #include <ctype.h> #include <errno.h> +// fenv.h (or approximate equivalent) comes from the n-way OS switch below. // #include <fenv.h> #include <float.h> #include <inttypes.h> @@ -95,4 +96,6 @@ #error unknown platform #endif + + #endif /* _MLTON_CENV_H_ */ |
|
From: Matthew F. <fl...@ml...> - 2006-05-08 18:00:58
|
Filter missing _SC and _PC constants in ML
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/basis-library/posix/file-sys.sml
U mlton/branches/on-20050822-x86_64-branch/basis-library/posix/proc-env.sml
U mlton/branches/on-20050822-x86_64-branch/basis-library/primitive/basis-ffi.sml
U mlton/branches/on-20050822-x86_64-branch/runtime/Posix/FileSys/FileSys-consts.c
U mlton/branches/on-20050822-x86_64-branch/runtime/Posix/ProcEnv/sysconf-consts.c
U mlton/branches/on-20050822-x86_64-branch/runtime/gen/basis-ffi.def
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/basis-library/posix/file-sys.sml
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/basis-library/posix/file-sys.sml 2006-05-08 22:05:37 UTC (rev 4492)
+++ mlton/branches/on-20050822-x86_64-branch/basis-library/posix/file-sys.sml 2006-05-09 01:00:56 UTC (rev 4493)
@@ -405,29 +405,34 @@
local
local
open Prim.PC
+ infixr 5 ::?
+ fun (n,s) ::? l =
+ if n = C_Int.fromInt ~1
+ then l
+ else (n,s) :: l
in
val properties =
- [
- (ALLOC_SIZE_MIN,"ALLOC_SIZE_MIN"),
- (ASYNC_IO,"ASYNC_IO"),
- (CHOWN_RESTRICTED,"CHOWN_RESTRICTED"),
- (FILESIZEBITS,"FILESIZEBITS"),
- (LINK_MAX,"LINK_MAX"),
- (MAX_CANON,"MAX_CANON"),
- (MAX_INPUT,"MAX_INPUT"),
- (NAME_MAX,"NAME_MAX"),
- (NO_TRUNC,"NO_TRUNC"),
- (PATH_MAX,"PATH_MAX"),
- (PIPE_BUF,"PIPE_BUF"),
- (PRIO_IO,"PRIO_IO"),
- (REC_INCR_XFER_SIZE,"REC_INCR_XFER_SIZE"),
- (REC_MAX_XFER_SIZE,"REC_MAX_XFER_SIZE"),
- (REC_MIN_XFER_SIZE,"REC_MIN_XFER_SIZE"),
- (REC_XFER_ALIGN,"REC_XFER_ALIGN"),
- (SYMLINK_MAX,"SYMLINK_MAX"),
- (SYNC_IO,"SYNC_IO"),
- (VDISABLE,"VDISABLE")
- ]
+ (TWO_SYMLINKS,"2_SYMLINKS") ::?
+ (ALLOC_SIZE_MIN,"ALLOC_SIZE_MIN") ::?
+ (ASYNC_IO,"ASYNC_IO") ::?
+ (CHOWN_RESTRICTED,"CHOWN_RESTRICTED") ::?
+ (FILESIZEBITS,"FILESIZEBITS") ::?
+ (LINK_MAX,"LINK_MAX") ::?
+ (MAX_CANON,"MAX_CANON") ::?
+ (MAX_INPUT,"MAX_INPUT") ::?
+ (NAME_MAX,"NAME_MAX") ::?
+ (NO_TRUNC,"NO_TRUNC") ::?
+ (PATH_MAX,"PATH_MAX") ::?
+ (PIPE_BUF,"PIPE_BUF") ::?
+ (PRIO_IO,"PRIO_IO") ::?
+ (REC_INCR_XFER_SIZE,"REC_INCR_XFER_SIZE") ::?
+ (REC_MAX_XFER_SIZE,"REC_MAX_XFER_SIZE") ::?
+ (REC_MIN_XFER_SIZE,"REC_MIN_XFER_SIZE") ::?
+ (REC_XFER_ALIGN,"REC_XFER_ALIGN") ::?
+ (SYMLINK_MAX,"SYMLINK_MAX") ::?
+ (SYNC_IO,"SYNC_IO") ::?
+ (VDISABLE,"VDISABLE") ::?
+ []
end
fun convertProperty s =
Modified: mlton/branches/on-20050822-x86_64-branch/basis-library/posix/proc-env.sml
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/basis-library/posix/proc-env.sml 2006-05-08 22:05:37 UTC (rev 4492)
+++ mlton/branches/on-20050822-x86_64-branch/basis-library/posix/proc-env.sml 2006-05-09 01:00:56 UTC (rev 4493)
@@ -79,132 +79,139 @@
val time = Time.now
local
- val sysconfNames =
- [
- (Prim.SC_2_CHAR_TERM,"2_CHAR_TERM"),
- (Prim.SC_2_C_BIND,"2_C_BIND"),
- (Prim.SC_2_C_DEV,"2_C_DEV"),
- (Prim.SC_2_FORT_DEV,"2_FORT_DEV"),
- (Prim.SC_2_FORT_RUN,"2_FORT_RUN"),
- (Prim.SC_2_LOCALEDEF,"2_LOCALEDEF"),
- (Prim.SC_2_PBS,"2_PBS"),
- (Prim.SC_2_PBS_ACCOUNTING,"2_PBS_ACCOUNTING"),
- (Prim.SC_2_PBS_CHECKPOINT,"2_PBS_CHECKPOINT"),
- (Prim.SC_2_PBS_LOCATE,"2_PBS_LOCATE"),
- (Prim.SC_2_PBS_MESSAGE,"2_PBS_MESSAGE"),
- (Prim.SC_2_PBS_TRACK,"2_PBS_TRACK"),
- (Prim.SC_2_SW_DEV,"2_SW_DEV"),
- (Prim.SC_2_UPE,"2_UPE"),
- (Prim.SC_2_VERSION,"2_VERSION"),
- (Prim.SC_ADVISORY_INFO,"ADVISORY_INFO"),
- (Prim.SC_AIO_LISTIO_MAX,"AIO_LISTIO_MAX"),
- (Prim.SC_AIO_MAX,"AIO_MAX"),
- (Prim.SC_AIO_PRIO_DELTA_MAX,"AIO_PRIO_DELTA_MAX"),
- (Prim.SC_ARG_MAX,"ARG_MAX"),
- (Prim.SC_ASYNCHRONOUS_IO,"ASYNCHRONOUS_IO"),
- (Prim.SC_ATEXIT_MAX,"ATEXIT_MAX"),
- (Prim.SC_BARRIERS,"BARRIERS"),
- (Prim.SC_BC_BASE_MAX,"BC_BASE_MAX"),
- (Prim.SC_BC_DIM_MAX,"BC_DIM_MAX"),
- (Prim.SC_BC_SCALE_MAX,"BC_SCALE_MAX"),
- (Prim.SC_BC_STRING_MAX,"BC_STRING_MAX"),
- (Prim.SC_CHILD_MAX,"CHILD_MAX"),
- (Prim.SC_CLK_TCK,"CLK_TCK"),
- (Prim.SC_CLOCK_SELECTION,"CLOCK_SELECTION"),
- (Prim.SC_COLL_WEIGHTS_MAX,"COLL_WEIGHTS_MAX"),
- (Prim.SC_CPUTIME,"CPUTIME"),
- (Prim.SC_DELAYTIMER_MAX,"DELAYTIMER_MAX"),
- (Prim.SC_EXPR_NEST_MAX,"EXPR_NEST_MAX"),
- (Prim.SC_FSYNC,"FSYNC"),
- (Prim.SC_GETGR_R_SIZE_MAX,"GETGR_R_SIZE_MAX"),
- (Prim.SC_GETPW_R_SIZE_MAX,"GETPW_R_SIZE_MAX"),
- (Prim.SC_HOST_NAME_MAX,"HOST_NAME_MAX"),
- (Prim.SC_IOV_MAX,"IOV_MAX"),
- (* (Prim.SC_IPV6,"IPV6"), *)
- (Prim.SC_JOB_CONTROL,"JOB_CONTROL"),
- (Prim.SC_LINE_MAX,"LINE_MAX"),
- (Prim.SC_LOGIN_NAME_MAX,"LOGIN_NAME_MAX"),
- (Prim.SC_MAPPED_FILES,"MAPPED_FILES"),
- (Prim.SC_MEMLOCK,"MEMLOCK"),
- (Prim.SC_MEMLOCK_RANGE,"MEMLOCK_RANGE"),
- (Prim.SC_MEMORY_PROTECTION,"MEMORY_PROTECTION"),
- (Prim.SC_MESSAGE_PASSING,"MESSAGE_PASSING"),
- (Prim.SC_MONOTONIC_CLOCK,"MONOTONIC_CLOCK"),
- (Prim.SC_MQ_OPEN_MAX,"MQ_OPEN_MAX"),
- (Prim.SC_MQ_PRIO_MAX,"MQ_PRIO_MAX"),
- (Prim.SC_NGROUPS_MAX,"NGROUPS_MAX"),
- (Prim.SC_OPEN_MAX,"OPEN_MAX"),
- (Prim.SC_PAGESIZE,"PAGESIZE"),
- (Prim.SC_PAGE_SIZE,"PAGE_SIZE"),
- (Prim.SC_PRIORITIZED_IO,"PRIORITIZED_IO"),
- (Prim.SC_PRIORITY_SCHEDULING,"PRIORITY_SCHEDULING"),
- (* (Prim.SC_RAW_SOCKETS,"RAW_SOCKETS"), *)
- (Prim.SC_READER_WRITER_LOCKS,"READER_WRITER_LOCKS"),
- (Prim.SC_REALTIME_SIGNALS,"REALTIME_SIGNALS"),
- (Prim.SC_REGEXP,"REGEXP"),
- (Prim.SC_RE_DUP_MAX,"RE_DUP_MAX"),
- (Prim.SC_RTSIG_MAX,"RTSIG_MAX"),
- (Prim.SC_SAVED_IDS,"SAVED_IDS"),
- (Prim.SC_SEMAPHORES,"SEMAPHORES"),
- (Prim.SC_SEM_NSEMS_MAX,"SEM_NSEMS_MAX"),
- (Prim.SC_SEM_VALUE_MAX,"SEM_VALUE_MAX"),
- (Prim.SC_SHARED_MEMORY_OBJECTS,"SHARED_MEMORY_OBJECTS"),
- (Prim.SC_SHELL,"SHELL"),
- (Prim.SC_SIGQUEUE_MAX,"SIGQUEUE_MAX"),
- (Prim.SC_SPAWN,"SPAWN"),
- (Prim.SC_SPIN_LOCKS,"SPIN_LOCKS"),
- (Prim.SC_SPORADIC_SERVER,"SPORADIC_SERVER"),
- (Prim.SC_SS_REPL_MAX,"SS_REPL_MAX"),
- (Prim.SC_STREAM_MAX,"STREAM_MAX"),
- (Prim.SC_SYMLOOP_MAX,"SYMLOOP_MAX"),
- (Prim.SC_SYNCHRONIZED_IO,"SYNCHRONIZED_IO"),
- (Prim.SC_THREADS,"THREADS"),
- (Prim.SC_THREAD_ATTR_STACKADDR,"THREAD_ATTR_STACKADDR"),
- (Prim.SC_THREAD_ATTR_STACKSIZE,"THREAD_ATTR_STACKSIZE"),
- (Prim.SC_THREAD_CPUTIME,"THREAD_CPUTIME"),
- (Prim.SC_THREAD_DESTRUCTOR_ITERATIONS,"THREAD_DESTRUCTOR_ITERATIONS"),
- (Prim.SC_THREAD_KEYS_MAX,"THREAD_KEYS_MAX"),
- (Prim.SC_THREAD_PRIORITY_SCHEDULING,"THREAD_PRIORITY_SCHEDULING"),
- (Prim.SC_THREAD_PRIO_INHERIT,"THREAD_PRIO_INHERIT"),
- (Prim.SC_THREAD_PRIO_PROTECT,"THREAD_PRIO_PROTECT"),
- (Prim.SC_THREAD_PROCESS_SHARED,"THREAD_PROCESS_SHARED"),
- (Prim.SC_THREAD_SAFE_FUNCTIONS,"THREAD_SAFE_FUNCTIONS"),
- (Prim.SC_THREAD_SPORADIC_SERVER,"THREAD_SPORADIC_SERVER"),
- (Prim.SC_THREAD_STACK_MIN,"THREAD_STACK_MIN"),
- (Prim.SC_THREAD_THREADS_MAX,"THREAD_THREADS_MAX"),
- (Prim.SC_TIMEOUTS,"TIMEOUTS"),
- (Prim.SC_TIMERS,"TIMERS"),
- (Prim.SC_TIMER_MAX,"TIMER_MAX"),
- (Prim.SC_TRACE,"TRACE"),
- (Prim.SC_TRACE_EVENT_FILTER,"TRACE_EVENT_FILTER"),
- (Prim.SC_TRACE_EVENT_NAME_MAX,"TRACE_EVENT_NAME_MAX"),
- (Prim.SC_TRACE_INHERIT,"TRACE_INHERIT"),
- (Prim.SC_TRACE_LOG,"TRACE_LOG"),
- (Prim.SC_TRACE_NAME_MAX,"TRACE_NAME_MAX"),
- (Prim.SC_TRACE_SYS_MAX,"TRACE_SYS_MAX"),
- (Prim.SC_TRACE_USER_EVENT_MAX,"TRACE_USER_EVENT_MAX"),
- (Prim.SC_TTY_NAME_MAX,"TTY_NAME_MAX"),
- (Prim.SC_TYPED_MEMORY_OBJECTS,"TYPED_MEMORY_OBJECTS"),
- (Prim.SC_TZNAME_MAX,"TZNAME_MAX"),
- (Prim.SC_V6_ILP32_OFF32,"V6_ILP32_OFF32"),
- (Prim.SC_V6_ILP32_OFFBIG,"V6_ILP32_OFFBIG"),
- (Prim.SC_V6_LP64_OFF64,"V6_LP64_OFF64"),
- (Prim.SC_V6_LPBIG_OFFBIG,"V6_LPBIG_OFFBIG"),
- (Prim.SC_VERSION,"VERSION"),
- (Prim.SC_XBS5_ILP32_OFF32,"XBS5_ILP32_OFF32"),
- (Prim.SC_XBS5_ILP32_OFFBIG,"XBS5_ILP32_OFFBIG"),
- (Prim.SC_XBS5_LP64_OFF64,"XBS5_LP64_OFF64"),
- (Prim.SC_XBS5_LPBIG_OFFBIG,"XBS5_LPBIG_OFFBIG"),
- (Prim.SC_XOPEN_CRYPT,"XOPEN_CRYPT"),
- (Prim.SC_XOPEN_ENH_I18N,"XOPEN_ENH_I18N"),
- (Prim.SC_XOPEN_LEGACY,"XOPEN_LEGACY"),
- (Prim.SC_XOPEN_REALTIME,"XOPEN_REALTIME"),
- (Prim.SC_XOPEN_REALTIME_THREADS,"XOPEN_REALTIME_THREADS"),
- (Prim.SC_XOPEN_SHM,"XOPEN_SHM"),
- (Prim.SC_XOPEN_STREAMS,"XOPEN_STREAMS"),
- (Prim.SC_XOPEN_UNIX,"XOPEN_UNIX"),
- (Prim.SC_XOPEN_VERSION,"XOPEN_VERSION")
- ]
+ local
+ infixr 5 ::?
+ fun (n,s) ::? l =
+ if n = C_Int.fromInt ~1
+ then l
+ else (n,s) :: l
+ in
+ val sysconfNames =
+ (Prim.SC_2_CHAR_TERM,"2_CHAR_TERM") ::?
+ (Prim.SC_2_C_BIND,"2_C_BIND") ::?
+ (Prim.SC_2_C_DEV,"2_C_DEV") ::?
+ (Prim.SC_2_FORT_DEV,"2_FORT_DEV") ::?
+ (Prim.SC_2_FORT_RUN,"2_FORT_RUN") ::?
+ (Prim.SC_2_LOCALEDEF,"2_LOCALEDEF") ::?
+ (Prim.SC_2_PBS,"2_PBS") ::?
+ (Prim.SC_2_PBS_ACCOUNTING,"2_PBS_ACCOUNTING") ::?
+ (Prim.SC_2_PBS_CHECKPOINT,"2_PBS_CHECKPOINT") ::?
+ (Prim.SC_2_PBS_LOCATE,"2_PBS_LOCATE") ::?
+ (Prim.SC_2_PBS_MESSAGE,"2_PBS_MESSAGE") ::?
+ (Prim.SC_2_PBS_TRACK,"2_PBS_TRACK") ::?
+ (Prim.SC_2_SW_DEV,"2_SW_DEV") ::?
+ (Prim.SC_2_UPE,"2_UPE") ::?
+ (Prim.SC_2_VERSION,"2_VERSION") ::?
+ (Prim.SC_ADVISORY_INFO,"ADVISORY_INFO") ::?
+ (Prim.SC_AIO_LISTIO_MAX,"AIO_LISTIO_MAX") ::?
+ (Prim.SC_AIO_MAX,"AIO_MAX") ::?
+ (Prim.SC_AIO_PRIO_DELTA_MAX,"AIO_PRIO_DELTA_MAX") ::?
+ (Prim.SC_ARG_MAX,"ARG_MAX") ::?
+ (Prim.SC_ASYNCHRONOUS_IO,"ASYNCHRONOUS_IO") ::?
+ (Prim.SC_ATEXIT_MAX,"ATEXIT_MAX") ::?
+ (Prim.SC_BARRIERS,"BARRIERS") ::?
+ (Prim.SC_BC_BASE_MAX,"BC_BASE_MAX") ::?
+ (Prim.SC_BC_DIM_MAX,"BC_DIM_MAX") ::?
+ (Prim.SC_BC_SCALE_MAX,"BC_SCALE_MAX") ::?
+ (Prim.SC_BC_STRING_MAX,"BC_STRING_MAX") ::?
+ (Prim.SC_CHILD_MAX,"CHILD_MAX") ::?
+ (Prim.SC_CLK_TCK,"CLK_TCK") ::?
+ (Prim.SC_CLOCK_SELECTION,"CLOCK_SELECTION") ::?
+ (Prim.SC_COLL_WEIGHTS_MAX,"COLL_WEIGHTS_MAX") ::?
+ (Prim.SC_CPUTIME,"CPUTIME") ::?
+ (Prim.SC_DELAYTIMER_MAX,"DELAYTIMER_MAX") ::?
+ (Prim.SC_EXPR_NEST_MAX,"EXPR_NEST_MAX") ::?
+ (Prim.SC_FSYNC,"FSYNC") ::?
+ (Prim.SC_GETGR_R_SIZE_MAX,"GETGR_R_SIZE_MAX") ::?
+ (Prim.SC_GETPW_R_SIZE_MAX,"GETPW_R_SIZE_MAX") ::?
+ (Prim.SC_HOST_NAME_MAX,"HOST_NAME_MAX") ::?
+ (Prim.SC_IOV_MAX,"IOV_MAX") ::?
+ (Prim.SC_IPV6,"IPV6") ::?
+ (Prim.SC_JOB_CONTROL,"JOB_CONTROL") ::?
+ (Prim.SC_LINE_MAX,"LINE_MAX") ::?
+ (Prim.SC_LOGIN_NAME_MAX,"LOGIN_NAME_MAX") ::?
+ (Prim.SC_MAPPED_FILES,"MAPPED_FILES") ::?
+ (Prim.SC_MEMLOCK,"MEMLOCK") ::?
+ (Prim.SC_MEMLOCK_RANGE,"MEMLOCK_RANGE") ::?
+ (Prim.SC_MEMORY_PROTECTION,"MEMORY_PROTECTION") ::?
+ (Prim.SC_MESSAGE_PASSING,"MESSAGE_PASSING") ::?
+ (Prim.SC_MONOTONIC_CLOCK,"MONOTONIC_CLOCK") ::?
+ (Prim.SC_MQ_OPEN_MAX,"MQ_OPEN_MAX") ::?
+ (Prim.SC_MQ_PRIO_MAX,"MQ_PRIO_MAX") ::?
+ (Prim.SC_NGROUPS_MAX,"NGROUPS_MAX") ::?
+ (Prim.SC_OPEN_MAX,"OPEN_MAX") ::?
+ (Prim.SC_PAGESIZE,"PAGESIZE") ::?
+ (Prim.SC_PAGE_SIZE,"PAGE_SIZE") ::?
+ (Prim.SC_PRIORITIZED_IO,"PRIORITIZED_IO") ::?
+ (Prim.SC_PRIORITY_SCHEDULING,"PRIORITY_SCHEDULING") ::?
+ (Prim.SC_RAW_SOCKETS,"RAW_SOCKETS") ::?
+ (Prim.SC_READER_WRITER_LOCKS,"READER_WRITER_LOCKS") ::?
+ (Prim.SC_REALTIME_SIGNALS,"REALTIME_SIGNALS") ::?
+ (Prim.SC_REGEXP,"REGEXP") ::?
+ (Prim.SC_RE_DUP_MAX,"RE_DUP_MAX") ::?
+ (Prim.SC_RTSIG_MAX,"RTSIG_MAX") ::?
+ (Prim.SC_SAVED_IDS,"SAVED_IDS") ::?
+ (Prim.SC_SEMAPHORES,"SEMAPHORES") ::?
+ (Prim.SC_SEM_NSEMS_MAX,"SEM_NSEMS_MAX") ::?
+ (Prim.SC_SEM_VALUE_MAX,"SEM_VALUE_MAX") ::?
+ (Prim.SC_SHARED_MEMORY_OBJECTS,"SHARED_MEMORY_OBJECTS") ::?
+ (Prim.SC_SHELL,"SHELL") ::?
+ (Prim.SC_SIGQUEUE_MAX,"SIGQUEUE_MAX") ::?
+ (Prim.SC_SPAWN,"SPAWN") ::?
+ (Prim.SC_SPIN_LOCKS,"SPIN_LOCKS") ::?
+ (Prim.SC_SPORADIC_SERVER,"SPORADIC_SERVER") ::?
+ (Prim.SC_SS_REPL_MAX,"SS_REPL_MAX") ::?
+ (Prim.SC_STREAM_MAX,"STREAM_MAX") ::?
+ (Prim.SC_SYMLOOP_MAX,"SYMLOOP_MAX") ::?
+ (Prim.SC_SYNCHRONIZED_IO,"SYNCHRONIZED_IO") ::?
+ (Prim.SC_THREADS,"THREADS") ::?
+ (Prim.SC_THREAD_ATTR_STACKADDR,"THREAD_ATTR_STACKADDR") ::?
+ (Prim.SC_THREAD_ATTR_STACKSIZE,"THREAD_ATTR_STACKSIZE") ::?
+ (Prim.SC_THREAD_CPUTIME,"THREAD_CPUTIME") ::?
+ (Prim.SC_THREAD_DESTRUCTOR_ITERATIONS,"THREAD_DESTRUCTOR_ITERATIONS") ::?
+ (Prim.SC_THREAD_KEYS_MAX,"THREAD_KEYS_MAX") ::?
+ (Prim.SC_THREAD_PRIORITY_SCHEDULING,"THREAD_PRIORITY_SCHEDULING") ::?
+ (Prim.SC_THREAD_PRIO_INHERIT,"THREAD_PRIO_INHERIT") ::?
+ (Prim.SC_THREAD_PRIO_PROTECT,"THREAD_PRIO_PROTECT") ::?
+ (Prim.SC_THREAD_PROCESS_SHARED,"THREAD_PROCESS_SHARED") ::?
+ (Prim.SC_THREAD_SAFE_FUNCTIONS,"THREAD_SAFE_FUNCTIONS") ::?
+ (Prim.SC_THREAD_SPORADIC_SERVER,"THREAD_SPORADIC_SERVER") ::?
+ (Prim.SC_THREAD_STACK_MIN,"THREAD_STACK_MIN") ::?
+ (Prim.SC_THREAD_THREADS_MAX,"THREAD_THREADS_MAX") ::?
+ (Prim.SC_TIMEOUTS,"TIMEOUTS") ::?
+ (Prim.SC_TIMERS,"TIMERS") ::?
+ (Prim.SC_TIMER_MAX,"TIMER_MAX") ::?
+ (Prim.SC_TRACE,"TRACE") ::?
+ (Prim.SC_TRACE_EVENT_FILTER,"TRACE_EVENT_FILTER") ::?
+ (Prim.SC_TRACE_EVENT_NAME_MAX,"TRACE_EVENT_NAME_MAX") ::?
+ (Prim.SC_TRACE_INHERIT,"TRACE_INHERIT") ::?
+ (Prim.SC_TRACE_LOG,"TRACE_LOG") ::?
+ (Prim.SC_TRACE_NAME_MAX,"TRACE_NAME_MAX") ::?
+ (Prim.SC_TRACE_SYS_MAX,"TRACE_SYS_MAX") ::?
+ (Prim.SC_TRACE_USER_EVENT_MAX,"TRACE_USER_EVENT_MAX") ::?
+ (Prim.SC_TTY_NAME_MAX,"TTY_NAME_MAX") ::?
+ (Prim.SC_TYPED_MEMORY_OBJECTS,"TYPED_MEMORY_OBJECTS") ::?
+ (Prim.SC_TZNAME_MAX,"TZNAME_MAX") ::?
+ (Prim.SC_V6_ILP32_OFF32,"V6_ILP32_OFF32") ::?
+ (Prim.SC_V6_ILP32_OFFBIG,"V6_ILP32_OFFBIG") ::?
+ (Prim.SC_V6_LP64_OFF64,"V6_LP64_OFF64") ::?
+ (Prim.SC_V6_LPBIG_OFFBIG,"V6_LPBIG_OFFBIG") ::?
+ (Prim.SC_VERSION,"VERSION") ::?
+ (Prim.SC_XBS5_ILP32_OFF32,"XBS5_ILP32_OFF32") ::?
+ (Prim.SC_XBS5_ILP32_OFFBIG,"XBS5_ILP32_OFFBIG") ::?
+ (Prim.SC_XBS5_LP64_OFF64,"XBS5_LP64_OFF64") ::?
+ (Prim.SC_XBS5_LPBIG_OFFBIG,"XBS5_LPBIG_OFFBIG") ::?
+ (Prim.SC_XOPEN_CRYPT,"XOPEN_CRYPT") ::?
+ (Prim.SC_XOPEN_ENH_I18N,"XOPEN_ENH_I18N") ::?
+ (Prim.SC_XOPEN_LEGACY,"XOPEN_LEGACY") ::?
+ (Prim.SC_XOPEN_REALTIME,"XOPEN_REALTIME") ::?
+ (Prim.SC_XOPEN_REALTIME_THREADS,"XOPEN_REALTIME_THREADS") ::?
+ (Prim.SC_XOPEN_SHM,"XOPEN_SHM") ::?
+ (Prim.SC_XOPEN_STREAMS,"XOPEN_STREAMS") ::?
+ (Prim.SC_XOPEN_UNIX,"XOPEN_UNIX") ::?
+ (Prim.SC_XOPEN_VERSION,"XOPEN_VERSION") ::?
+ []
+ end
in
fun sysconf s =
case List.find (fn (_, s') => s = s') sysconfNames of
Modified: mlton/branches/on-20050822-x86_64-branch/basis-library/primitive/basis-ffi.sml
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/basis-library/primitive/basis-ffi.sml 2006-05-08 22:05:37 UTC (rev 4492)
+++ mlton/branches/on-20050822-x86_64-branch/basis-library/primitive/basis-ffi.sml 2006-05-09 01:00:56 UTC (rev 4493)
@@ -415,6 +415,7 @@
val REC_XFER_ALIGN = _const "Posix_FileSys_PC_REC_XFER_ALIGN" : C_Int.t;
val SYMLINK_MAX = _const "Posix_FileSys_PC_SYMLINK_MAX" : C_Int.t;
val SYNC_IO = _const "Posix_FileSys_PC_SYNC_IO" : C_Int.t;
+val TWO_SYMLINKS = _const "Posix_FileSys_PC_TWO_SYMLINKS" : C_Int.t;
val VDISABLE = _const "Posix_FileSys_PC_VDISABLE" : C_Int.t;
end
val readlink = _import "Posix_FileSys_readlink" : NullString8.t * (Char8.t) array * C_Size.t -> (C_SSize.t) C_Errno.t;
@@ -596,6 +597,7 @@
val SC_GETPW_R_SIZE_MAX = _const "Posix_ProcEnv_SC_GETPW_R_SIZE_MAX" : C_Int.t;
val SC_HOST_NAME_MAX = _const "Posix_ProcEnv_SC_HOST_NAME_MAX" : C_Int.t;
val SC_IOV_MAX = _const "Posix_ProcEnv_SC_IOV_MAX" : C_Int.t;
+val SC_IPV6 = _const "Posix_ProcEnv_SC_IPV6" : C_Int.t;
val SC_JOB_CONTROL = _const "Posix_ProcEnv_SC_JOB_CONTROL" : C_Int.t;
val SC_LINE_MAX = _const "Posix_ProcEnv_SC_LINE_MAX" : C_Int.t;
val SC_LOGIN_NAME_MAX = _const "Posix_ProcEnv_SC_LOGIN_NAME_MAX" : C_Int.t;
@@ -613,6 +615,7 @@
val SC_PAGESIZE = _const "Posix_ProcEnv_SC_PAGESIZE" : C_Int.t;
val SC_PRIORITIZED_IO = _const "Posix_ProcEnv_SC_PRIORITIZED_IO" : C_Int.t;
val SC_PRIORITY_SCHEDULING = _const "Posix_ProcEnv_SC_PRIORITY_SCHEDULING" : C_Int.t;
+val SC_RAW_SOCKETS = _const "Posix_ProcEnv_SC_RAW_SOCKETS" : C_Int.t;
val SC_RE_DUP_MAX = _const "Posix_ProcEnv_SC_RE_DUP_MAX" : C_Int.t;
val SC_READER_WRITER_LOCKS = _const "Posix_ProcEnv_SC_READER_WRITER_LOCKS" : C_Int.t;
val SC_REALTIME_SIGNALS = _const "Posix_ProcEnv_SC_REALTIME_SIGNALS" : C_Int.t;
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/Posix/FileSys/FileSys-consts.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/Posix/FileSys/FileSys-consts.c 2006-05-08 22:05:37 UTC (rev 4492)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/Posix/FileSys/FileSys-consts.c 2006-05-09 01:00:56 UTC (rev 4493)
@@ -60,7 +60,10 @@
#define _PC_PIPE_BUF -1
#endif
const C_Int_t Posix_FileSys_PC_PIPE_BUF = _PC_PIPE_BUF;
-// const C_Int_t Posix_FileSys_PC_2_SYMLINKS = _PC_2_SYMLINKS;
+#ifndef _PC_2_SYMLINKS
+#define _PC_2_SYMLINKS -1
+#endif
+const C_Int_t Posix_FileSys_PC_TWO_SYMLINKS = _PC_2_SYMLINKS;
#ifndef _PC_ALLOC_SIZE_MIN
#define _PC_ALLOC_SIZE_MIN -1
#endif
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/Posix/ProcEnv/sysconf-consts.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/Posix/ProcEnv/sysconf-consts.c 2006-05-08 22:05:37 UTC (rev 4492)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/Posix/ProcEnv/sysconf-consts.c 2006-05-09 01:00:56 UTC (rev 4493)
@@ -120,7 +120,10 @@
#define _SC_FSYNC -1
#endif
const C_Int_t Posix_ProcEnv_SC_FSYNC = _SC_FSYNC;
-// const C_Int_t Posix_ProcEnv_SC_IPV6 = _SC_IPV6;
+#ifndef _SC_IPV6
+#define _SC_IPV6 -1
+#endif
+const C_Int_t Posix_ProcEnv_SC_IPV6 = _SC_IPV6;
#ifndef _SC_JOB_CONTROL
#define _SC_JOB_CONTROL -1
#endif
@@ -157,7 +160,10 @@
#define _SC_PRIORITY_SCHEDULING -1
#endif
const C_Int_t Posix_ProcEnv_SC_PRIORITY_SCHEDULING = _SC_PRIORITY_SCHEDULING;
-// const C_Int_t Posix_ProcEnv_SC_RAW_SOCKETS = _SC_RAW_SOCKETS;
+#ifndef _SC_RAW_SOCKETS
+#define _SC_RAW_SOCKETS -1
+#endif
+const C_Int_t Posix_ProcEnv_SC_RAW_SOCKETS = _SC_RAW_SOCKETS;
#ifndef _SC_READER_WRITER_LOCKS
#define _SC_READER_WRITER_LOCKS -1
#endif
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/gen/basis-ffi.def
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/gen/basis-ffi.def 2006-05-08 22:05:37 UTC (rev 4492)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/gen/basis-ffi.def 2006-05-09 01:00:56 UTC (rev 4493)
@@ -277,7 +277,6 @@
Posix.FileSys.O.TEXT = _const : C_Int.t
Posix.FileSys.O.TRUNC = _const : C_Int.t
Posix.FileSys.O.WRONLY = _const : C_Int.t
-# Posix.FileSys.PC.2_SYMLINKS = _const : C_Int.t
Posix.FileSys.PC.ALLOC_SIZE_MIN = _const : C_Int.t
Posix.FileSys.PC.ASYNC_IO = _const : C_Int.t
Posix.FileSys.PC.CHOWN_RESTRICTED = _const : C_Int.t
@@ -296,6 +295,7 @@
Posix.FileSys.PC.REC_XFER_ALIGN = _const : C_Int.t
Posix.FileSys.PC.SYMLINK_MAX = _const : C_Int.t
Posix.FileSys.PC.SYNC_IO = _const : C_Int.t
+Posix.FileSys.PC.TWO_SYMLINKS = _const : C_Int.t
Posix.FileSys.PC.VDISABLE = _const : C_Int.t
Posix.FileSys.S.IFBLK = _const : C_Mode.t
Posix.FileSys.S.IFCHR = _const : C_Mode.t
@@ -456,7 +456,7 @@
Posix.ProcEnv.SC_GETPW_R_SIZE_MAX = _const : C_Int.t
Posix.ProcEnv.SC_HOST_NAME_MAX = _const : C_Int.t
Posix.ProcEnv.SC_IOV_MAX = _const : C_Int.t
-# Posix.ProcEnv.SC_IPV6 = _const : C_Int.t
+Posix.ProcEnv.SC_IPV6 = _const : C_Int.t
Posix.ProcEnv.SC_JOB_CONTROL = _const : C_Int.t
Posix.ProcEnv.SC_LINE_MAX = _const : C_Int.t
Posix.ProcEnv.SC_LOGIN_NAME_MAX = _const : C_Int.t
@@ -474,7 +474,7 @@
Posix.ProcEnv.SC_PAGE_SIZE = _const : C_Int.t
Posix.ProcEnv.SC_PRIORITIZED_IO = _const : C_Int.t
Posix.ProcEnv.SC_PRIORITY_SCHEDULING = _const : C_Int.t
-# Posix.ProcEnv.SC_RAW_SOCKETS = _const : C_Int.t
+Posix.ProcEnv.SC_RAW_SOCKETS = _const : C_Int.t
Posix.ProcEnv.SC_READER_WRITER_LOCKS = _const : C_Int.t
Posix.ProcEnv.SC_REALTIME_SIGNALS = _const : C_Int.t
Posix.ProcEnv.SC_REGEXP = _const : C_Int.t
|
|
From: Stephen W. <sw...@ml...> - 2006-05-08 15:05:38
|
Moved the stuff that moves files from the runtime to the basis-library out of the runtime/Makefile and into the main Makefile. It seems to be how we generally handle cross-project things. ---------------------------------------------------------------------- U mlton/branches/on-20050822-x86_64-branch/Makefile U mlton/branches/on-20050822-x86_64-branch/runtime/Makefile ---------------------------------------------------------------------- Modified: mlton/branches/on-20050822-x86_64-branch/Makefile =================================================================== --- mlton/branches/on-20050822-x86_64-branch/Makefile 2006-05-08 20:32:59 UTC (rev 4491) +++ mlton/branches/on-20050822-x86_64-branch/Makefile 2006-05-08 22:05:37 UTC (rev 4492) @@ -282,6 +282,10 @@ $(MAKE) -C runtime $(CP) include/*.h $(INC)/ $(CP) runtime/*.a $(LIB)/$(TARGET)/ + mv runtime/gen/c-types.sml \ + basis-library/config/c/$(TARGET_ARCH)-$(TARGET_OS)/c-types.sml + mv runtime/gen/basis-ffi.sml \ + basis-library/primitive/basis-ffi.sml mkdir -p $(INC)/gc mkdir -p $(INC)/util mkdir -p $(INC)/platform Modified: mlton/branches/on-20050822-x86_64-branch/runtime/Makefile =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/Makefile 2006-05-08 20:32:59 UTC (rev 4491) +++ mlton/branches/on-20050822-x86_64-branch/runtime/Makefile 2006-05-08 22:05:37 UTC (rev 4492) @@ -211,18 +211,16 @@ rm -f c-types.h ml-types.h $(CC) $(OPTCFLAGS) $(WARNCFLAGS) -o gen/gen-types gen/gen-types.c $(UTILOFILES) cd gen && ./gen-types - cp gen/c-types.h c-types.h - cp gen/c-types.sml ../basis-library/config/c/$(TARGET_ARCH)-$(TARGET_OS)/c-types.sml - cp gen/ml-types.h ml-types.h - rm -f gen/gen-types gen/c-types.h gen/c-types.sml gen/ml-types.h + mv gen/c-types.h c-types.h + mv gen/ml-types.h ml-types.h + rm -f gen/gen-types basis-ffi.h: gen/gen-basis-ffi.sml gen/basis-ffi.def rm -f basis-ffi.h cd gen && mlton gen-basis-ffi.sml cd gen && ./gen-basis-ffi - cp gen/basis-ffi.h basis-ffi.h - cp gen/basis-ffi.sml ../basis-library/primitive/basis-ffi.sml - rm -f gen/gen-basis-ffi gen/basis-ffi.h gen/basis-ffi.sml + mv gen/basis-ffi.h basis-ffi.h + rm -f gen/gen-basis-ffi gc-gdb.o: gc.c $(GCCFILES) $(HFILES) $(CC) $(DEBUGCFLAGS) $(DEBUGWARNCFLAGS) -c -o $@ $< |
|
From: Stephen W. <sw...@ml...> - 2006-05-08 13:32:59
|
Added inttypes.h. ---------------------------------------------------------------------- U mlton/branches/on-20050822-x86_64-branch/runtime/platform/hpux.h ---------------------------------------------------------------------- Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/hpux.h =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/platform/hpux.h 2006-05-08 20:29:55 UTC (rev 4490) +++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/hpux.h 2006-05-08 20:32:59 UTC (rev 4491) @@ -2,6 +2,7 @@ #define _XOPEN_SOURCE_EXTENDED #endif +#include <inttypes.h> #include <math.h> #include <signal.h> #include <sys/ptrace.h> |
|
From: Stephen W. <sw...@ml...> - 2006-05-08 13:29:56
|
Moved n-way OS #ifdef from platform.h to cenv.h. ---------------------------------------------------------------------- U mlton/branches/on-20050822-x86_64-branch/runtime/cenv.h U mlton/branches/on-20050822-x86_64-branch/runtime/platform.h ---------------------------------------------------------------------- Modified: mlton/branches/on-20050822-x86_64-branch/runtime/cenv.h =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/cenv.h 2006-05-08 05:19:09 UTC (rev 4489) +++ mlton/branches/on-20050822-x86_64-branch/runtime/cenv.h 2006-05-08 20:29:55 UTC (rev 4490) @@ -38,13 +38,8 @@ #include <stdarg.h> #include <stdbool.h> #include <stddef.h> -#if (defined(__hpux__) || defined (__OpenBSD__)) -#include <inttypes.h> -#elif (defined (__sun__)) -#include <sys/int_types.h> -#else -#include <stdint.h> -#endif +// stdint.h (or approximate equivalent) comes from the n-way OS switch below. +// #include <stdint.h> #include <stdio.h> #include <stdlib.h> #include <string.h> @@ -71,10 +66,33 @@ #include <sys/stat.h> #include <sys/time.h> -#if (defined (__sun__)) -#include <sys/socket.h> +#include "gmp.h" + + +#if (defined (__APPLE_CC__)) +#define __Darwin__ #endif -#include "gmp.h" +#if (defined (__CYGWIN__)) +#include "platform/cygwin.h" +#elif (defined (__Darwin__)) +#include "platform/darwin.h" +#elif (defined (__FreeBSD__)) +#include "platform/freebsd.h" +#elif (defined (__hpux__)) +#include "platform/hpux.h" +#elif (defined (__linux__)) +#include "platform/linux.h" +#elif (defined (__MINGW32__)) +#include "platform/mingw.h" +#elif (defined (__NetBSD__)) +#include "platform/netbsd.h" +#elif (defined (__OpenBSD__)) +#include "platform/openbsd.h" +#elif (defined (__sun__)) +#include "platform/solaris.h" +#else +#error unknown platform +#endif #endif /* _MLTON_CENV_H_ */ Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform.h =================================================================== --- mlton/branches/on-20050822-x86_64-branch/runtime/platform.h 2006-05-08 05:19:09 UTC (rev 4489) +++ mlton/branches/on-20050822-x86_64-branch/runtime/platform.h 2006-05-08 20:29:55 UTC (rev 4490) @@ -13,32 +13,6 @@ #include "util.h" #include "gc.h" -#if (defined (__APPLE_CC__)) -#define __Darwin__ -#endif - -#if (defined (__CYGWIN__)) -#include "platform/cygwin.h" -#elif (defined (__Darwin__)) -#include "platform/darwin.h" -#elif (defined (__FreeBSD__)) -#include "platform/freebsd.h" -#elif (defined (__hpux__)) -#include "platform/hpux.h" -#elif (defined (__linux__)) -#include "platform/linux.h" -#elif (defined (__MINGW32__)) -#include "platform/mingw.h" -#elif (defined (__NetBSD__)) -#include "platform/netbsd.h" -#elif (defined (__OpenBSD__)) -#include "platform/openbsd.h" -#elif (defined (__sun__)) -#include "platform/solaris.h" -#else -#error unknown platform -#endif - #ifndef MLton_Platform_OS_host #error MLton_Platform_OS_host not defined #endif |
|
From: Stephen W. <sw...@ml...> - 2006-05-07 22:19:11
|
Changed reference to totalRam.sysconf.c into sysconf.c.
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c 2006-05-08 05:18:09 UTC (rev 4488)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/platform/solaris.c 2006-05-08 05:19:09 UTC (rev 4489)
@@ -6,7 +6,7 @@
#include "mkdir2.c"
#include "mmap.c"
#include "mmap-protect.c"
-#include "totalRam.sysconf.c"
+#include "sysconf.c"
#include "setenv.putenv.c"
static void catcher (int sig, siginfo_t *sip, ucontext_t *ucp) {
|