Commit Graph

429 Commits (2f6f69eb5b9764228e6030e0d704f076b64969bf)

Author SHA1 Message Date
Björn Lindqvist 2f6f69eb5b VM: trying to simplify record_sample and the profiling_sample constructor 2016-08-15 15:16:41 +02:00
Alexander Iljin 7ee4e5dea5 vm: replace line comments // with block comments /**/ for consintency
Fix .
2016-08-03 09:19:48 -07:00
Björn Lindqvist 801c70e9da VM: removes the signal_handler_impl methods from factor_vm
Instead the code is in the functions with the same name. That way, they
don't need to exist both as functions and methods.
2016-06-29 18:27:26 +02:00
Björn Lindqvist a331ad3788 VM: factor_vm::set_callstack and set_retainstack is not needed 2016-06-27 16:08:58 +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 b027285b48 VM: makes some factor_vm methods to free functions 2016-05-29 03:03:07 +02:00
Björn Lindqvist 63791bf90e VM: move some logic from factor_vm to the vm_parameters class
It's good because the factor_vm class is to fat.
2016-05-14 18:21:49 +02:00
Björn Lindqvist 340ad8b8d9 VM: removes the delete_contexts method 2016-05-14 18:21:49 +02:00
Björn Lindqvist 9824be8714 VM: The C++11 method shrink_to_fit() can be used to release memory 2016-05-05 14:22:57 +02:00
Björn Lindqvist 5826394573 VM: the (clear-samples) primitive is unused 2016-05-05 02:33:35 +02:00
Björn Lindqvist 2035eb91fe VM: method compute_identity_hashcode is not needed 2016-05-02 14:05:01 +02:00
Björn Lindqvist eb8b7f02bf VM: the start_factor method isn't needed 2016-05-01 23:36:41 +02:00
Björn Lindqvist c55af9b957 VM: object_size, compute_entry_point_address, code_block_owner made into
functions

It is to make the vm class less heavy
2016-04-24 14:45:03 +02:00
Björn Lindqvist 28b5378196 VM: merge of fixup_data & fixup_code into a new method fixup_heaps 2016-04-24 12:42:22 +02:00
Björn Lindqvist c8d648f3f2 VM: the factor_vm::code_blocks() method isn't needed 2016-04-22 12:01:26 +02:00
Björn Lindqvist da4812ba21 VM: refactoring which removes two not useful short methods 2016-04-04 23:32:23 +02:00
Doug Coleman b324c30cc7 vm: Fix four compile warnings reported by gcc with -pedantic flag. 2016-03-30 15:39:42 -07:00
Björn Lindqvist 7da72ac77c VM: the compute_vm_address method can be removed 2015-12-13 13:56:36 +01:00
Björn Lindqvist 1a72f731e0 VM: now special-objects is used for -1, 0, 1 and t
The fields in the image_header aren't read or written to but I haven't
changed the format yet.
2015-12-10 10:22:38 +01:00
Björn Lindqvist d911bc45fd VM: refactors the prepare_boot_image method
easier to read if the methods compile_all_words and
initialize_all_quotations which are only used once are "inlined"
2015-12-04 13:57:57 +01:00
Björn Lindqvist 867c85f1c5 VM: can't go through the accessor here because it triggers the assert 2015-11-25 18:12:55 +01:00
Björn Lindqvist 0274e889b9 VM: refactor tagged.hpp so it's not dependent on the factor_vm class
this way untag<byte_array>(relocation) can be used in code_blocks.hpp
2015-11-24 16:00:50 +01:00
Björn Lindqvist cb55fcf20f VM: prettier and more detailed output when dumping generations 2015-10-08 16:25:35 +02:00
John Benediktsson bd04290187 vm: fix signature for safe_fopen. 2015-09-30 19:03:39 -07: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
Björn Lindqvist cb0bf3b1ce VM: merge memory_protection_error() with memory_signal_handler_impl() 2015-08-24 07:23:40 -07:00
Björn Lindqvist 51daaf6be4 VM: the windows_image_path method is unused 2015-08-24 07:23:40 -07:00
Björn Lindqvist 4efef7bfd9 VM: merge the compute_dlsym_toc_address() with the
compute_dlsym_address() method

