- 11 Jan, 2022 3 commits
-
-
Andy Wingo authored
replace use of uninitialized variable size in reset_literal_pool See merge request !15
-
Luke Nihlen authored
-
Luke Nihlen authored
-
- 07 Jan, 2021 2 commits
-
-
Andy Wingo authored
Fix jmp-shortening on x86 when target within instruction. See merge request !12
-
Andy Wingo authored
* lightening/x86.c (jit_try_shorten): If the address is within the last instruction, don't shorten. If the intstruction is a jump, we could elide it entirely in some cases, but we don't know if the user captured the PC before calling jit_patch_here. Better to leave this to the user. Thanks to Helmut Eller for the bug report and test case in #17.
-
- 30 Jul, 2020 12 commits
-
-
Andy Wingo authored
Spill whole words to stack, even for uint8_t args Closes #15 See merge request !11
-
Andy Wingo authored
* lightening/lightening.c (abi_gpr_to_mem): Write whole words when spilling GPRs to the stack. Always correct given that all Lightening operations that write GPRs write the whole register, and the current ABI targets allow writing the extra words. Closes #15.
-
Andy Wingo authored
Literal pools have word-alignment, not u64-alignment See merge request !10
-
Andy Wingo authored
Prevents useless over-alignment for ARM. * lightening/lightening.c (struct jit_literal_pool_entry): Value is a uintptr_t. (emit_uintptr): New helper. (emit_abs_reloc): Use new helper. (patch_pending_literal): Value is a uintptr_t. (emit_literal_pool): Adapt to literal entry being uintptr_t.
-
Andy Wingo authored
Allow jit_begin_data to declare max data size See merge request !9
-
Andy Wingo authored
* lightening.h: * lightening/lightening.c (jit_begin_data): Add max data size parameter. If nonzero, can allow the JIT to avoid prematurely emitting a constant pool. (jit_end_data): Allow pending literals. * tests/jmp_table.c (run_test): Use new API.
-
Andy Wingo authored
Add support for emitting inline data and table switches See merge request !6
-
Andy Wingo authored
* lightening.h: * lightening/lightening.c (jit_begin_data, jit_end_data) (jit_emit_u8, jit_emit_u16, jit_emit_u32, jit_emit_u64): Add new raw data-emitting primitives, bracketed by begin/end so that we can flush constant pools first, if needed. * lightening/lightening.c (struct jit_state): Add new emitting_data flag. (jit_begin, jit_reset, jit_end): Handle the new flag. (emit_abs_reloc): Move here, from x86.c. * lightening/x86.c (emit_abs_reloc): Remove. (jit_try_shorten): Don't shorten if loc == start; could be raw data. * tests/jmp_table.c: New test.
-
Andy Wingo authored
Ensure tail caller and callee in jmpi test have compatible ABI See merge request !8
-
Andy Wingo authored
* tests/jmpi.c: Emit the tail callee using the JIT, to ensure that it saves and restores registers in the same way as the caller. Fixes #16.
-
Andy Wingo authored
Fix patch_veneer on aarch64 See merge request !7
-
Andy Wingo authored
* lightening/aarch64.c (patch_veneer): Fix absolutely bogus patch_veneer implementation.
-
- 20 Jun, 2020 4 commits
-
-
This is a followup to 1bb909a4. It reproduces the bug that 1bb909a4 fixes on ARMv7. * tests/movi.c: New file. Co-authored-by:
Ludovic Courtès <ludo@gnu.org>
-
civodul authored
* tests/Makefile (CC_IA32, CC_AARCH64, CC_ARMv7): Remove 'glibc' from the 'guix environment' command line since it's redundant with 'gcc-toolchain'.
-
civodul authored
This allows users to run "make TARGETS=armv7", for instance. * tests/Makefile (TARGETS): Make it overridable.
-
* lightening/arm-cpu.c (encode_thumb_immediate): Fix return value in third case. Signed-off-by:
Ludovic Courtès <ludo@gnu.org>
-
- 19 Jun, 2020 5 commits
-
-
Andy Wingo authored
* lightening/lightening.c (jit_patch_there): Conditionally define flags.
-
Andy Wingo authored
Fix zeroing of literal pool entries See merge request !5
-
Andy Wingo authored
* lightening/lightening.c (reset_literal_pool): Zero before setting size to 0. Thanks to Dale Smith for pointing this out!
-
Andy Wingo authored
Fix undefined behavior in ARMv7 assembler See merge request !4
-
Andy Wingo authored
* lightening/arm-cpu.c (rotate_left): Fix the case of rotating by zero, which produced undefined behavior. Many thanks to Andrew Gierth (andrew at tao11 riddles org uk) for the debugging and the fix.
-
- 11 Jun, 2020 1 commit
-
-
Andy Wingo authored
Fix armv7 with the ARM instruction set Closes #12 See merge request !3
-
- 09 Apr, 2020 9 commits
-
-
Icecream95 authored
-
Icecream95 authored
With this, Guile builds and runs in both ARM and Thumb mode. Closes: #12
-
Icecream95 authored
It is unlikely for any ARM code to be close enough to not have needed a veneer, but it is possible, especially if running in a program with another JIT library.
-
Icecream95 authored
-
Icecream95 authored
-
Icecream95 authored
Thanks to the previous commit, the jump targets should all be correct.
-
Icecream95 authored
This will allow supporting ARM code on armv7 without having to change any users of Lightening.
-
Icecream95 authored
This will allow supporting jumping to ARM (as opposed to Thumb) code.
-
Icecream95 authored
-
- 06 Apr, 2020 2 commits
-
-
Icecream95 authored
-
Icecream95 authored
-
- 18 Feb, 2020 1 commit
-
-
Andy Wingo authored
-
- 17 Feb, 2020 1 commit
-
-
Andy Wingo authored
* lightening/x86.c (reset_abi_arg_iterator): Reserve 32 stack bytes on 64-bit Windows systems, in accordance with ABI. Thanks a million to Charles Stanhope for the patch and to Mike Gran for testing!
-