Björn Lindqvist
e9cd20604c
VM: factor_vm::compile_inline_cache() can be removed
2016-10-31 16:16:42 +01:00
Björn Lindqvist
51408b66cb
VM: the jit class doesn't need to store the code block type
2016-10-19 09:28:59 +02:00
Björn Lindqvist
453eca66c4
VM: changing case of code_block_type
2016-10-19 09:14:58 +02:00
Alexander Iljin
0d57734dab
vm: replace block comments /**/ with line comments //
2016-09-09 05:47:52 +02:00
Björn Lindqvist
0a5f1689e1
VM: init_inline_caching is not needed
2016-08-19 02:58:19 +02:00
Björn Lindqvist
a58f8c76f4
VM: rename compile_inline_cache and refactor the loop body into emit_check_and_jump
2016-05-31 03:37:24 +02:00
Björn Lindqvist
dae2229957
VM: omit the type check if checking for fixnum and it's the first check
...
Previously: and ecx, 0xf ; cmp ecx, 0 ; jz <address> was generated. Now
instead: and ecx, 0xf ; jz <address> because the cmp, ecx, 0 instruction
is redundant.
2016-05-31 03:37:24 +02:00
Björn Lindqvist
3b016bc254
VM: a bunch of more methods on the factor_vm class that can be made into funtions
2016-05-30 07:44:26 +02:00
Björn Lindqvist
4509371f7c
VM: shorter definition of emit_check
2016-05-29 04:55:11 +02:00
Björn Lindqvist
2db1e7e6a5
VM: simplifies factor_vm::determine_inline_cache_type
2016-02-28 01:10:12 +01:00
Björn Lindqvist
9bfc43144e
VM: debug macros FACTOR_PRINT and FACTOR_PRINT_MARK to make better debug
...
printing messages than just using std::cout
2015-05-09 20:04:21 -07:00
Björn Lindqvist
fb9fa12cdd
VM: change the definition of entry_point in word and quotation from void* to cell
...
this gets rid of lots of redundant casts from void* to cell
2015-01-15 09:29:13 +00:00
Björn Lindqvist
423e983514
VM: refactoring to get rid of the megamorphic_call_stub and check_code_pointer() words
2014-12-04 10:23:33 -08:00
Doug Coleman
19685f4528
vm: jit::jit is a c++ constructor but it does not allocate objects to the Factor heaps.
...
Add annotations for gc allocating.
2014-02-14 20:29:26 -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
7b1b1eef23
VM: Remove unnecessary _ suffix in constructors
2013-05-12 23:20:43 -04:00
Erik Charlebois
26ff071205
VM: Remove unnecessary explicit keywords
2013-05-12 21:48:38 -04:00
Erik Charlebois
f6047832cb
VM: Refactor inline_cache.cpp/hpp to Factor style
2013-05-12 13:24:44 -04:00
Erik Charlebois
ca2ea548be
VM: Remove exec bit from VM source files
2013-05-11 17:04:23 -04:00
Joe Groff
7121e0d598
vm: also smoke-check callstack after pic update
2011-12-21 18:31:37 -08:00
Joe Groff
9f137c66d4
vm: fashion brigade
2011-12-21 13:25:05 -08:00
Joe Groff
442923b561
vm: walk stack on inline_cache_miss if PIC_DEBUG=1
...
Reveals inline cache stack coherency bug behind #460
2011-12-21 13:24:35 -08:00
Joe Groff
1911905c6b
vm: frame size for signal handler code blocks
2011-12-14 09:56:46 -08:00
Slava Pestov
1434a305c8
vm: add a new rc-absolute-1 relocation class to allow storing values in 8-bit operands, and optimized code sequences for inline caches using this
2010-04-12 14:22:41 -07:00
Slava Pestov
637a77c018
Stop wearing monocle and use the term "entry point" instead of "XT" throughout VM and compiler; also remove two unused relocation types
2010-01-18 20:54:00 +13:00
Slava Pestov
63edd20a55
vm: eliminating register variables work in progress. Works on x86-32 with non-optimizing compiler
2009-12-19 10:59:56 +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
066d2836ca
Get modify-code-heap working if stack traces are stripped (but then it won't update existing code blocks), and rename code_heap::code_heap_free() to code_heap::free()
2009-12-02 05:27:48 -06:00
Slava Pestov
68c09f0e93
Split literal table into literal and parameter tables, literal table is discarded after code block initialization
2009-12-02 04:28:15 -06:00
Slava Pestov
d49c86ba11
vm: Clean up more code duplication and rename a few methods
2009-12-02 01:17:30 -06:00
Slava Pestov
b09d6ef586
vm: deallocate old PIC after allocating the new one to avoid having the code heap potentially point to a free block during compaction
2009-11-24 21:20:23 -06:00
Slava Pestov
47df580081
tools.time: overhaul
2009-11-05 01:07:59 -06:00
Slava Pestov
ed3ab1335e
vm: minor fixes after code review
2009-11-03 04:56:58 -06:00
Slava Pestov
6c2c87758a
vm: rename gc_root to data_root, add code_root to fix a problem where code blocks would move underneath the PIC compiler if PIC compiler allocated enough
2009-11-02 18:10:34 -06:00
Slava Pestov
e4ad642134
vm: 4 bit tags, new representation of alien objects makes unbox-any-c-ptr more efficient (work in progress)
2009-11-02 04:25:54 -06:00
Slava Pestov
810e309e0c
vm: rename userenv to special_objects
2009-10-23 00:33:53 -05: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
Slava Pestov
838a44e901
vm: change code heap layout somewhat, remove unused allocation bitmap from mark_bits
2009-10-20 09:37:24 -05:00
Slava Pestov
2e65366c6b
vm: rename myvm and parent_vm instance variables to parent, clean up casts in primitive definitions
2009-10-18 20:31:59 -05:00
Phil Dawes
7fef05fd76
Removed VM_PTR macros. All builds reentrant by default
2009-10-14 19:14:57 +01:00
Slava Pestov
16c3251072
vm: free up a cell in compiled code block headers
2009-10-06 05:52:45 -05:00
Slava Pestov
ed1ee19ce1
vm: add a remembered set for code blocks which may reference young literals. Improves loading time
2009-10-06 04:36:34 -05:00
Slava Pestov
47c735d81d
vm: more GC refactoring
2009-10-06 00:13:54 -05:00
Slava Pestov
c4ef640f4d
Big VM cleanup
...
- Move forward declarations of 'struct factor_vm' to one place
- Rename template parameters from T and TYPE to descriptive names. New convention: CamelCase for template parameters
- Change some higher-order functions taking function pointers into templates, and define classes overriding operator(). There's a bit of new boilerplate here but its more consistent than the old mish-mash approaches
- Put GC state into a gc_state struct
- Use exceptions instead of longjmp for non-local control transfer in GC
- In code GC, instead of interleaving code block tracing with copying, add code blocks which need to be revisited to an std::set stored in the gc_state
2009-10-03 08:47:05 -05:00
Phil Dawes
9b7412b8f8
Moved PRIMITIVE and PRIMITIVE_FORWARDs to primitives.[ch]pp
2009-09-27 19:42:18 +01:00
Slava Pestov
c046ff4b23
vm: make heap data-type object-oriented
2009-09-25 20:32:00 -05:00
Phil Dawes
6b7717bf37
forwarding functions replaced with PRIMITIVE_FORWARD() macro
2009-09-25 20:43:01 +01:00
Phil Dawes
57840562f5
renamed myvm member variable to parent_vm
2009-09-24 08:16:57 +01:00
Phil Dawes
83b0769eef
renamed factorvm to factor_vm
2009-09-24 08:16:52 +01:00
Phil Dawes
e566656e46
removed a bunch of superflous blank lines
2009-09-24 08:02:14 +01:00