it makes the code slightly more cluttered but you get rid of a lot of
special casing for the ppc platform
2015-08-23 18:36:31 -07:00
Björn Lindqvist a53d5be683 VM: make allot_alien() and ffi_dlsym() use cell instead of void*
this way we get rid of a bunch of superfluous casts
2015-08-23 18:36:31 -07:00
Björn Lindqvist 7f545271f4 VM: new iteration method each_object_each_slot()
used by find_data_references() and dump_edges() instead of the functor structs
2015-08-23 18:36:31 -07:00
Björn Lindqvist 59b7a50567 VM: removing the get_datastack/retainstack/callstack primitives
they can all be implemented using the
datastack/retainstack/callstack-for primitives and the less primitives
the better!
2015-08-23 18:36:30 -07:00
Björn Lindqvist df669298ce VM: split dispatch_signal_handler into two methods, one for resumable
and one for non-resumable signals
2015-08-14 20:19:55 -07:00
Björn Lindqvist 2b1c6ca11a VM: move the frame_predecessor() method to the code_heap class 2015-08-14 20:19:54 -07:00
Björn Lindqvist 504be0c7cb VM: signal_error and fp_trap_error not needed, call general_error directly 2015-08-04 16:02:10 +02:00
Björn Lindqvist 73956db33a VM: a bunch of methods on factor_vm that can be converted into free
functions

I think that makes it easier to see whats going on than having
everything added to factor_vm
2015-08-04 16:02:09 +02:00
Björn Lindqvist ae725b737a VM: lets merge entry_points.hpp with vm.hpp, so you have one less header
file to worry about
2015-08-04 16:02:09 +02:00
Björn Lindqvist f5f8ce1501 VM: word_stack_frame_p() is not used and find_all_quotations() is
trivial so those methods can be removed
2015-08-04 16:02:09 +02:00
Björn Lindqvist 49a406d880 VM: using compute_external_address everywhere instead of store_external_address 2015-08-04 16:02:09 +02:00
Björn Lindqvist 50318a6f77 VM: new method compute_external_address 2015-08-04 16:02:08 +02:00
Björn Lindqvist 718ea51d8a VM: remove the collect_compact_code_impl(), collect_compact_impl() can
be used instead

this might slow down collect_growing_heap(), but heap growth happens so
rarely that it shouldn't matter
2015-08-04 16:02:08 +02:00
Björn Lindqvist b44db91f65 VM: init_code_heap is trivial and only used once, so let's remove it 2015-08-04 16:02:08 +02:00
John Benediktsson 4c2c8f133f vm: rename some primitives, and some cleanup.
* quot-compiled? => quotation-compiled?
* optimized? => word-optimized?
2015-07-15 11:13:52 -07:00
Björn Lindqvist b9b75c272b VM: let's merge (save-image) and (save-image-and-exit) into one 3
arg (save-image). it's good not to have to many similar primitives
2015-07-12 22:36:59 +02:00
Björn Lindqvist d608f3377b VM: get_entry_point is unused 2015-07-12 22:36:59 +02:00
Björn Lindqvist e14d7a3508 VM: make the bignum_to_* family free functions, they don't need to be
members of factor_vm
2015-06-27 16:14:58 +02:00
Björn Lindqvist 40b7805e0a VM: fixes so that raw_fread and safe_fread returns a size_t again 2015-06-05 02:14:49 +02:00
Björn Lindqvist 0713f28bdb VM: safe_fread needs to return an int so you can return -1 on error 2015-06-05 02:14:49 +02:00
Doug Coleman 27590b514c vm: Only call fclose() once. Rename io_error() to io_error_if_not_EINTR() to be more explicit.
Fixes .
2015-06-03 14:35:48 -07:00
Björn Lindqvist 016614747d VM: the delete_context() and reset_context() api functions can be
simplified a bit

The functions always operates on parent->ctx, so passing a context*
parameter is redundant. This enables shorter assembly code for
the (start-context-and-delete) and (set-context-and-delete) primitives.
2015-05-22 12:22:26 -07:00
Björn Lindqvist 3887b58c02 VM: cleanups, like removing redundant paranthesis and removing method
declarations that doesn't exist
2015-05-09 20:04:22 -07:00