From: Matt Birkholz Date: Sat, 6 Dec 2014 19:56:10 +0000 (-0700) Subject: smp: share: README.txt begins the analysis of microcode state X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=d93bc7f;p=mit-scheme.git smp: share: README.txt begins the analysis of microcode state --- diff --git a/README.txt b/README.txt index ec6c980cc..acd136bbc 100644 --- a/README.txt +++ b/README.txt @@ -141,3 +141,566 @@ is forwarded to the next processor in a ring of all processors. Thus 2 processors are interrupted half as often with the same thread timer interval. Four processors run uninterrupted for 4 times the interval. + + +* Analyses + +There are three major concerns when running multiple Scheme machines. +The fluid-let form needed to be replaced. The use of without- +interrupts reviewed because of the change of its behavior. And the +variables of the microcode must be sorted between thread-local and +shared, and the shared variables must protected from simultaneous, +conflicting updates. + +** fluid-let + +The "fluid-let" form still exists in the runtime system. The command +line + + cd src/runtime/ && grep -in '(fluid-let' * + +reveals the 4 remaining lines. + + pp.scm:66: (FLUID-LET . ,print-let-expression) + runtime.cbf:27:(fluid-let ((compiler:coalescing-constant-warnings? #f)) + runtime.pkg:4838: (fluid-let :fluid-let) + runtime.sf:34:(fluid-let ((sf/default-syntax-table (->environment '(RUNTIME)))) + +** microcode state + +The list of state variables used by the various modules of the +microcode were found by applying nm to each module listed on the +linker command line. Of 103 Unix .o files, 91 appear on the Unix link +command line. The remaining 12 belong to the 7 microcode modules and +./findprim. + + nm --defined-only artutl.o avltree.o bkpt.o bignum.o bigprm.o bitstr.o boot.o char.o daemon.o debug.o dfloat.o error.o extern.o fasdump.o fasl.o fasload.o fixnum.o floenv.o flonum.o gcloop.o generic.o hooks.o hunk.o intern.o interp.o intprm.o list.o lookprm.o lookup.o memmag.o missing.o obstack.o option.o osscheme.o ostty.o outf.o prim.o primutl.o ptrvec.o purify.o purutl.o regex.o rgxprim.o step.o storage.o string.o syntax.o sysprim.o term.o transact.o utabmd.o utils.o vector.o wind.o prosenv.o prosfile.o prosfs.o prosio.o prosproc.o prospty.o prosterm.o prostty.o pruxsock.o prossmp.o intext.o pruxenv.o pruxfs.o pruxio.o ux.o uxctty.o uxenv.o uxfile.o uxfs.o uxio.o uxproc.o uxsig.o uxsock.o uxterm.o uxtop.o uxtrap.o uxtty.o uxutil.o cmpauxmd.o terminfo.o tterm.o pruxdld.o pruxffi.o cmpint.o cmpintmd.o comutl.o usrdef.o \ + | grep -v '^[^ ]* [TtRr] ' + + artutl.o: + + avltree.o: + 00000008 b bias.4380 + 00000000 B tree_error_message + 00000004 B tree_error_noise + + bkpt.o: + 00000004 b One_Before + 00000000 B SP_List + + bignum.o: + + bigprm.o: + + bitstr.o: + + boot.o: + 00000004 C OS_Name + 00000004 C OS_Variant + 00000050 B critical_section_hook + 0000004c B critical_section_hook_p + 00000048 B critical_section_name + 00000024 B ffi_obstack + 00000000 b initial_C_stack_pointer + 00000004 b reload_saved_string + 00000008 b reload_saved_string_length + 00000004 C scheme_program_name + 00000000 B scratch_obstack + + char.o: + + daemon.o: + + debug.o: + 00000000 b saved_addrs + 00000040 b saved_index + + dfloat.o: + + error.o: + 00000004 b current_handler_record + 00000008 b current_restart_record + 00000000 b next_condition_type_index + + extern.o: + + fasdump.o: + 00000064 b cc_seen_p + 0000005c b current_env_mode + 00000060 b current_pr + 00000068 b dumped_ephemeron_count + 000000a4 b fasdump_original_digest + 0000006c b fasdump_saved_Free + 00000098 b fasdump_saved_constant_alloc_next + 000000a0 b fasdump_saved_constant_end + 0000009c b fasdump_saved_constant_start + 00000070 b fasdump_saved_heap_alloc_limit + 00000078 b fasdump_saved_heap_end + 00000074 b fasdump_saved_heap_start + 00000094 b fasdump_saved_shared_heap_end + 0000008c b fasdump_saved_shared_heap_free + 00000090 b fasdump_saved_shared_heap_start + 00000088 b fasdump_saved_stack_end + 00000080 b fasdump_saved_stack_guard + 0000007c b fasdump_saved_stack_pointer + 00000084 b fasdump_saved_stack_start + 00000000 b fasl_header + 00000058 b fh + 000000b0 b fixups_end + 000000ac b fixups_next + 000000a8 b fixups_start + 000000b4 b initialized_p.7460 + 000000c0 b table.7461 + + fasl.o: + + fasload.o: + 00000084 b failed_heap_length.6294 + 00000000 b fasl_header + 00000058 b fh + 00000088 b initialized_p.6365 + 000001c8 b initialized_p.6399 + 00000060 b new_constant_start + 0000005c b new_heap_start + 00000070 b new_prim_table + 00000068 b new_stack_end + 00000064 b new_stack_start + 0000006c b new_utilities + 00000074 b reload_band_name + 00000078 b reload_cleanups + 00000080 b reload_constant_size + 0000007c b reload_heap_size + 000000a0 b table.6366 + 000001e0 b table.6400 + + fixnum.o: + + floenv.o: + 00000004 b scheme_fenv + 00000000 b scheme_fenv_p + + flonum.o: + + gcloop.o: + 00000004 C current_gc_table + 00000024 b current_object + 00000020 b current_scan + 0000002c b ephemeron_list + 00000030 b ephemeron_queue + 00000004 b gc_abort_handler + 00002048 b gc_object_referenced + 0000204c b gc_object_references + 00002050 b gc_object_references_count + 00002058 b gc_object_references_end + 00002054 b gc_object_references_scan + 00000040 b gc_scan_history + 00000038 b gc_scan_history_index + 00002040 b gc_scan_trap + 00001040 b gc_to_history + 00002044 b gc_to_trap + 00000000 b gc_tospace_allocator + 00000000 d gc_trap + 00000020 D gc_type_map + 00002060 b initialized_p.5660 + 0000001c b newspace_end + 00000018 b newspace_next + 00000014 b newspace_start + 00000034 b scanning_ephemerons_p + 00002080 b table.5661 + 00000010 b tospace_end + 0000000c b tospace_next + 00000008 b tospace_start + 00000028 b weak_chain + 0000205c b weak_chain_length + + generic.o: + + hooks.o: + + hunk.o: + + intern.o: + + interp.o: + 00000000 B interpreter_state + 00000004 B prim_apply_error_code + + intprm.o: + + list.o: + + lookprm.o: + + lookup.o: + + memmag.o: + 00000000 d primes + 00000004 b saved_constant_size + 00000000 b saved_heap_size + 00000004 C saved_processor_count + 00000004 C saved_processor_heap_size + 00000004 C saved_stack_size + 00000008 b saved_to + + missing.o: + + obstack.o: + 00000004 C _obstack + + option.o: + 00000004 B option_band_file + 00000001 C option_batch_mode + 00000004 C option_constant_size + 00000001 C option_disable_core_dump + 00000001 C option_emacs_subprocess + 00000008 B option_fasl_file + 00000001 C option_force_interactive + 00000004 C option_heap_size + 00000000 B option_library_path + 00000004 C option_processor_count + 00000004 C option_processor_heap_size + 00000014 b option_raw_band + 0000001c b option_raw_constant + 00000018 b option_raw_heap + 00000010 b option_raw_library + 00000024 b option_raw_processor_count + 00000028 b option_raw_processor_heap + 00000020 b option_raw_stack + 00000004 C option_saved_argc + 00000004 C option_saved_argv + 00000001 C option_show_help + 00000001 C option_show_version + 00000004 C option_stack_size + 0000000c b option_summary + 00000004 C option_unused_argc + 00000004 C option_unused_argv + + osscheme.o: + + ostty.o: + 00000000 b next_interrupt_char + + outf.o: + 00000000 b stderr_mutex + 00000018 b stdout_mutex + + prim.o: + + primutl.o: + 00000000 B MAX_PRIMITIVE + 00000008 B Primitive_Arity_Table + 0000000c B Primitive_Count_Table + 00000014 B Primitive_Documentation_Table + 00000010 B Primitive_Name_Table + 00000004 B Primitive_Procedure_Table + 00000018 B load_renumber_table + 00000088 d null_string.6141 + 00000020 b prim_procedure_tree + 0000001c b prim_table_size + 00000000 d primitive_aliases + + ptrvec.o: + + purify.o: + + purutl.o: + + regex.o: + 00000000 D re_max_failures + + rgxprim.o: + + step.o: + + storage.o: + 000002a0 D Abort_Names + 00000015 B Bignum_Debug + 00000004 D CONT_PRINT_EXPR_MESSAGE + 00000000 D CONT_PRINT_RETURN_MESSAGE + 0000000d B Cont_Debug + 00000010 B Define_Debug + 00000013 B Dump_Debug + 000002e0 D Error_Names + 00000008 B Eval_Debug + 0000000a B File_Load_Debug + 00000000 B Free_primitive + 00000011 B GC_Debug + 00000009 B Hex_Input_Debug + 0000000c B Intern_Debug + 0000000f B Lookup_Debug + 00000010 D MAX_RETURN + 00000016 B Per_File + 0000000e B Primitive_Debug + 0000000c D RESTORE_CONT_EXPR_MESSAGE + 00000008 D RESTORE_CONT_RETURN_MESSAGE + 0000000b B Reloc_Debug + 00000020 D Return_Names + 000003e0 D Term_Names + 00000014 B Trace_On_Error + 00000012 B Upgrade_Debug + 00000004 C constant_alloc_next + 00000004 C constant_end + 00000004 C constant_start + 00000190 C debug_circle + 0000001c B debug_nslots + 00000018 B debug_slotno + 00000000 B ephemeron_array + 00000004 B ephemeron_count + 00000001 C ephemeron_request_hard_p + 00000004 C fixed_objects + 000004e0 D fixed_objects_names + 00000018 B gc_shared_space_needed + 00000014 B gc_space_needed + 00000004 C heap_reserved + 00000004 B heap_start + 0000000c B last_return_code + 00000190 C local_circle + 00000024 B local_nslots + 00000020 B local_slotno + 00000004 C memory_block_end + 00000004 C memory_block_start + 00000004 C n_ephemerons_requested + 00000004 C p0_heap_start + 00000004 C shared_heap_end + 00000004 C shared_heap_free + 00000004 C shared_heap_start + 00000008 B stack_end + 00000460 D term_messages + 00000010 B trapping + 000001a0 D type_names + + string.o: + 00000000 b external_strings + + syntax.o: + 00000080 D syntax_code_spec + 00000000 D syntax_spec_code + + sysprim.o: + + term.o: + 00000020 b new_state.6060 + 000000e0 b new_state.6077 + 00000000 b position.6059 + 000000cc b position.6076 + + transact.o: + 00000000 b current_transaction + + utabmd.o: + 00000000 d identity_names + + utils.o: + 00000004 C death_blow + 00000000 b error_argument + 00000000 B history_register + 00000004 B prev_restore_history_offset + + vector.o: + + wind.o: + 00000024 b current_winding_record + 00000000 b dstack + 00000028 B dstack_position + 00000000 b save_binding_location + + prosenv.o: + + prosfile.o: + + prosfs.o: + + prosio.o: + 00000000 d channel_type_names + + prosproc.o: + + prospty.o: + + prosterm.o: + + prostty.o: + + pruxsock.o: + + prossmp.o: + 00000020 b finished + 00000018 B gc_processor + 00000004 C processors + 00000060 b ready + 00000000 B self + 000000ac b smp_idle_prim + 00000000 B state_mutex + 00000090 b thread_mutex + 000000a8 b trace_p + + intext.o: + 00000000 B current_interruptable_extent + + pruxenv.o: + + pruxfs.o: + + pruxio.o: + + ux.o: + 00000000 B UX_out_of_files_p + 00000004 b memoized_clk_tck + + uxctty.o: + 00000000 b ctty_fildes + 0000024c b current_interrupt_chars + 00000248 b current_interrupt_enables + 00000140 b inside_ctty_state + 000001a0 b inside_stdin_state + 00000200 b inside_stdout_state + 00000250 b int_chars.7411 + 00000253 b int_handlers.7428 + 00000020 b outside_ctty_state + 00000080 b outside_stdin_state + 000000e0 b outside_stdout_state + 00000004 b permit_ctty_control + 00000004 C scheme_in_foreground + + uxenv.o: + 00000010 b current_dir_path + 0000000c b current_dir_path_size + 00000000 b initial_process_clock + 00000004 b initial_rtc + 00000000 d utc_epoch_minus_unix_epoch + 00000020 b zero_tx.8640 + + uxfile.o: + + uxfs.o: + 00000000 b directory_pointers + 00000004 b n_directory_pointers + + uxio.o: + 00000004 C OS_channel_table_size + 00000004 C channel_table + + uxproc.o: + 00000004 C OS_process_table_size + 00000004 b foreground_child_process + 00000020 b grabbed_signal_mask + 00000004 C process_table + 00000008 b process_tick + 00000000 b scheme_ctty_fd + 00000004 C scheme_jc_status + 0000000c b sync_tick + + uxsig.o: + 00000000 b blocked_signals + 000000a0 b buffer.8771 + 00000000 d reset_choices.9210 + 00000080 b signal_descriptors + 00000084 b signal_descriptors_length + 00000088 b signal_descriptors_limit + 00000004 C stop_signal_hook + 00000004 C subprocess_death_hook + + uxsock.o: + 00000000 b address.8832 + + uxterm.o: + 00000008 b slave_name.9024 + 00000004 b terminal_table + 00000000 b terminal_table_size + + uxtop.o: + 00000000 b interactive + 00000000 d syscall_names_table + 00000120 d syserr_names_table + + uxtrap.o: + 00000010 b saved_info + 00000014 b saved_scp + 0000000c b saved_signo + 00000008 b saved_trap_state + 00000000 d trap_query_choices.9003 + 00000000 b trap_state + 00000004 b user_trap_state + 00000000 b ux_signal_codes + + uxtty.o: + 00000000 b input_channel + 00000004 b output_channel + 00000840 b tgetstr_buffer.8852 + 00000020 b tputs_output + 00000820 b tputs_output_scan + 00000010 b tty_command_beep + 00000014 b tty_command_clear + 00000018 b tty_size_synchronized_p + 00000008 b tty_x_size + 0000000c b tty_y_size + + uxutil.o: + 0000003c b buffer.8550 + 00000060 b buffer.8562 + 00000000 b original_tty_state + + cmpauxmd.o: + 0000001c B C_Frame_Pointer + 00000018 B C_Stack_Pointer + 00000000 B Free + 000000a0 B Registers + 00000004 B heap_alloc_limit + 00000008 B heap_end + 00000004 C i387_presence + 00000004 C ia32_cpuid_needed + 00000004 C ia32_cpuid_supported + 00000004 C sse_presence + 0000000c B stack_guard + 00000010 B stack_pointer + 00000014 B stack_start + + terminfo.o: + + tterm.o: + 00000000 b termcap_buffer + 00000800 b tgetstr_buffer + 00001000 b tgetstr_pointer + 00001020 b tputs_output + 00001820 b tputs_output_scan + + pruxdld.o: + 00000000 b cleanup_registered_p + 0000000c b loaded_handles + 00000004 b loaded_handles_size + 00000008 b n_loaded_handles + + pruxffi.o: + 00000004 b c_call_continue + 00000000 B cstack_depth + 0000000c b return_to_c + 00000008 b run_callback + + cmpint.o: + 00000010 b builtin_names + 0000000c b builtins + 00000004 C compiler_interface_version + 00000004 C compiler_processor_type + 00000004 C compiler_utilities + 00000000 b linking_cc_block_p + 00000138 D max_trampoline + 00000004 b n_builtins + 00000004 C reflect_to_interface + 00000004 C return_to_interpreter + 00000008 b s_builtins + 00000000 d trampoline_arity_table + 00000040 D utility_table + + cmpintmd.o: + 00000000 b fp_support_present + + comutl.o: + 00000000 b ilof_prefix + + usrdef.o: + 00000000 D MAX_STATIC_PRIMITIVE + 00001f40 D Static_Primitive_Arity_Table + 000029a0 D Static_Primitive_Count_Table + 000014e0 D Static_Primitive_Documentation_Table + 00000a80 D Static_Primitive_Name_Table + 00000020 D Static_Primitive_Procedure_Table