Changeset 6337


Ignore:
Timestamp:
Apr 22, 2007, 12:22:04 PM (15 years ago)
Author:
gb
Message:

Start to handle new "builtin" subprims.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/x8664-call/ccl/compiler/X86/x862.lisp

    r6333 r6337  
    13881388             (imm0 (make-wired-lreg x8664::imm0 :mode (get-regspec-mode s64-src))))
    13891389        (x862-copy-register seg imm0 s64-src)
    1390         (! call-subprim (subprim-name->offset '.SPmakes64))
     1390        (! xcall-subprim (subprim-name->offset '.SPnmakes64))
    13911391        (x862-copy-register seg node-dest arg_z)))))
    13921392
     
    14181418             (imm0 ($ x8664::imm0 :mode :u64)))
    14191419        (x862-copy-register seg imm0 u64-src)
    1420         (! call-subprim (subprim-name->offset '.SPmakeu64))
     1420        (! xcall-subprim (subprim-name->offset '.SPnmakeu64))
    14211421        (x862-copy-register seg node-dest arg_z)))))
    14221422
     
    24442444           (label-p (and (fixnump fn)
    24452445                         (locally (declare (fixnum fn))
    2446                            (and (= fn -1) (- fn)))))
     2446                           (and (= fn -2) (- fn)))))
    24472447           (tail-p (eq xfer $backend-return))
    24482448           (func (if (consp f-op) (%cadr f-op)))
     
    25032503              (if label-p
    25042504                (progn
    2505                   (! call-label (aref *backend-labels* 1)))
     2505                  (! call-label (aref *backend-labels* 2)))
    25062506                (progn
    25072507                  (if a-reg
     
    53635363        (! jump-subprim subprim)
    53645364        (progn
    5365           (! call-subprim subprim)
     5365          (setq subprim (+ (subprim-name->offset 'x8664::.spnbuiltin-plus)
     5366                           (- subprim
     5367                              (subprim-name->offset 'x8664::.spbuiltin-plus))))
     5368          (! xcall-subprim subprim)
    53665369          (<- ($ x8664::arg_z))
    53675370          (^))))))
     
    54335436          (x862-allocate-global-registers *x862-fcells* *x862-vcells* (afunc-all-vars afunc) no-regs))
    54345437        (@ (backend-get-next-label)) ; generic self-reference label, should be label #1
     5438        (! establish-fn)
     5439        (@ (backend-get-next-label)) ; self-call label
    54355440        (unless next-method-p
    54365441          (setq method-var nil))
     
    61376142        (let* ((index (arch::builtin-function-name-offset name))
    61386143               (idx-subprim (x862-builtin-index-subprim index)))
    6139           (! call-subprim-2 ($ x8664::arg_z) idx-subprim ($ x8664::arg_y) ($ x8664::arg_z)))
     6144          (setq idx-subprim (+ (subprim-name->offset 'x8664::.SPnbuiltin-plus)
     6145                               (- idx-subprim (subprim-name->offset 'x8664::.SPbuiltin-plus))))
     6146          (! xcall-subprim-2 ($ x8664::arg_z) idx-subprim ($ x8664::arg_y) ($ x8664::arg_z)))
    61406147        (@ done)
    61416148        (<- ($ x8664::arg_z))
     
    62966303(defx862 x862-self-call self-call (seg vreg xfer arglist &optional spread-p)
    62976304  (setq arglist (x862-augment-arglist *x862-cur-afunc* arglist (if spread-p 1 *x862-target-num-arg-regs*)))
    6298   (x862-call-fn seg vreg xfer -1 arglist spread-p))
     6305  (x862-call-fn seg vreg xfer -2 arglist spread-p))
    62996306
    63006307
     
    63276334      (! jump-subprim subprim)
    63286335      (progn
    6329         (! call-subprim subprim)
     6336        (setq subprim (+ (subprim-name->offset 'x8664::.SPnbuiltin-plus)
     6337                         (- subprim
     6338                            (subprim-name->offset 'x8664::.SPbuiltin-plus))))
     6339        (! xcall-subprim subprim)
    63306340        (<- x8664::arg_z)
    63316341        (^)))))
Note: See TracChangeset for help on using the changeset viewer.