Changeset 14607 for branches


Ignore:
Timestamp:
Jan 28, 2011, 9:49:58 PM (9 years ago)
Author:
rme
Message:

More tweaks; a cross-compiled Windows x86 lisp now bootstraps on Windows x64.

Location:
branches/shrink-tcr
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • branches/shrink-tcr/level-0/l0-misc.lisp

    r14606 r14607  
    277277        (values 0 0 0 0 0 0)
    278278        (multiple-value-bind (cf cu) (free-and-used cs-area)
    279           (multiple-value-bind (vf vu) (free-and-used (%fixnum-ref tcr target::tcr.vs-area))
     279          (multiple-value-bind (vf vu)
     280              (free-and-used (%fixnum-ref tcr (- target::tcr.vs-area
     281                                                 target::tcr-bias)))
    280282            #+arm-target
    281283            (values cf cu vf vu)
    282284            #-arm-target
    283             (multiple-value-bind (tf tu) (free-and-used (%fixnum-ref tcr target::tcr.ts-area ))
     285            (multiple-value-bind (tf tu)
     286                (free-and-used (%fixnum-ref tcr (- target::tcr.ts-area
     287                                                   target::tcr-bias)))
    284288              (values cf cu vf vu tf tu))))))))
    285289
  • branches/shrink-tcr/level-0/nfasload.lisp

    r14606 r14607  
    415415    (%epushval s (svref (faslstate.faslevec s) idx))))
    416416
    417 (defun decode-imm-word-count (imm-word-count element-count)
    418   (if (logbitp 15 imm-word-count)
    419     (- element-count (ldb (byte 15 0) imm-word-count))
    420     imm-word-count))
    421 
    422417#+x86-target
    423418;;; Read a "concatenated" lisp function, in which the machine code
     
    430425    (declare (fixnum size-in-elements size-of-code))
    431426    (%epushval s function)
    432     #+x8632-target
    433     (setq size-of-code (decode-imm-word-count size-of-code size-in-elements))
    434427    (%fasl-read-n-bytes s vector 0 (ash size-of-code target::word-shift))
    435428    #+x8632-target
  • branches/shrink-tcr/lib/nfcomp.lisp

    r14606 r14607  
    17731773           (function-size (ash (uvsize code) -2))
    17741774           (encoded-imm-words (dpb (uvref code 1) (byte 8 8) (uvref code 0)))
    1775            (imm-words (decode-imm-word-count encoded-imm-words function-size))
     1775           (imm-words (if (logbitp 15 encoded-imm-words)
     1776                        (- function-size (ldb (byte 15 0) encoded-imm-words))
     1777                        encoded-imm-words))
    17761778           (imm-bytes (ash imm-words 2))
    17771779           (other-words (- function-size imm-words)))
     
    17791781      (fasl-out-opcode $fasl-clfun f)
    17801782      (fasl-out-count function-size)
    1781       (fasl-out-count encoded-imm-words)
     1783      (fasl-out-count imm-words)
    17821784      (fasl-out-ivect code 0 imm-bytes)
    17831785      (do ((i 1 (1+ i))
  • branches/shrink-tcr/lib/x86-backtrace.lisp

    r13067 r14607  
    121121(defun %stack< (index1 index2 &optional context)
    122122  (let* ((tcr (if context (bt.tcr context) (%current-tcr)))
    123          (vs-area (%fixnum-ref tcr target::tcr.vs-area)))
     123         (vs-area (%fixnum-ref tcr (- target::tcr.vs-area
     124                                      target::tcr-bias))))
    124125    (and (%ptr-in-area-p index1 vs-area)
    125126         (%ptr-in-area-p index2 vs-area)
     
    300301(defun last-tsp-before (target)
    301302  (declare (fixnum target))
    302   (do* ((tsp (%fixnum-ref (%current-tcr) target::tcr.save-tsp)
     303  (do* ((tsp (%fixnum-ref (%current-tcr) (- target::tcr.save-tsp
     304                                            target::tcr-bias))
    303305             (%fixnum-ref tsp target::tsp-frame.backptr)))
    304306       ((zerop tsp) nil)
     
    315317(defun last-foreign-sp-before (target)
    316318  (declare (fixnum target))
    317   (do* ((cfp (%fixnum-ref (%current-tcr) target::tcr.foreign-sp)
     319  (do* ((cfp (%fixnum-ref (%current-tcr) (- target::tcr.foreign-sp
     320                                            target::tcr-bias))
    318321             (%fixnum-ref cfp target::csp-frame.backptr)))
    319322       ((zerop cfp))
     
    330333(defun %tsp-frame-containing-progv-binding (db)
    331334  (declare (fixnum db))
    332   (do* ((tsp (%fixnum-ref (%current-tcr) target::tcr.save-tsp) next)
     335  (do* ((tsp (%fixnum-ref (%current-tcr) (- target::tcr.save-tsp
     336                                            target::tcr-bias)) next)
    333337        (next (%fixnum-ref tsp target::tsp-frame.backptr)
    334338              (%fixnum-ref tsp target::tsp-frame.backptr)))
     
    353357  (do* ((db (%current-db-link) (%fixnum-ref db 0))
    354358        (tcr (%current-tcr))
    355         (vs-area (%fixnum-ref tcr target::tcr.vs-area))
     359        (vs-area (%fixnum-ref tcr (- target::tcr.vs-area
     360                                     target::tcr-bias)))
    356361        (vs-low (%fixnum-ref vs-area target::area.low))
    357362        (vs-high (%fixnum-ref vs-area target::area.high)))
  • branches/shrink-tcr/lisp-kernel/thread_manager.c

    r14606 r14607  
    13971397    tcr->interrupt_pending = 0;
    13981398    TCR_AUX(tcr)->termination_semaphore = NULL;
    1399 #ifdef HAVE_TLS
     1399#if defined(HAVE_TLS) || defined(WIN_32)
    14001400    dequeue_tcr(tcr);
    14011401#endif
     
    14081408    free(TCR_AUX(tcr)->native_thread_info);
    14091409    TCR_AUX(tcr)->native_thread_info = NULL;
     1410    free(tcr->aux);
    14101411#endif
    14111412    UNLOCK(lisp_global(TCR_AREA_LOCK),current);
     
    22282229#ifndef HAVE_TLS
    22292230#ifdef WIN32
    2230     free(current->aux);
     2231    /* free(current->aux); */
    22312232#else
    22322233    free(current);
  • branches/shrink-tcr/lisp-kernel/win32/Makefile

    r14606 r14607  
    2424ASFLAGS = -g --32
    2525M4FLAGS = -DWIN_32 -DWINDOWS -DX86 -DX8632
    26 CDEFINES = -DWIN_32 -DWINDOWS -D_REENTRANT -DX86 -DX8632 -D_GNU_SOURCE  -D__MSVCRT__ -D__MSVCRT_VERSION__=0x700 -D_WIN32_WINNT=0x0502 -DSVN_REVISION=$(SVN_REVISION) -DGC_INTEGRITY_CHECKING
     26CDEFINES = -DWIN_32 -DWINDOWS -D_REENTRANT -DX86 -DX8632 -D_GNU_SOURCE  -D__MSVCRT__ -D__MSVCRT_VERSION__=0x700 -D_WIN32_WINNT=0x0502 -DSVN_REVISION=$(SVN_REVISION)
    2727CDEBUG = -g
    28 COPT =
     28COPT = -O
    2929# Once in a while, -Wformat says something useful.  The odds are against that,
    3030# however.
Note: See TracChangeset for help on using the changeset viewer.