Commit Graph

47 Commits (clean-windows-x86-64)

Author SHA1 Message Date
Alexander Iljin 0d57734dab vm: replace block comments /**/ with line comments // 2016-09-09 05:47:52 +02:00
Alexander Iljin e0acf4f328 Revert "vm: replace line comments // with block comments /**/ for consintency"
This reverts commit 7ee4e5dea5.
2016-09-09 05:47:52 +02:00
Alexander Iljin 7ee4e5dea5 vm: replace line comments // with block comments /**/ for consintency
Fix #1651.
2016-08-03 09:19:48 -07:00
Björn Lindqvist 4cc5e90605 VM: SNPRINTF macro is not used 2016-05-02 15:01:49 +02:00
Björn Lindqvist 2536b6cd93 VM: fix move_file called from save_image
save_image() shouldn't throw exceptions because if the 'then_die'
argument is t it would leave factor in an inconsistent state. So
therefore move_file() should be fixed and raw_fclose() called instead of
safe_fclose().
2015-09-29 23:13:10 +02:00
Doug Coleman 6244b925c7 vm: Simplify strerror code. 2014-07-05 18:58:24 -07:00
Doug Coleman 69262be4d8 vm: Add threadsafe_sterror to the vm. 2014-07-04 03:00:08 -07:00
Doug Coleman c3210f9f4f Windows: Add two new targets, x86-32-vista and x86-64-vista for bjourne's
ctrl-c patch. We still support Windows XP by default for now. Closes
2014-05-10 18:13:20 -07:00
Björn Lindqvist 0226718a82 VM: attempt to cancel blocking system calls when ctrl-c is pressed
Windows runs ctrl-c in its own thread and doesn't by itself interrupt
blocking system calls when it is pressed. Therefore you have to manually
send an interrupt signal to the stuck thread.
2014-05-10 18:13:04 -07:00
Doug Coleman 268fa0225d os-windows: Remove FACTOR_DLL which is NULL and only used in one place. 2013-11-24 22:06:57 -06:00
Erik Charlebois ffe41b3d7f VM: Fixup cast formatting after clang-format
clang-format doesn't recognize casts to non-pointer/non-template types
so it winds up adding a space between the right paren and the expression
and then failing to recognize prefix operators in the process
(e.g. foo = (cell) & bar; should be foo = (cell)&bar;). This commit
manually fixes up the major cases (fixnum, cell, all types ending in _t).
2013-05-13 14:59:24 -04:00
Erik Charlebois 88d7c10d03 VM: Replace u8-64, s8-64, cell, fixnum with stdint.h equivalents 2013-05-13 00:28:25 -04:00
Erik Charlebois 37b15012e6 VM: Refactor os-* to Factor style 2013-05-12 13:24:46 -04:00
Erik Charlebois ca2ea548be VM: Remove exec bit from VM source files 2013-05-11 17:04:23 -04:00
Joe Groff 0a1a252cdb vm: replace assert with FACTOR_ASSERT
Factor is finally a real C++ project and has a custom assert macro. Assertion failures were still getting caught as exceptions and causing failure loops. Write our own macro that calls factor::abort on failure.
2011-11-23 11:11:26 -08:00
Joe Groff 8e7baef1a0 vm: typo in os-windows.hpp 2011-11-12 19:23:44 -08:00
Joe Groff e24400679f vm: more defense against multi-faulting
* Clear faulting_p from a safepoint rather than inside general_error, because jumping into unwind-native-frames could blow up.
* Handle multiple faults from fatal_error by breakpointing. Is there anything else we can safely do at that point?
* Verify memory protection faults in the top half of the signal handlers because signal dispatch could fault. Treat memory faults during gc or fep as fatal errors.
* Add a function factor_vm::abort() that restores the default SIGABRT handler and ::abort()s. Use it from fatal_error() so we get useful context from gdb and so the user gets feedback from the system crash reporter that Factor blew up and didn't just disappear.
* In factorbug(), don't proceed with .s .r .c if it would be unsafe to do so.
* Don't pile on signals if we've already called fatal_error().
2011-11-12 13:02:57 -08:00
Joe Groff 9541bf14f5 vm: win32 GetCurrentThread is a fake thread handle
Open a real thread handle with the necessary permissions to dispatch a handler from the the Ctrl-C handler thread.
2011-10-27 21:18:21 -07:00
Doug Coleman bf2a96e9e0 Remove Windows CE from core/ basis/ and build-support/
Rename the winnt singleton to windows in core/ basis/ extra/
Rename boot images winnt -> windows
Fixes #84.
2011-09-18 23:19:06 -05:00
Erik Charlebois 64252dbdbc 32 and 64 bit Linux PPC support 2011-05-23 23:36:14 -04:00
Doug Coleman f791c8c5d2 Squashed commit of the following:
commit 197dbe9a6733775ac0ea19b3da4bd4dc3c85418c
Author: Doug Coleman <doug.coleman@gmail.com>
Date:   Sat Sep 18 19:01:38 2010 -0500

    Fix bootstrap, move privileges to windows.privileges

