Commit Graph

36 Commits (char-rename)

Author SHA1 Message Date
Björn Lindqvist 0590ebf914 VM: storing some sample data in the heap (#337)
This is the first half of it. In the second half the samples array
should also be stored in the heap.
2016-11-23 09:44:17 +01:00
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 6984bae7ca VM: rename of JIT_PUSH_IMMEDIATE to JIT_PUSH_LITERAL
The code template pushes both immediates and references so the name was
wrong.
2016-06-07 14:54:23 +02:00
Björn Lindqvist 579875821b VM: removes the OBJ-ERROR special object in favor of a constant
The special object contained the string "kernel-error" which were used
to tag VM errors. But it is simplier and removes a little complexity to
just tag them with a fixnum constant.
2016-03-22 17:52:19 +01:00
Björn Lindqvist 44b9b26baa VM: nitpick fix of filenames in comments 2016-02-28 01:23:59 +01:00
Björn Lindqvist 08766090d3 VM: more fine-grained control over which special objects to save
It removes a few roots that doesn't need to be saved in the image and
can save a few hundred bytes.
2015-12-13 13:56:36 +01:00
Björn Lindqvist 339b1b6466 VM: put the singletons t, -1, 0 and 1 in the special objects table
Having them there instead of as fields in the vm struct removes a bunch
of special handling. This commit just adds them and doesn't remove the
old ones to avoid potential chicken-and-egg bootstrap problems.
2015-12-09 21:31:13 +01:00
Björn Lindqvist de4917e6a1 VM: give the exception handling special object a real name 2015-09-02 21:54:33 +02:00
Björn Lindqvist cee0b19324 VM: the ffi-signal-handler and ffi-leaf-signal-handler primitives are unused 2015-09-02 21:54:15 +02:00
Björn Lindqvist 9413f711b9 VM: the JIT_PROFILING special object is never used, so rename it to
JIT_UNUSED (removing it breaks boot images)
2015-08-14 20:19:53 -07:00
Björn Lindqvist fce5d4353a VM: replace binary_payload_start() with slot_count()
This should simplify a little the address calculations when visiting
slots of an object
2015-07-06 22:49:38 +02:00
Björn Lindqvist 990af22dc6 VM: renamed version and git-label to vm-version and vm-git-label. 2014-11-10 23:02:13 -08:00
Björn Lindqvist 090f4fddd5 VM: Three new special objects added to keep track of the builds version number, git label and compilation time respectively. The info is exposed in the system:version-info word and also shown in the banner during startup.
Conflicts:
	Nmakefile
	basis/ui/tools/listener/listener.factor
	core/alien/strings/strings.factor
2014-11-10 23:01:52 -08: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 228d813a7d VM: Refactor objects* 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 72d335f2b5 vm: write async signals to pipe for multiplexer
also factor out safepoint logic into its own file
2011-11-08 08:42:46 -08:00
Joe Groff d28845a1ef vm: reserve some more special-objects
Need a jit-safepoint object to deal with #332, and ffi-signal-handler words for immediate signal handling during FFI calls
2011-11-02 22:16:08 -07:00
Joe Groff 186bf65a00 constants for special object hardcoded literals 2011-11-02 12:54:50 -07:00
Joe Groff 1386212d23 vm: dispatch signal handlers through subprimitive
We also need to save C ABI volatile registers before calling the signal handler in order to be able to reliably resume. Add signal-handler and leaf-signal-handler subprimitives to preserve volatile registers before invoking the signal handler C function.
2011-10-27 21:18:18 -07:00
Slava Pestov c36d73e242 Change do-callback to register the current thread with the callback, instead of busy waiting for the current callback to become the right one before returning. Fixes 100% CPU usage issue with system-alert. Thanks to Blei and ex-rzr for doing preliminary analysis of the issue 2011-04-12 21:48:54 -04:00
Slava Pestov 1818bcb780 Fix three problems discovered by running math.floats.env tests in a loop:
- Crash if allocating error triggers a GC from a signal/SEH handler
- Crash if GC runs with floating point traps enabled on Windows
- Floating point traps didn't prettyprint properly
2010-09-02 22:57:14 -05:00
Slava Pestov bc87b269c5 Remove Cocoa exception handling support since it no longer works 2010-07-06 17:48:37 -04:00
Slava Pestov fb2ecab614 threads: delete old contexts immediately instead of handing them off to a 'context recycler' thread 2010-03-30 21:47:48 -04:00
Slava Pestov c7142e4281 threads: use context-switching primitives 2010-03-29 20:40:17 -04:00
Slava Pestov 6aee6b3adc Add context-specific special object table, generalizing catchstack_save and current_callback_save fields of context struct 2010-03-18 22:06:00 +13:00
Joe Groff ac979619e6 record the C++ compiler version in the VM, and expose it with a vm-compiler word 2010-03-01 13:32:07 -08:00
Slava Pestov 36d2ac8921 vm: move c_to_factor, lazy_jit_compile_impl, throw_impl, set_callstack assembly routines into non-optimizing compiler for x86-64 2010-01-06 15:47:36 +13:00
Slava Pestov 0068bce934 vm: big overhaul of non-optimizing compiler
- change some primitives into sub-primitives: fixnum+ fixnum- fixnum* inline-cache-miss inline-cache-miss-tail
- rename some relocation types for clarity
- some other minor re-organizations and cleanups
2009-12-15 07:20:09 -05:00
Slava Pestov 24c3ddbbde Clean up startup/shutdown hook code 2009-11-20 00:57:49 -06:00
Doug Coleman 51e21a6aa8 update vm for startup branch 2009-11-15 02:53:02 -06:00
Slava Pestov cba12eae37 Invalidate inline caches used by call( and execute( when words are redefined 2009-11-12 16:09:07 -06:00
Slava Pestov c2b3d6b894 vm: fix fencepost error in write barrier on large object allocation; fixes benchmark.sort crash 2009-11-11 19:31:18 -06:00
Slava Pestov 72ab6ec548 vm: rewrite 'become' primitive so that it uses a slot visitor instead of GC 2009-11-05 19:03:51 -06:00