View | Details | Return to bug 29932
Collapse All | Expand All

(-)gcc/config/avr/predicates.md (-11 / +3 lines)
Lines 43-65 Link Here
43
  (and (match_code "reg")
43
  (and (match_code "reg")
44
       (match_test "REGNO (op) == REG_SP")))
44
       (match_test "REGNO (op) == REG_SP")))
45
;; Return true if OP is a valid address for an I/O register.
46
(define_predicate "io_address_operand"
47
  (and (match_code "const_int")
48
       (match_test "INTVAL (op) >= 0x20
49
                    && INTVAL (op) <= 0x60 - GET_MODE_SIZE (mode)")))
50
51
;; Return true if OP is a valid address for lower half of I/O space.
45
;; Return true if OP is a valid address for lower half of I/O space.
52
(define_predicate "low_io_address_operand"
46
(define_predicate "low_io_address_operand"
53
  (and (match_code "const_int")
47
  (and (match_code "const_int")
54
       (match_test "INTVAL (op) >= 0x20
48
       (match_test "IN_RANGE((INTVAL (op)), 0x20, 0x3F)")))
55
                    && INTVAL (op) <= 0x40 - GET_MODE_SIZE (mode)")))
49
56
57
;; Return true if OP is a valid address for higth half of I/O space.
50
;; Return true if OP is a valid address for higth half of I/O space.
58
(define_predicate "higth_io_address_operand"
51
(define_predicate "higth_io_address_operand"
59
  (and (match_code "const_int")
52
  (and (match_code "const_int")
60
       (match_test "INTVAL (op) >= 0x40
53
       (match_test "IN_RANGE((INTVAL (op)), 0x40, 0x5F)")))
61
                    && INTVAL (op) <= 0x60 - GET_MODE_SIZE (mode)")))
62
;; Return 1 if OP is the zero constant for MODE.
54
;; Return 1 if OP is the zero constant for MODE.
63
(define_predicate "const0_operand"
55
(define_predicate "const0_operand"

Return to bug 29932