| Commit message (Expand) | Author | Age | Files | Lines |
* | constant-interning fix...(Best-ability ChangeLog annotation added by Christopher Allan Webber.)
* module/system/vm/assembler.scm (intern-constant): Switch from using
vector-ref/immediate to make-short-immediate.
| Robin Templeton | 2020-04-04 | 1 | -1/+2 |
* | prefer compilers earlier in list...(Best-ability ChangeLog annotation added by Christopher Allan Webber.)
* module/system/base/compile.scm (find-language-joint): Change order of cond.
| Robin Templeton | 2020-04-04 | 1 | -2/+2 |
* | check symbols constants uninterned...(Best-ability ChangeLog annotation added by Christopher Allan Webber.)
* module/system/vm/assembler.scm (intern-constant, link-data):
Update to check "symbol-interned?".
| Robin Templeton | 2020-04-04 | 1 | -1/+1 |
* | intern arbitrary constants...(Best-ability ChangeLog annotation added by Christopher Allan Webber.)
* libguile/loader.c (load_thunk_from_memory): Refactor, adding
"constants" argument and passing to "init" if appropriate.
(load_thunk_from_file): Call "load-thunk-from-memory" with
"constants" set to #f.
(scm_load_thunk_from_memory): Instead of a bytevector, accept
a cons of "(bytevector . constants)", where constants is either
a vector or #f. Pass this into "load_thunk_from_memory".
* module/language/bytecode/spec.scm: Adapt printer.
* module/language/cps/compile-bytecode.scm (compile-bytecode):
New variable.
* module/system/repl/command.scm (disassemble):
Adapt to expect pair which includes bytevector as its car.
* module/system/vm/assembler.scm <asm>: Add "to-file?" slot.
(fresh-block): New variable.
(make-assembler): Adapt to expect "to-file?" keyword argument.
(intern-constant): Support "asm-to-file?" in checks.
(emit-init-constants, link-data): Likewise.
(link-assembly): Update logic for handling "(bytevector . constants)"
pair, as well as the expectations of its invocation by compile-bytecode.
| Robin Templeton | 2020-04-04 | 2 | -9/+27 |
* | REPL server: Avoid deprecated '_IOFBF'....* module/system/repl/server.scm (drain-input-and-close): Use 'block
instead of _IOFBF.
| Ludovic Courtès | 2019-06-30 | 1 | -1/+1 |
* | Remove references to 'inet-ntoa' and 'inet-aton'....These procedures were removed in Guile 2.2 by commit
fc7bd367ab4b5027a7f80686b1e229c62e43c90b (May 2011).
* libguile/socket.h (scm_inet_aton, scm_inet_ntoa): Remove.
* module/system/repl/server.scm (make-tcp-server-socket): Use
'inet-pton' instead of 'inet-aton'.
* doc/ref/web.texi (HTTP): Likewise in 'declare-header!' example.
* doc/ref/posix.texi (Network Address Conversion): Remove documentation
of 'inet-ntoa' and 'inet-aton'.
| Ludovic Courtès | 2019-06-24 | 1 | -2/+4 |
* | Avoid regexp ranges in HTTP inter-protocol exploitation check....* module/system/repl/server.scm (permissive-http-request-line?): Avoid
character ranges in regexp.
| Mark H Weaver | 2019-06-18 | 1 | -1/+1 |
* | Update user-visible copyright years....* doc/ref/guile.texi: Update years in copyright notice.
* module/ice-9/command-line.scm (version-etc): Update 'copyright-year'.
* module/system/repl/common.scm (*version*): Update copyright years.
| Mark H Weaver | 2019-04-16 | 1 | -2/+2 |
* | Add -Wshadowed-toplevel....* module/language/tree-il/analyze.scm (shadowed-toplevel-analysis): New
variable.
* module/language/tree-il/compile-cps.scm (%warning-passes): Add it.
* module/system/base/message.scm (%warning-types): Add it.
* test-suite/tests/tree-il.test ("warnings")["shadowed-toplevel"]: New
test prefix.
* module/ice-9/boot-9.scm (%auto-compilation-options): Add it.
* doc/ref/api-evaluation.texi (Compilation): Add 'shadowed-toplevel' and
'macro-use-before-definition'.
| Ludovic Courtès | 2018-07-24 | 1 | -1/+8 |
* | linker: Don't rely on out-of-range bv-ref exceptions....* module/system/vm/linker.scm (find-shstrndx): Check whether NAME is
lower than the length of BV; remove 'false-if-exception' around
'string-table-ref' call.
| Ludovic Courtès | 2018-06-28 | 1 | -3/+3 |
* | types: Recognize 'scm_t_port_type' and decode port type name....* module/system/base/types.scm (read-c-string, inferior-port-type): New
procedures.
(inferior-port): Use 'inferior-port-type' to determine the port type.
(cell->object): Rename 'flags+type' to 'flags' in the '%tc7-port' case.
* test-suite/tests/types.test ("opaque objects"): Adjust port testse.
(test-inferior-ports): New macro.
("ports"): New test prefix.
| Ludovic Courtès | 2018-06-24 | 1 | -6/+30 |
* | elisp: Fix cross-compilation support....* module/system/base/target.scm (with-native-target): New exported
procedure.
* module/language/elisp/spec.scm: In the top-level body expression, call
'compile-and-load' within 'with-native-target' to compile native code.
* module/language/elisp/compile-tree-il.scm
(eval-when-compile, defmacro): Compile native code.
| Mark H Weaver | 2018-06-11 | 1 | -2/+8 |
* | Recognize RISC-V compilation targets....* module/system/base/target.scm (cpu-endianness): Add case for "riscv" variants.
Signed-off-by: Shea Levy <shea@shealevy.com>
Signed-off-by: Mark H Weaver <mhw@netris.org>
| Shea Levy | 2018-03-15 | 1 | -0/+2 |
* | foreign: Add 'uintptr_t' and 'intptr_t'....* libguile/foreign.c (scm_uintptr_t, scm_intptr_t): New variables.
(scm_init_foreign): Define them.
* module/system/foreign.scm: Export 'intptr_t' and 'uintptr_t'.
* doc/ref/api-foreign.texi (Foreign Types): Document them.
Co-authored-by: Ludovic Courtès <ludo@gnu.org>
| Matt Wette | 2017-11-22 | 1 | -0/+1 |
* | Allow GDB support to be used with GDB-linked-against-Guile-2.0....* libguile/Makefile.am (INSTANTIATE): New variable.
(install-data-hook): Use it.
* libguile/libguile-2.2-gdb.scm: Autoload (system vm debug).
Augment %load-path and %load-compiled-path, and reload (system base
types).
* module/system/base/types.scm: Remove #:hide to be 2.0-compatible.
Use (system syntax internal) conditionally when on 2.2.
| Ludovic Courtès | 2017-11-05 | 1 | -10/+20 |
* | 'frame-matcher' doesn't crash when the last IP is unknown....This fixes a bug when using ",break":
system/vm/traps.scm:127:31: system/vm/traps.scm:127:31: In procedure <: Wrong type: #f
* module/system/vm/traps.scm (frame-matcher): Check whether END is
true.
| Ludovic Courtès | 2017-10-25 | 1 | -2/+3 |
* | Use make-struct/no-tail instead of make-struct...* module/ice-9/boot-9.scm:
* module/language/cps/effects-analysis.scm:
* module/language/elisp/falias.scm:
* module/language/tree-il.scm:
* module/language/tree-il/primitives.scm:
* module/rnrs/records/procedural.scm:
* module/srfi/srfi-35.scm:
* module/system/base/syntax.scm: Change uses of make-struct to
make-struct/no-tail.
| Andy Wingo | 2017-09-20 | 1 | -1/+1 |
* | Bump objcode version in a compatible way...* libguile/_scm.h (SCM_OBJCODE_MINIMUM_MINOR_VERSION): New definition,
indicating the oldest objcode version that we support.
(SCM_OBJCODE_MINOR_VERSION): Bump.
* libguile/loader.c (process_dynamic_segment): Support a range of
versions.
* module/system/vm/assembler.scm (*bytecode-minor-version*): Bump.
| Andy Wingo | 2017-04-18 | 1 | -1/+1 |
* | All literal constants are read-only...* libguile/array-handle.c (initialize_vector_handle): Add mutable_p
argument. Unless the vector handle is mutable, null out its
writable_elements member.
(scm_array_get_handle): Adapt to determine mutability of the various
arrays.
(scm_array_handle_elements, scm_array_handle_writable_elements):
Reverse the sense: instead of implementing read-only in terms of
read-write, go the other way around, adding an assertion in the
read-write case that the array handle is mutable.
* libguile/array-map.c (racp): Assert that the destination is mutable.
* libguile/bitvectors.c (SCM_F_BITVECTOR_IMMUTABLE, IS_BITVECTOR):
(IS_MUTABLE_BITVECTOR): Add a flag to indicate immutability.
(scm_i_bitvector_bits): Fix indentation.
(scm_i_is_mutable_bitvector): New helper.
(scm_array_handle_bit_elements)
((scm_array_handle_bit_writable_elements): Build writable_elements in
terms of elements.
(scm_bitvector_elements, scm_bitvector_writable_elements): Likewise.
(scm_c_bitvector_set_x): Require a mutable bitvector for the
fast-path.
(scm_bitvector_to_list, scm_bit_count): Use read-only elements()
function.
* libguile/bitvectors.h (scm_i_is_mutable_bitvector): New decl.
* libguile/bytevectors.c (INTEGER_ACCESSOR_PROLOGUE):
(INTEGER_GETTER_PROLOGUE, INTEGER_SETTER_PROLOGUE):
(INTEGER_REF, INTEGER_NATIVE_REF, INTEGER_SET, INTEGER_NATIVE_SET):
(GENERIC_INTEGER_ACCESSOR_PROLOGUE):
(GENERIC_INTEGER_GETTER_PROLOGUE, GENERIC_INTEGER_SETTER_PROLOGUE):
(LARGE_INTEGER_NATIVE_REF, LARGE_INTEGER_NATIVE_SET):
(IEEE754_GETTER_PROLOGUE, IEEE754_SETTER_PROLOGUE):
(IEEE754_REF, IEEE754_NATIVE_REF, IEEE754_SET, IEEE754_NATIVE_SET):
Setters require a mutable bytevector.
(SCM_BYTEVECTOR_SET_FLAG): New helper.
(SCM_BYTEVECTOR_SET_CONTIGUOUS_P, SCM_BYTEVECTOR_SET_ELEMENT_TYPE):
Remove helpers.
(SCM_VALIDATE_MUTABLE_BYTEVECTOR): New helper.
(make_bytevector, make_bytevector_from_buffer): Use
SCM_SET_BYTEVECTOR_FLAGS.
(scm_c_bytevector_set_x, scm_bytevector_fill_x)
(scm_bytevector_copy_x): Require a mutable bytevector.
* libguile/bytevectors.h (SCM_F_BYTEVECTOR_CONTIGUOUS)
(SCM_F_BYTEVECTOR_IMMUTABLE, SCM_MUTABLE_BYTEVECTOR_P): New
definitions.
* libguile/bytevectors.h (SCM_BYTEVECTOR_CONTIGUOUS_P): Just access one
bit.
* libguile/srfi-4.c (DEFINE_SRFI_4_C_FUNCS): Implement
writable_elements() in terms of elements().
* libguile/strings.c (scm_i_string_is_mutable): New helper.
* libguile/uniform.c (scm_array_handle_uniform_elements):
(scm_array_handle_uniform_writable_elements): Implement
writable_elements in terms of elements.
* libguile/vectors.c (SCM_VALIDATE_MUTABLE_VECTOR): New helper.
(scm_vector_elements, scm_vector_writable_elements): Implement
writable_elements in terms of elements.
(scm_c_vector_set_x): Require a mutable vector.
* libguile/vectors.h (SCM_F_VECTOR_IMMUTABLE, SCM_I_IS_MUTABLE_VECTOR):
New definitions.
* libguile/vm-engine.c (VM_VALIDATE_MUTABLE_BYTEVECTOR):
(VM_VALIDATE_MUTABLE_VECTOR, vector-set!, vector-set!/immediate)
(BV_BOUNDED_SET, BV_SET): Require mutable bytevector/vector.
* libguile/vm.c (vm_error_not_a_mutable_bytevector):
(vm_error_not_a_mutable_vector): New definitions.
* module/system/vm/assembler.scm (link-data): Mark residualized vectors,
bytevectors, and bitvectors as being read-only.
| Andy Wingo | 2017-04-18 | 1 | -19/+35 |
* | types: Hide one of the 'bytevector->string' procedures....* module/system/base/types.scm: Hide 'bytevector->string' from (rnrs io
ports).
| Ludovic Courtès | 2017-04-14 | 1 | -2/+2 |
* | Add disjoint syntax object type...* libguile/Makefile.am (libguile_@GUILE_EFFECTIVE_VERSION@_la_SOURCES):
(DOT_X_FILES, DOT_DOC_FILES, noinst_HEADERS): Add syntax.c and
syntax.h.
* libguile/evalext.c (scm_self_evaluating_p):
* libguile/goops.c (class_syntax, scm_class_of, scm_goops_early_init):
* libguile/init.c (scm_init_guile):
* libguile/print.c (iprin1):
* libguile/tags.h (scm_tc7_syntax):
* module/oop/goops.scm (<syntax>):
* module/system/base/types.scm (%tc7-syntax, cell->object):
* module/system/vm/disassembler.scm (code-annotation): Wire up the new
data type.
* libguile/syntax.c:
* libguile/syntax.h: New files.
* module/ice-9/boot-9.scm: Move new definitions to (system syntax
internal).
* module/system/syntax.scm (print-syntax): New helper.
* module/system/vm/assembler.scm (statically-allocatable?)
(intern-constant, link-data): Arrange to be able to write syntax
objects into images.
* module/language/cps/types.scm (&syntax): New type. Remove
&hash-table; it was never detected, an internal binding, and we need
the bit to avoid going into bignum territory.
| Andy Wingo | 2017-03-28 | 4 | -2/+38 |
* | Plumbing changes to rename "syntax-module"...* module/ice-9/psyntax.scm (%syntax-module): Rename from syntax-module
in order to make room for a new syntax-module primitive binding.
* module/ice-9/psyntax-pp.scm: Regenerate.
* module/ice-9/boot-9.scm: Push syntax bindings into an internal
module.
* module/system/syntax.scm: New file.
* module/Makefile.am (SOURCES): Add system/syntax.scm.
| Andy Wingo | 2017-03-28 | 1 | -0/+26 |
* | Update --version and REPL copyright years...* module/ice-9/command-line.scm (version-etc):
* module/system/repl/common.scm (*version*): Update release year.
| Andy Wingo | 2017-03-15 | 1 | -1/+1 |
* | VM support for string-set!; slimmer read-string...* doc/ref/vm.texi (Inlined Scheme Instructions): Add string-set!.
* libguile/vm-engine.c (string-set!): New opcode.
* module/ice-9/rdelim.scm (read-string): Reimplement in terms of a
geometrically growing list of strings, to reduce total heap usage when
reading big files.
* module/language/cps/compile-bytecode.scm (compile-function): Add
string-set! support.
* module/language/cps/types.scm (string-set!): Update for &u64 index.
* module/language/tree-il/compile-cps.scm (convert): Unbox index to
string-set!.
* module/system/vm/assembler.scm (system): Export string-set!.
| Andy Wingo | 2017-03-09 | 1 | -0/+1 |
* | 64KB segment alignment...* module/system/vm/linker.scm (*lcm-page-size*): Rename
from *page-size*, change to 64 KB.
* libguile/loader.c (load_thunk_from_memory): Only require page size
alignment, knowing that although Guile might emit ELF with 64k
alignment, it only really needs page alignment.
| Andy Wingo | 2017-03-08 | 1 | -2/+37 |
* | psyntax: Generate identifiers in a deterministic fashion....Fixes <http://bugs.gnu.org/20272>.
* module/ice-9/boot-9.scm (module-generate-unique-id!)
(module-gensym): New procedures.
(module): Add 'next-unique-id' field.
(the-root-module): Inherit 'next-unique-id' value from early stub.
(make-module, make-autoload-interface): Adjust calls to
module-constructor.
* module/ice-9/psyntax.scm (gen-label, new-mark): Generate unique
identifiers from the module name and the per-module unique-id.
(build-lexical-var, generate-temporaries): Use
'module-gensym' instead of 'gensym'.
* module/ice-9/psyntax-pp.scm: Regenerate.
* module/language/tree-il/fix-letrec.scm (fix-letrec!): Use
'module-gensym' instead of 'gensym'.
* module/system/base/syntax.scm (define-record): Likewise.
(transform-record): Likewise.
Co-authored-by: Ludovic Courtès <ludo@gnu.org>
| Mark H Weaver | 2017-03-07 | 1 | -4/+4 |
* | Recognize sh3 as compilation targets...* module/system/base/target.scm (cpu-endianness, triplet-pointer-size):
Add case for "sh3".
Signed-off-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
| John Paul Adrian Glaubitz | 2017-03-01 | 1 | -2/+2 |
* | REPL Server: Guard against HTTP inter-protocol exploitation attacks....Reported by Christopher Allan Webber <cwebber@dustycloud.org>
Co-authored-by: Ludovic Courtès <ludo@gnu.org>
This commit adds protection to Guile's REPL servers against HTTP
inter-protocol exploitation attacks, a scenario whereby an attacker can,
via an HTML page, cause a web browser to send data to TCP servers
listening on a loopback interface or private network. See
<https://en.wikipedia.org/wiki/Inter-protocol_exploitation> and
<https://www.jochentopf.com/hfpa/hfpa.pdf>, The HTML Form Protocol
Attack (2001) by Tochen Topf <jochen@remote.org>.
Here we add a procedure to 'before-read-hook' that looks for a possible
HTTP request-line in the first line of input from the client socket. If
present, the socket is drained and closed, and a loud warning is written
to stderr (POSIX file descriptor 2).
* module/system/repl/server.scm: Add 'maybe-check-for-http-request'
to 'before-read-hook' when this module is loaded.
(with-temporary-port-encoding, with-saved-port-line+column)
(drain-input-and-close, permissive-http-request-line?)
(check-for-http-request, guard-against-http-request)
(maybe-check-for-http-request): New procedures.
(serve-client): Use 'guard-against-http-request'.
* module/system/repl/coop-server.scm (start-repl-client): Use
'guard-against-http-request'.
* doc/ref/guile-invoke.texi (Command-line Options): In the description
of the --listen option, make the security warning more prominent.
Mention the new protection added here. Recommend using UNIX domain
sockets for REPL servers. "a path to" => "the file name of".
| Mark H Weaver | 2017-03-01 | 2 | -4/+188 |
* | Cosmetic REPL server improvements...* module/system/repl/server.scm (run-server*): Cosmetic improvements.
| Andy Wingo | 2017-03-01 | 1 | -10/+10 |
* | Fix trap frame matching...* module/system/vm/traps.scm (program-last-ip): Actually return an
absolute IP. Fixes traps!
| Andy Wingo | 2017-03-01 | 1 | -1/+3 |
* | Fix compute-frame-sizes for case-lambda jumps...* module/system/vm/frame.scm (compute-frame-sizes): Fix for jumps to the
next arity.
| Andy Wingo | 2017-02-22 | 1 | -0/+3 |
* | Stringbufs immutable by default...* libguile/snarf.h (SCM_IMMUTABLE_STRINGBUF): Remove shared flag.
Stringbufs are immutable by default.
* libguile/strings.c: Rewrite blurb. Change to have stringbufs be
immutable by default and mutable only when marked as such. Going
mutable means making a private copy.
(STRINGBUF_MUTABLE, STRINGBUF_F_MUTABLE): New definitions.
(SET_STRINGBUF_SHARED): Remove.
(scm_i_print_stringbuf): Simplify to just alias the stringbuf as-is.
(substring_with_immutable_stringbuf): New helper.
(scm_i_substring, scm_i_substring_read_only, scm_i_substring_copy):
use new helper.
(scm_i_string_ensure_mutable_x): New helper.
(scm_i_substring_shared): Use scm_i_string_ensure_mutable_x.
(stringbuf_write_mutex): Remove; yaaaaaaaay.
(scm_i_string_start_writing): Use scm_i_string_ensure_mutable_x. No
more mutex.
(scm_i_string_stop_writing): Now a no-op.
(scm_i_make_symbol): Use substring/copy.
(scm_sys_string_dump, scm_sys_symbol_dump): Update.
* libguile/strings.h (SCM_I_STRINGBUF_F_SHARED): Remove.
(SCM_I_STRINGBUF_F_MUTABLE): Add.
* module/system/vm/assembler.scm (link-data): Don't add shared flag any
more. Existing compiled flags are harmless tho.
* test-suite/tests/strings.test ("string internals"): Update.
| Andy Wingo | 2017-02-16 | 1 | -5/+2 |
* | Avoid stacks in dynamically-bound values...* libguile/dynstack.h:
* libguile/dynstack.c (scm_dynstack_find_old_fluid_value): New
function.
* libguile/fluids.c (saved_dynamic_state_ref): New helper.
(scm_fluid_ref): Fix docstring.
(scm_fluid_ref_star): New function allowing access to previous values
for a fluid.
(scm_dynamic_state_ref): New internal function.
* libguile/fluids.h: Add scm_fluid_ref_star and scm_dynamic_state_ref.
* libguile/stacks.c (scm_stack_id): Adapt to %stacks not being a chain.
* libguile/throw.c (catch, throw_without_pre_unwind): Adapt to
%exception-handlers not being a chain.
* module/ice-9/boot-9.scm (catch, dispatch-exception): Instead of having
%exception-handlers be a chain, use fluid-ref* to access the chain
that is in place at the time the exception is thrown. Prevents
unintended undelimited capture of the current exception handler stack
by a delimited "catch".
(%start-stack): Similarly, don't be a chain.
* module/system/repl/debug.scm (frame->stack-vector):
* module/system/repl/error-handling.scm (call-with-error-handling):
* module/ice-9/save-stack.scm (save-stack): Adapt to %stacks not being a
chain.
* test-suite/tests/exceptions.test ("delimited exception handlers"): Add
tests.
* doc/ref/api-control.texi (Fluids and Dynamic States): Add docs.
| Andy Wingo | 2017-02-07 | 2 | -5/+5 |
* | Add unboxed floating point comparison instructions....* libguile/vm-engine.c (BR_F64_ARITHMETIC): New preprocessor macro.
(br_if_f64_ee, br_if_f64_lt, br_if_f64_le, br_if_f64_gt, br_if_f64_ge):
New VM instructions.
* doc/ref/vm.texi ("Unboxed Floating-Point Arithmetic"): Document them.
* module/language/cps/compile-bytecode.scm (compile-function): Emit f64
comparison instructions.
* module/language/cps/effects-analysis.scm: Define effects for f64
primcalls.
* module/language/cps/primitives.scm (*branching-primcall-arities*): Add
arities for f64 primcalls.
* module/language/cps/specialize-numbers.scm (specialize-f64-comparison):
New procedure.
(specialize-operations): Specialize f64 comparisons.
* module/system/vm/assembler.scm (emit-br-if-f64-=, emit-br-if-f64-<)
(emit-br-if-f64-<=, emit-br-if-f64->, emit-br-if-f64->=): Export.
* module/system/vm/disassembler.scm (code-annotation): Add annotations
for f64 comparison instructions.
| David Thompson | 2017-01-12 | 2 | -0/+7 |
* | with-dynamic-state compiler and VM support...* libguile/dynstack.h (SCM_DYNSTACK_TYPE_DYNAMIC_STATE):
* libguile/dynstack.c (DYNAMIC_STATE_WORDS, DYNAMIC_STATE_STATE_BOX):
(scm_dynstack_push_dynamic_state):
(scm_dynstack_unwind_dynamic_state): New definitions.
(scm_dynstack_unwind_1, scm_dynstack_wind_1): Add with-dynamic-state
cases.
* libguile/memoize.c (push_dynamic_state, pop_dynamic_state)
(do_push_dynamic_state, do_pop_dynamic_state): New definitions.
(memoize, scm_init_memoize): Handle push-dynamic-state and
pop-dynamic-state.
* libguile/vm-engine.c (push-dynamic-state, pop-dynamic-state): New
opcodes.
* module/ice-9/boot-9.scm (with-dynamic-state): New definition in Scheme
so that the push-dynamic-state and pop-dynamic-state always run in the
VM.
* module/language/cps/compile-bytecode.scm (compile-function):
* module/language/cps/effects-analysis.scm:
* module/language/cps/types.scm:
* module/language/tree-il/effects.scm (make-effects-analyzer):
* module/language/tree-il/peval.scm (peval):
* module/language/tree-il/primitives.scm (*interesting-primitive-names*):
* module/system/vm/assembler.scm: Add support for with-dynamic-state to
the compiler.
* test-suite/tests/fluids.test ("dynamic states"): Add basic tests.
* doc/ref/vm.texi (Dynamic Environment Instructions): Update.
| Andy Wingo | 2016-12-05 | 1 | -0/+2 |
* | Compile fluid-set! to VM opcode...* libguile/vm-engine.c (fluid-set!): Fix name of opcode to correspond
with name of Tree-IL primitive. Fixes compilation of fluid-set! to
actually use the fluid-set! opcode.
* doc/ref/vm.texi (Dynamic Environment Instructions): Update.
* module/language/cps/compile-bytecode.scm (compile-function): Add
fluid-set! case.
* module/system/vm/assembler.scm: Update export name for
emit-fluid-set!.
| Andy Wingo | 2016-11-27 | 1 | -1/+1 |
* | Remove special support for fluids in GDB interface...* module/system/base/types.scm (inferior-fluid?, inferior-fluid-number)
(<inferior-fluid>): Remove. Fluids won't have numbers in the future.
(cell->object): Adapt.
* test-suite/tests/types.test ("opaque objects"): Update.
| Andy Wingo | 2016-11-26 | 1 | -20/+2 |
* | Fix compilation of rank 0 typed array literals...* module/system/vm/assembler.scm (simple-uniform-vector?): array-length
fails for rank 0 arrays; fix the shape condition.
* test-suite/tests/arrays.test: Test reading of #0f64(x) in compilation
context.
| Daniel Llorens | 2016-11-23 | 1 | -1/+3 |
* | Add handle-interrupts inst and compiler pass...* libguile/vm-engine.c (vm_engine): Remove initial VM_HANDLE_INTERRUPTS
call; surely our caller already handled interrupts. Add
handle-interrupts opcode.
* am/bootstrap.am (SOURCES):
* module/Makefile.am (SOURCES): Add handle-interrupts.scm.
* module/system/vm/assembler.scm (system):
* module/language/cps/compile-bytecode.scm (compile-function):
(lower-cps): Add handle-interrupts support.
* module/language/cps/handle-interrupts.scm: New file.
| Andy Wingo | 2016-11-16 | 1 | -0/+1 |
* | REPL server avoids thread cleanup handlers...* module/system/repl/server.scm (serve-client): Avoid thread cleanup
handlers.
| Andy Wingo | 2016-10-31 | 1 | -11/+12 |
* | Adapt run-server* to change to `accept'....* module/system/repl/server.scm (run-server*): Adapt to new #f return
value of accept on non-blocking ports.
(errs-to-retry): Remove variable.
| Andy Wingo | 2016-10-19 | 1 | -25/+9 |
* | Fix cross-compilation of negative fixnums...* module/system/vm/assembler.scm (encoder): Use immediate-bits instead
of object-address, to fix cross-compilation.
| Andy Wingo | 2016-09-06 | 1 | -6/+5 |
* | Compiler support for atomics...* doc/ref/vm.texi (Inlined Atomic Instructions): New section.
* libguile/vm-engine.c (VM_VALIDATE_ATOMIC_BOX, make-atomic-box)
(atomic-box-ref, atomic-box-set!, atomic-box-swap!)
(atomic-box-compare-and-swap!): New instructions.
* libguile/vm.c: Include atomic and atomics-internal.h.
(vm_error_not_a_atomic_box): New function.
* module/ice-9/atomic.scm: Register primitives with the compiler.
* module/language/cps/compile-bytecode.scm (compile-function): Add
support for atomic ops.
* module/language/cps/effects-analysis.scm: Add comment about why no
effects analysis needed.
* module/language/cps/reify-primitives.scm (primitive-module): Add case
for (ice-9 atomic).
* module/language/tree-il/primitives.scm (*effect-free-primitives*):
(*effect+exception-free-primitives*): Add atomic-box?.
* module/system/vm/assembler.scm: Add new instructions.
* test-suite/tests/atomic.test: Test with compilation and
interpretation.
| Andy Wingo | 2016-09-06 | 1 | -0/+5 |
* | Fix fixnum min/max for assembler...* module/system/vm/assembler.scm (immediate-bits): I am a complete and
total idiot and got the fixnum mins and maxes swapped.
| Andy Wingo | 2016-09-06 | 1 | -4/+4 |
* | Tweak value of tc7-smob....* libguile/tags.h (scm_tc7_smob):
* module/system/base/types.scm (%tc7-smob): Tweak this value, just to
prove that it can be done. Remove scary comment.
| Andy Wingo | 2016-09-06 | 1 | -1/+1 |
* | Convert tc7 values to hex in tags.h and elsewhere...* libguile/tags.h:
* module/system/base/types.scm:
* module/system/vm/assembler.scm: Convert tc7 values to hex. No change
otherwise.
| Andy Wingo | 2016-09-06 | 2 | -30/+30 |
* | Check for missing debug info in print-program...* module/system/vm/program.scm (print-program): Check the return value
of find-program-debug-info. Fixes #24320.
| Robin Templeton | 2016-09-02 | 1 | -1/+1 |
* | Add unboxed logxor on u64 values...* libguile/vm-engine.c (ulogxor): New instruction.
* module/language/cps/effects-analysis.scm (ulogxor):
* module/language/cps/slot-allocation.scm (compute-var-representations):
* module/language/cps/types.scm (ulogxor):
* module/system/vm/assembler.scm (emit-ulogxor): Add support for new
instruction.
* doc/ref/vm.texi (Unboxed Integer Arithmetic): Document ulogxor.
| Andy Wingo | 2016-09-01 | 1 | -0/+1 |
* | Fix exception when running ",help debug"...* module/system/repl/command.scm (*command-table*): Remove entry for
",procedure", a command removed a few months ago.
| Andy Wingo | 2016-08-25 | 1 | -1/+1 |
* | Recognize alpha as compilation target...* module/system/base/target.scm (cpu-endianness): Add case for "alpha".
(triplet-pointer-size): Likewise.
| James Clarke | 2016-08-08 | 1 | -2/+2 |