]> gitweb.factorcode.org Git - factor.git/commitdiff
Merge branch 'master' of git://factorcode.org/git/factor
authorSlava Pestov <slava@slava-pestovs-macbook-pro.local>
Mon, 15 Dec 2008 09:47:23 +0000 (03:47 -0600)
committerSlava Pestov <slava@slava-pestovs-macbook-pro.local>
Mon, 15 Dec 2008 09:47:23 +0000 (03:47 -0600)
basis/io/backend/windows/nt/nt.factor
vm/os-windows.c
vm/os-windows.h

index e41293b6ded590a898c30262f457b3d0a123d26f..bb8175b35c5ab8f34e827b8f2a70b7732da01651 100755 (executable)
@@ -118,3 +118,5 @@ M: winnt (wait-to-read) ( port -- )
     ] with-destructors ;
 
 M: winnt (init-stdio) init-c-stdio ;
+
+winnt set-io-backend
index ee2c7211119e59212abdd3104bcc12ce15a3a8ac..c3e9e50cee7ce0ab164f392ca4ac1b28d9358f16 100755 (executable)
@@ -166,7 +166,7 @@ long getpagesize(void)
        return g_pagesize;
 }
 
-void sleep_micros(DWORD usec)
+void sleep_micros(u64 usec)
 {
-       Sleep(usec);
+       Sleep((DWORD)(usec / 1000));
 }
index af9b75bca5c931d1028c629ac666eb113c227b29..227d44af77261f863c61dd95d6700542942b2cb6 100755 (executable)
@@ -20,17 +20,18 @@ typedef wchar_t F_CHAR;
 #define STRNCMP wcsncmp
 #define STRDUP _wcsdup
 
-#define FIXNUM_FORMAT "%Id"
 #define CELL_FORMAT "%lu"
-#define CELL_HEX_FORMAT "%Ix"
 
 #ifdef WIN64
+        #define CELL_HEX_FORMAT "%Ix"
        #define CELL_HEX_PAD_FORMAT "%016Ix"
+        #define FIXNUM_FORMAT "%Id"
 #else
+        #define CELL_HEX_FORMAT "%lx"
        #define CELL_HEX_PAD_FORMAT "%08lx"
+        #define FIXNUM_FORMAT "%ld"
 #endif
 
-#define FIXNUM_FORMAT "%Id"
 
 #define OPEN_READ(path) _wfopen(path,L"rb")
 #define OPEN_WRITE(path) _wfopen(path,L"wb")
@@ -49,7 +50,7 @@ void ffi_dlopen(F_DLL *dll);
 void *ffi_dlsym(F_DLL *dll, F_SYMBOL *symbol);
 void ffi_dlclose(F_DLL *dll);
 
-void sleep_micros(DWORD msec);
+void sleep_micros(u64 msec);
 
 INLINE void init_signals(void) {}
 INLINE void early_init(void) {}