[MLton-commit] r5884
Matthew Fluet
fluet at mlton.org
Wed Aug 15 11:24:56 PDT 2007
Catching up with runtime changes; untested
----------------------------------------------------------------------
U mlton/trunk/runtime/platform/mingw.c
----------------------------------------------------------------------
Modified: mlton/trunk/runtime/platform/mingw.c
===================================================================
--- mlton/trunk/runtime/platform/mingw.c 2007-08-15 15:33:44 UTC (rev 5883)
+++ mlton/trunk/runtime/platform/mingw.c 2007-08-15 18:24:55 UTC (rev 5884)
@@ -17,14 +17,20 @@
Windows_release (base);
}
-Word32 GC_totalRam (void) {
- MEMORYSTATUS memStat;
+uintmax_t GC_physMem (void) {
+ MEMORYSTATUS memstat;
- memStat.dwLength = sizeof(memStat);
- GlobalMemoryStatus(&memStat);
- return memStat.dwTotalPhys;
+ memstat.dwLength = sizeof(memstat);
+ GlobalMemoryStatus(&memstat);
+ return (uintmax_t)memstat.dwTotalPhys;
}
+size_t GC_pageSize (void) {
+ SYSTEM_INFO sysinfo;
+ GetSystemInfo(&sysinfo);
+ return (size_t)sysinfo.dwPageSize;
+}
+
HANDLE fileDesHandle (int fd) {
// The temporary prevents a "cast does not match function type" warning.
long t;
@@ -33,12 +39,6 @@
return (HANDLE)t;
}
-size_t GC_pageSize (void) {
- SYSTEM_INFO sysinfo;
- GetSystemInfo(&sysinfo);
- return sysinfo.dwPageSize;
-}
-
int mkstemp (char *template) {
char file_path[255];
char file_name[255];
More information about the MLton-commit
mailing list