x86-64: Improve symbol-value even without #!+immobile-symbols.
commitcd8131541577ddd4b229e75f34b5f44540cdc6fd
authorDouglas Katzman <dougk@google.com>
Thu, 6 Jul 2017 13:27:46 +0000 (6 09:27 -0400)
committerDouglas Katzman <dougk@google.com>
Thu, 6 Jul 2017 14:19:09 +0000 (6 10:19 -0400)
treebb54abc4d3cd78416512df5fb22fccd4f32a0690
parent4984858dc93d8eedc7ff836868a8c8466573753f
x86-64: Improve symbol-value even without #!+immobile-symbols.

Better code is generated for #!+immobile-space. The problem is determining
which symbols are immobile. Since the cross-compiler always uses immobile space
for symbols when it can, at least that much is easy to decide. The other case
is compilation to memory: if a symbol has a low address, it won't move.

Unfortunately, compiling to fasl can not make use of this, because after
deciding to use a 4-byte immediate operand to reference a symbol,
we'll lose badly if the loading process has the symbol at a high address.
src/compiler/tn.lisp
src/compiler/x86-64/memory.lisp
src/compiler/x86-64/move.lisp
src/compiler/x86-64/vm.lisp