commit 521c622f8afb15bf42d263c738cb990560dc29cb
Author: Doug Coleman <doug.coleman@gmail.com>
Date:   Sat Sep 18 18:26:30 2010 -0500

    Hopefully fix bootstrap

commit eb3f22928b59758b9505430034044b5b94705da2
Author: Doug Coleman <doug.coleman@gmail.com>
Date:   Sat Sep 18 18:19:05 2010 -0500

    Remove wince from factor codebase

commit 619d6c99415f46208a7ede6a04b0ccda46b15360
Author: Doug Coleman <doug.coleman@gmail.com>
Date:   Sat Sep 18 16:07:46 2010 -0500

    Remove Windows CE from vm/
2010-09-19 19:13:25 -05:00
Joe Groff 14de58b73c vm: remove some mixed use of stdio/iostream. when monotonic timer decreases, log old and new values 2010-08-01 16:14:20 -07:00
Doug Coleman e8d528ad93 Remove system_micros from vm, implement gmt hook on windows 2010-06-16 23:39:16 -05:00
Slava Pestov 9ffe0a69d1 vm: use sigaltstack to handle callstack overflow properly 2010-03-28 11:37:28 -04:00
Doug Coleman 950eaed73a Change the MOVE_FILE macro to a function named move_file 2010-02-03 15:12:13 -06:00
Doug Coleman 40cf302d2d Fix image save on Windows 2010-01-22 12:59:36 -06:00
Doug Coleman bb2f455747 Save images to a temporary file first, then call MOVE_FILE to avoid writing incomplete and truncated images. 2010-01-22 12:59:20 -06:00
Slava Pestov d36b83d6a9 Use ParseCommandLineArgvw() on Windows again, instead of hand-rolled parser. Update Nmakefile to link in shell32.dll, where this function is defined 2010-01-18 06:12:04 -06:00
Slava Pestov e4da687413 vm: Tweak Factor VM to compile with Microsoft Visual Studio on Windows, in addition to Mingw. Add an Nmakefile which can be used for this purpose. Rename Makefile to GNUmakefile. 2010-01-17 03:43:22 +13:00
Slava Pestov 2922e08ed9 vm: rework platform.hpp so that it is no longer necessary to pass -DFACTOR_64 and -DWINDOWS when compiling VM 2010-01-13 23:06:45 +13:00
Slava Pestov 0fd3c78157 vm: remove some unused #defines 2010-01-07 21:33:19 +13:00
Doug Coleman bce084ac12 fix windows compile error 2009-11-20 04:21:21 -06:00
Doug Coleman 6f7ec206a1 rename millis to system-millis, micros to system-micros, add nano-count 2009-11-18 15:58:48 -06:00
Doug Coleman 60d8ef22b8 fix current_nanos on windows 2009-11-18 11:04:46 -06:00
Slava Pestov 40351d40be vm: use iostreams instead of printf for debug messages, clean up a few things 2009-10-21 20:12:57 -05:00
Doug Coleman 77860bc95d let's work with cygwin here..._ftelli64 -> ftello64 on cygwin. fine i guess 2009-10-04 06:10:57 -05:00
Doug Coleman 11d55131de add ftell primitive 2009-10-03 18:20:35 -05:00
Slava Pestov 6578bd0533 vm: fix windows compilation (untested) 2009-09-26 02:41:01 -05:00
Phil Dawes e566656e46 removed a bunch of superflous blank lines 2009-09-24 08:02:14 +01:00
Phil Dawes 7cebe088a1 moved some os-windows functions into the vm 2009-09-16 08:16:29 +01:00
Philipp Brüschweiler 230061783a misc small documentation fixes, some fixes for factor.vim, changed permissions of vm/* to 644 2009-08-10 21:33:07 +02:00
Slava Pestov 9ef162e2ef More VM cleanups 2009-05-13 01:08:16 -05:00
Slava Pestov 53db9d737a Change (void) to () 2009-05-05 11:33:35 -05:00
Slava Pestov 8872c40b1e The great type renaming 2009-05-04 04:50:24 -05:00
Slava Pestov edecac508e Use C++ namespaces 2009-05-04 01:46:13 -05:00
Slava Pestov 8e17e0a01e VM: use better abstractions for tagged pointers, eliminate get()/set() stuff, clean up array, string, and byte-array element access 2009-05-04 01:00:30 -05:00
Slava Pestov b923d548cf Move vmpp to vm 2009-05-02 20:37:18 -05:00