Get rid of vm-support-routines indirection.
[sbcl.git] / src / compiler / mips / pred.lisp
1 (in-package "SB!VM")
2
3 \f
4 ;;;; The Branch VOP.
5
6 ;;; The unconditional branch, emitted when we can't drop through to the desired
7 ;;; destination.  Dest is the continuation we transfer control to.
8 ;;;
9 (define-vop (branch)
10   (:info dest)
11   (:generator 5
12     (inst b dest)
13     (inst nop)))
14
15 \f
16 ;;;; Generic conditional VOPs
17
18 ;;; The generic conditional branch, emitted immediately after test
19 ;;; VOPs that only set flags.
20
21 (define-vop (branch-if)
22   (:info dest flags not-p)
23   (:ignore dest flags not-p)
24   (:generator 0
25      (error "BRANCH-IF not yet implemented")))
26
27 (defun
28     convert-conditional-move-p (node dst-tn x-tn y-tn)
29   (declare (ignore node dst-tn x-tn y-tn))
30   nil)
31
32 \f
33 ;;;; Conditional VOPs:
34
35 (define-vop (if-eq)
36   (:args (x :scs (any-reg descriptor-reg zero null))
37          (y :scs (any-reg descriptor-reg zero null)))
38   (:conditional)
39   (:info target not-p)
40   (:policy :fast-safe)
41   (:translate eq)
42   (:generator 3
43     (if not-p
44         (inst bne x y target)
45         (inst beq x y target))
46     (inst nop)))
47
48