Use indirection for entry points on amd64.
authorTaylor R Campbell <campbell@mumble.net>
Thu, 27 Dec 2018 03:58:38 +0000 (03:58 +0000)
committerTaylor R Campbell <campbell@mumble.net>
Tue, 13 Aug 2019 14:37:02 +0000 (14:37 +0000)
commit67adeda088f018ba07ad79e0b875a12d516c4623
treed90b44de637dca721207b069bf0d7f1c0552cee2
parenta6a461c06f036195c98bcf0f4f31bef7fe18859a
Use indirection for entry points on amd64.

A compiled entry is now a tagged address A pointing to a 64-bit word
W such that A + W points to instruction to execute.

This adds a memory indirection overhead to unknown procedure calls,
but it has the effect that consing a closure only involves writing
data memory, not instruction memory that must be reloaded into the
CPU's instruction cache.

WARNING: This changes the amd64 compiled code interface, so you'll
have to build a new compiler running on an old microcode and use that
to compile a new system afresh.
src/compiler/machines/x86-64/insutl.scm
src/compiler/machines/x86-64/lapgen.scm
src/compiler/machines/x86-64/machin.scm
src/compiler/machines/x86-64/rules3.scm
src/microcode/cmpauxmd/x86-64.m4
src/microcode/cmpintmd/x86-64.c
src/microcode/cmpintmd/x86-64.h
src/microcode/gcloop.c