Changeset 8857 for branches/ia32/level-0


Ignore:
Timestamp:
Mar 22, 2008, 3:32:56 AM (12 years ago)
Author:
rme
Message:

New function %UPDATE-SELF-REFERENCES. Call it when fasloading functions
on x8632.

Location:
branches/ia32/level-0
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/ia32/level-0/X86/X8632/x8632-def.lisp

    r8691 r8857  
    1616
    1717(in-package "CCL")
     18
     19;;; Use the offsets in a function's self-reference table to replace
     20;;; the :self in (movl ($ :self) (% fn)) wih the function's actual
     21;;; address.
     22(defx8632lapfunction %update-self-references ((fun arg_z))
     23  (movzwl (@ x8632::misc-data-offset (% fun)) (% imm0)) ;imm word count
     24  (subl ($ 2) (% imm0))
     25  (box-fixnum imm0 temp0)               ;byte offset of first self-ref offset
     26  (movl (@ x8632::misc-data-offset (% fun) (% temp0)) (% imm0))
     27  (jmp @test)
     28  @loop
     29  (movl (% fun) (@ x8632::misc-header-offset (% fun) (% imm0)))
     30  (subl ($ '1) (% temp0))
     31  (movl (@ x8632::misc-data-offset (% fun) (% temp0)) (% imm0))
     32  @test
     33  (test (% imm0) (% imm0))
     34  (jne @loop)
     35  (single-value-return))
    1836
    1937(defx8632lapfunction %function-vector-to-function ((arg arg_z))
  • branches/ia32/level-0/nfasload.lisp

    r8215 r8857  
    344344    (%epushval s function)
    345345    (%fasl-read-n-bytes s vector 0 (ash size-of-code target::word-shift))
     346    #+x8632-target
     347    (%update-self-references vector)
    346348    (do* ((numconst (- size-in-elements size-of-code))
    347349          (i 0 (1+ i))
Note: See TracChangeset for help on using the changeset viewer.