OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-dev/] [fsf-gcc-snapshot-1-mar-12/] [or1k-gcc/] [gcc/] [config/] [arm/] [constraints.md] - Diff between revs 709 and 783

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 709 Rev 783
;; Constraint definitions for ARM and Thumb
;; Constraint definitions for ARM and Thumb
;; Copyright (C) 2006, 2007, 2008, 2010 Free Software Foundation, Inc.
;; Copyright (C) 2006, 2007, 2008, 2010 Free Software Foundation, Inc.
;; Contributed by ARM Ltd.
;; Contributed by ARM Ltd.
;; This file is part of GCC.
;; This file is part of GCC.
;; GCC is free software; you can redistribute it and/or modify it
;; GCC is free software; you can redistribute it and/or modify it
;; under the terms of the GNU General Public License as published
;; under the terms of the GNU General Public License as published
;; by the Free Software Foundation; either version 3, or (at your
;; by the Free Software Foundation; either version 3, or (at your
;; option) any later version.
;; option) any later version.
;; GCC is distributed in the hope that it will be useful, but WITHOUT
;; GCC is distributed in the hope that it will be useful, but WITHOUT
;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
;; or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
;; or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
;; License for more details.
;; License for more details.
;; You should have received a copy of the GNU General Public License
;; You should have received a copy of the GNU General Public License
;; along with GCC; see the file COPYING3.  If not see
;; along with GCC; see the file COPYING3.  If not see
;; .
;; .
;; The following register constraints have been used:
;; The following register constraints have been used:
;; - in ARM/Thumb-2 state: f, t, v, w, x, y, z
;; - in ARM/Thumb-2 state: f, t, v, w, x, y, z
;; - in Thumb state: h, b
;; - in Thumb state: h, b
;; - in both states: l, c, k
;; - in both states: l, c, k
;; In ARM state, 'l' is an alias for 'r'
;; In ARM state, 'l' is an alias for 'r'
;; The following normal constraints have been used:
;; The following normal constraints have been used:
;; in ARM/Thumb-2 state: G, H, I, j, J, K, L, M
;; in ARM/Thumb-2 state: G, H, I, j, J, K, L, M
;; in Thumb-1 state: I, J, K, L, M, N, O
;; in Thumb-1 state: I, J, K, L, M, N, O
;; The following multi-letter normal constraints have been used:
;; The following multi-letter normal constraints have been used:
;; in ARM/Thumb-2 state: Da, Db, Dc, Dn, Dl, DL, Dv, Dy, Di, Dt, Dz
;; in ARM/Thumb-2 state: Da, Db, Dc, Dn, Dl, DL, Dv, Dy, Di, Dt, Dz
;; in Thumb-1 state: Pa, Pb, Pc, Pd
;; in Thumb-1 state: Pa, Pb, Pc, Pd
;; in Thumb-2 state: Pj, PJ, Ps, Pt, Pu, Pv, Pw, Px, Py
;; in Thumb-2 state: Pj, PJ, Ps, Pt, Pu, Pv, Pw, Px, Py
;; The following memory constraints have been used:
;; The following memory constraints have been used:
;; in ARM/Thumb-2 state: Q, Ut, Uv, Uy, Un, Um, Us
;; in ARM/Thumb-2 state: Q, Ut, Uv, Uy, Un, Um, Us
;; in ARM state: Uq
;; in ARM state: Uq
;; in Thumb state: Uu, Uw
;; in Thumb state: Uu, Uw
(define_register_constraint "f" "TARGET_ARM ? FPA_REGS : NO_REGS"
(define_register_constraint "f" "TARGET_ARM ? FPA_REGS : NO_REGS"
 "Legacy FPA registers @code{f0}-@code{f7}.")
 "Legacy FPA registers @code{f0}-@code{f7}.")
(define_register_constraint "t" "TARGET_32BIT ? VFP_LO_REGS : NO_REGS"
(define_register_constraint "t" "TARGET_32BIT ? VFP_LO_REGS : NO_REGS"
 "The VFP registers @code{s0}-@code{s31}.")
 "The VFP registers @code{s0}-@code{s31}.")
(define_register_constraint "v" "TARGET_ARM ? CIRRUS_REGS : NO_REGS"
(define_register_constraint "v" "TARGET_ARM ? CIRRUS_REGS : NO_REGS"
 "The Cirrus Maverick co-processor registers.")
 "The Cirrus Maverick co-processor registers.")
(define_register_constraint "w"
(define_register_constraint "w"
  "TARGET_32BIT ? (TARGET_VFPD32 ? VFP_REGS : VFP_LO_REGS) : NO_REGS"
  "TARGET_32BIT ? (TARGET_VFPD32 ? VFP_REGS : VFP_LO_REGS) : NO_REGS"
 "The VFP registers @code{d0}-@code{d15}, or @code{d0}-@code{d31} for VFPv3.")
 "The VFP registers @code{d0}-@code{d15}, or @code{d0}-@code{d31} for VFPv3.")
(define_register_constraint "x" "TARGET_32BIT ? VFP_D0_D7_REGS : NO_REGS"
(define_register_constraint "x" "TARGET_32BIT ? VFP_D0_D7_REGS : NO_REGS"
 "The VFP registers @code{d0}-@code{d7}.")
 "The VFP registers @code{d0}-@code{d7}.")
(define_register_constraint "y" "TARGET_REALLY_IWMMXT ? IWMMXT_REGS : NO_REGS"
(define_register_constraint "y" "TARGET_REALLY_IWMMXT ? IWMMXT_REGS : NO_REGS"
 "The Intel iWMMX co-processor registers.")
 "The Intel iWMMX co-processor registers.")
(define_register_constraint "z"
(define_register_constraint "z"
 "TARGET_REALLY_IWMMXT ? IWMMXT_GR_REGS : NO_REGS"
 "TARGET_REALLY_IWMMXT ? IWMMXT_GR_REGS : NO_REGS"
 "The Intel iWMMX GR registers.")
 "The Intel iWMMX GR registers.")
(define_register_constraint "l" "TARGET_THUMB ? LO_REGS : GENERAL_REGS"
(define_register_constraint "l" "TARGET_THUMB ? LO_REGS : GENERAL_REGS"
 "In Thumb state the core registers @code{r0}-@code{r7}.")
 "In Thumb state the core registers @code{r0}-@code{r7}.")
(define_register_constraint "h" "TARGET_THUMB ? HI_REGS : NO_REGS"
(define_register_constraint "h" "TARGET_THUMB ? HI_REGS : NO_REGS"
 "In Thumb state the core registers @code{r8}-@code{r15}.")
 "In Thumb state the core registers @code{r8}-@code{r15}.")
(define_constraint "j"
(define_constraint "j"
 "A constant suitable for a MOVW instruction. (ARM/Thumb-2)"
 "A constant suitable for a MOVW instruction. (ARM/Thumb-2)"
 (and (match_test "TARGET_32BIT && arm_arch_thumb2")
 (and (match_test "TARGET_32BIT && arm_arch_thumb2")
      (ior (match_code "high")
      (ior (match_code "high")
           (and (match_code "const_int")
           (and (match_code "const_int")
                (match_test "(ival & 0xffff0000) == 0")))))
                (match_test "(ival & 0xffff0000) == 0")))))
(define_constraint "Pj"
(define_constraint "Pj"
 "@internal A 12-bit constant suitable for an ADDW or SUBW instruction. (Thumb-2)"
 "@internal A 12-bit constant suitable for an ADDW or SUBW instruction. (Thumb-2)"
 (and (match_code "const_int")
 (and (match_code "const_int")
      (and (match_test "TARGET_THUMB2")
      (and (match_test "TARGET_THUMB2")
           (match_test "(ival & 0xfffff000) == 0"))))
           (match_test "(ival & 0xfffff000) == 0"))))
(define_constraint "PJ"
(define_constraint "PJ"
 "@internal A constant that satisfies the Pj constrant if negated."
 "@internal A constant that satisfies the Pj constrant if negated."
 (and (match_code "const_int")
 (and (match_code "const_int")
      (and (match_test "TARGET_THUMB2")
      (and (match_test "TARGET_THUMB2")
           (match_test "((-ival) & 0xfffff000) == 0"))))
           (match_test "((-ival) & 0xfffff000) == 0"))))
(define_register_constraint "k" "STACK_REG"
(define_register_constraint "k" "STACK_REG"
 "@internal The stack register.")
 "@internal The stack register.")
(define_register_constraint "b" "TARGET_THUMB ? BASE_REGS : NO_REGS"
(define_register_constraint "b" "TARGET_THUMB ? BASE_REGS : NO_REGS"
 "@internal
 "@internal
  Thumb only.  The union of the low registers and the stack register.")
  Thumb only.  The union of the low registers and the stack register.")
(define_register_constraint "c" "CC_REG"
(define_register_constraint "c" "CC_REG"
 "@internal The condition code register.")
 "@internal The condition code register.")
(define_constraint "I"
(define_constraint "I"
 "In ARM/Thumb-2 state a constant that can be used as an immediate value in a
 "In ARM/Thumb-2 state a constant that can be used as an immediate value in a
  Data Processing instruction.  In Thumb-1 state a constant in the range
  Data Processing instruction.  In Thumb-1 state a constant in the range
  0-255."
  0-255."
 (and (match_code "const_int")
 (and (match_code "const_int")
      (match_test "TARGET_32BIT ? const_ok_for_arm (ival)
      (match_test "TARGET_32BIT ? const_ok_for_arm (ival)
                   : ival >= 0 && ival <= 255")))
                   : ival >= 0 && ival <= 255")))
(define_constraint "J"
(define_constraint "J"
 "In ARM/Thumb-2 state a constant in the range @minus{}4095-4095.  In Thumb-1
 "In ARM/Thumb-2 state a constant in the range @minus{}4095-4095.  In Thumb-1
  state a constant in the range @minus{}255-@minus{}1."
  state a constant in the range @minus{}255-@minus{}1."
 (and (match_code "const_int")
 (and (match_code "const_int")
      (match_test "TARGET_32BIT ? (ival >= -4095 && ival <= 4095)
      (match_test "TARGET_32BIT ? (ival >= -4095 && ival <= 4095)
                   : (ival >= -255 && ival <= -1)")))
                   : (ival >= -255 && ival <= -1)")))
(define_constraint "K"
(define_constraint "K"
 "In ARM/Thumb-2 state a constant that satisfies the @code{I} constraint if
 "In ARM/Thumb-2 state a constant that satisfies the @code{I} constraint if
  inverted.  In Thumb-1 state a constant that satisfies the @code{I}
  inverted.  In Thumb-1 state a constant that satisfies the @code{I}
  constraint multiplied by any power of 2."
  constraint multiplied by any power of 2."
 (and (match_code "const_int")
 (and (match_code "const_int")
      (match_test "TARGET_32BIT ? const_ok_for_arm (~ival)
      (match_test "TARGET_32BIT ? const_ok_for_arm (~ival)
                   : thumb_shiftable_const (ival)")))
                   : thumb_shiftable_const (ival)")))
(define_constraint "L"
(define_constraint "L"
 "In ARM/Thumb-2 state a constant that satisfies the @code{I} constraint if
 "In ARM/Thumb-2 state a constant that satisfies the @code{I} constraint if
  negated.  In Thumb-1 state a constant in the range @minus{}7-7."
  negated.  In Thumb-1 state a constant in the range @minus{}7-7."
 (and (match_code "const_int")
 (and (match_code "const_int")
      (match_test "TARGET_32BIT ? const_ok_for_arm (-ival)
      (match_test "TARGET_32BIT ? const_ok_for_arm (-ival)
                   : (ival >= -7 && ival <= 7)")))
                   : (ival >= -7 && ival <= 7)")))
;; The ARM state version is internal...
;; The ARM state version is internal...
;; @internal In ARM/Thumb-2 state a constant in the range 0-32 or any
;; @internal In ARM/Thumb-2 state a constant in the range 0-32 or any
;; power of 2.
;; power of 2.
(define_constraint "M"
(define_constraint "M"
 "In Thumb-1 state a constant that is a multiple of 4 in the range 0-1020."
 "In Thumb-1 state a constant that is a multiple of 4 in the range 0-1020."
 (and (match_code "const_int")
 (and (match_code "const_int")
      (match_test "TARGET_32BIT ? ((ival >= 0 && ival <= 32)
      (match_test "TARGET_32BIT ? ((ival >= 0 && ival <= 32)
                                 || (((ival & (ival - 1)) & 0xFFFFFFFF) == 0))
                                 || (((ival & (ival - 1)) & 0xFFFFFFFF) == 0))
                   : ival >= 0 && ival <= 1020 && (ival & 3) == 0")))
                   : ival >= 0 && ival <= 1020 && (ival & 3) == 0")))
(define_constraint "N"
(define_constraint "N"
 "Thumb-1 state a constant in the range 0-31."
 "Thumb-1 state a constant in the range 0-31."
 (and (match_code "const_int")
 (and (match_code "const_int")
      (match_test "!TARGET_32BIT && (ival >= 0 && ival <= 31)")))
      (match_test "!TARGET_32BIT && (ival >= 0 && ival <= 31)")))
(define_constraint "O"
(define_constraint "O"
 "In Thumb-1 state a constant that is a multiple of 4 in the range
 "In Thumb-1 state a constant that is a multiple of 4 in the range
  @minus{}508-508."
  @minus{}508-508."
 (and (match_code "const_int")
 (and (match_code "const_int")
      (match_test "TARGET_THUMB1 && ival >= -508 && ival <= 508
      (match_test "TARGET_THUMB1 && ival >= -508 && ival <= 508
                   && ((ival & 3) == 0)")))
                   && ((ival & 3) == 0)")))
(define_constraint "Pa"
(define_constraint "Pa"
  "@internal In Thumb-1 state a constant in the range -510 to +510"
  "@internal In Thumb-1 state a constant in the range -510 to +510"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB1 && ival >= -510 && ival <= 510
       (match_test "TARGET_THUMB1 && ival >= -510 && ival <= 510
                    && (ival > 255 || ival < -255)")))
                    && (ival > 255 || ival < -255)")))
(define_constraint "Pb"
(define_constraint "Pb"
  "@internal In Thumb-1 state a constant in the range -262 to +262"
  "@internal In Thumb-1 state a constant in the range -262 to +262"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB1 && ival >= -262 && ival <= 262
       (match_test "TARGET_THUMB1 && ival >= -262 && ival <= 262
                    && (ival > 255 || ival < -255)")))
                    && (ival > 255 || ival < -255)")))
(define_constraint "Pc"
(define_constraint "Pc"
  "@internal In Thumb-1 state a constant that is in the range 1021 to 1275"
  "@internal In Thumb-1 state a constant that is in the range 1021 to 1275"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB1
       (match_test "TARGET_THUMB1
                    && ival > 1020 && ival <= 1275")))
                    && ival > 1020 && ival <= 1275")))
(define_constraint "Pd"
(define_constraint "Pd"
  "@internal In Thumb-1 state a constant in the range 0 to 7"
  "@internal In Thumb-1 state a constant in the range 0 to 7"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB1 && ival >= 0 && ival <= 7")))
       (match_test "TARGET_THUMB1 && ival >= 0 && ival <= 7")))
(define_constraint "Ps"
(define_constraint "Ps"
  "@internal In Thumb-2 state a constant in the range -255 to +255"
  "@internal In Thumb-2 state a constant in the range -255 to +255"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB2 && ival >= -255 && ival <= 255")))
       (match_test "TARGET_THUMB2 && ival >= -255 && ival <= 255")))
(define_constraint "Pt"
(define_constraint "Pt"
  "@internal In Thumb-2 state a constant in the range -7 to +7"
  "@internal In Thumb-2 state a constant in the range -7 to +7"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB2 && ival >= -7 && ival <= 7")))
       (match_test "TARGET_THUMB2 && ival >= -7 && ival <= 7")))
(define_constraint "Pu"
(define_constraint "Pu"
  "@internal In Thumb-2 state a constant in the range +1 to +8"
  "@internal In Thumb-2 state a constant in the range +1 to +8"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB2 && ival >= 1 && ival <= 8")))
       (match_test "TARGET_THUMB2 && ival >= 1 && ival <= 8")))
(define_constraint "Pv"
(define_constraint "Pv"
  "@internal In Thumb-2 state a constant in the range -255 to 0"
  "@internal In Thumb-2 state a constant in the range -255 to 0"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB2 && ival >= -255 && ival <= 0")))
       (match_test "TARGET_THUMB2 && ival >= -255 && ival <= 0")))
(define_constraint "Pw"
(define_constraint "Pw"
  "@internal In Thumb-2 state a constant in the range -255 to -1"
  "@internal In Thumb-2 state a constant in the range -255 to -1"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB2 && ival >= -255 && ival <= -1")))
       (match_test "TARGET_THUMB2 && ival >= -255 && ival <= -1")))
(define_constraint "Px"
(define_constraint "Px"
  "@internal In Thumb-2 state a constant in the range -7 to -1"
  "@internal In Thumb-2 state a constant in the range -7 to -1"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB2 && ival >= -7 && ival <= -1")))
       (match_test "TARGET_THUMB2 && ival >= -7 && ival <= -1")))
(define_constraint "Py"
(define_constraint "Py"
  "@internal In Thumb-2 state a constant in the range 0 to 255"
  "@internal In Thumb-2 state a constant in the range 0 to 255"
  (and (match_code "const_int")
  (and (match_code "const_int")
       (match_test "TARGET_THUMB2 && ival >= 0 && ival <= 255")))
       (match_test "TARGET_THUMB2 && ival >= 0 && ival <= 255")))
(define_constraint "G"
(define_constraint "G"
 "In ARM/Thumb-2 state a valid FPA immediate constant."
 "In ARM/Thumb-2 state a valid FPA immediate constant."
 (and (match_code "const_double")
 (and (match_code "const_double")
      (match_test "TARGET_32BIT && arm_const_double_rtx (op)")))
      (match_test "TARGET_32BIT && arm_const_double_rtx (op)")))
(define_constraint "H"
(define_constraint "H"
 "In ARM/Thumb-2 state a valid FPA immediate constant when negated."
 "In ARM/Thumb-2 state a valid FPA immediate constant when negated."
 (and (match_code "const_double")
 (and (match_code "const_double")
      (match_test "TARGET_32BIT && neg_const_double_rtx_ok_for_fpa (op)")))
      (match_test "TARGET_32BIT && neg_const_double_rtx_ok_for_fpa (op)")))
(define_constraint "Dz"
(define_constraint "Dz"
 "@internal
 "@internal
  In ARM/Thumb-2 state a vector of constant zeros."
  In ARM/Thumb-2 state a vector of constant zeros."
 (and (match_code "const_vector")
 (and (match_code "const_vector")
      (match_test "TARGET_NEON && op == CONST0_RTX (mode)")))
      (match_test "TARGET_NEON && op == CONST0_RTX (mode)")))
(define_constraint "Da"
(define_constraint "Da"
 "@internal
 "@internal
  In ARM/Thumb-2 state a const_int, const_double or const_vector that can
  In ARM/Thumb-2 state a const_int, const_double or const_vector that can
  be generated with two Data Processing insns."
  be generated with two Data Processing insns."
 (and (match_code "const_double,const_int,const_vector")
 (and (match_code "const_double,const_int,const_vector")
      (match_test "TARGET_32BIT && arm_const_double_inline_cost (op) == 2")))
      (match_test "TARGET_32BIT && arm_const_double_inline_cost (op) == 2")))
(define_constraint "Db"
(define_constraint "Db"
 "@internal
 "@internal
  In ARM/Thumb-2 state a const_int, const_double or const_vector that can
  In ARM/Thumb-2 state a const_int, const_double or const_vector that can
  be generated with three Data Processing insns."
  be generated with three Data Processing insns."
 (and (match_code "const_double,const_int,const_vector")
 (and (match_code "const_double,const_int,const_vector")
      (match_test "TARGET_32BIT && arm_const_double_inline_cost (op) == 3")))
      (match_test "TARGET_32BIT && arm_const_double_inline_cost (op) == 3")))
(define_constraint "Dc"
(define_constraint "Dc"
 "@internal
 "@internal
  In ARM/Thumb-2 state a const_int, const_double or const_vector that can
  In ARM/Thumb-2 state a const_int, const_double or const_vector that can
  be generated with four Data Processing insns.  This pattern is disabled
  be generated with four Data Processing insns.  This pattern is disabled
  if optimizing for space or when we have load-delay slots to fill."
  if optimizing for space or when we have load-delay slots to fill."
 (and (match_code "const_double,const_int,const_vector")
 (and (match_code "const_double,const_int,const_vector")
      (match_test "TARGET_32BIT && arm_const_double_inline_cost (op) == 4
      (match_test "TARGET_32BIT && arm_const_double_inline_cost (op) == 4
                   && !(optimize_size || arm_ld_sched)")))
                   && !(optimize_size || arm_ld_sched)")))
(define_constraint "Di"
(define_constraint "Di"
 "@internal
 "@internal
  In ARM/Thumb-2 state a const_int or const_double where both the high
  In ARM/Thumb-2 state a const_int or const_double where both the high
  and low SImode words can be generated as immediates in 32-bit instructions."
  and low SImode words can be generated as immediates in 32-bit instructions."
 (and (match_code "const_double,const_int")
 (and (match_code "const_double,const_int")
      (match_test "TARGET_32BIT && arm_const_double_by_immediates (op)")))
      (match_test "TARGET_32BIT && arm_const_double_by_immediates (op)")))
(define_constraint "Dn"
(define_constraint "Dn"
 "@internal
 "@internal
  In ARM/Thumb-2 state a const_vector which can be loaded with a Neon vmov
  In ARM/Thumb-2 state a const_vector which can be loaded with a Neon vmov
  immediate instruction."
  immediate instruction."
 (and (match_code "const_vector")
 (and (match_code "const_vector")
      (match_test "TARGET_32BIT
      (match_test "TARGET_32BIT
                   && imm_for_neon_mov_operand (op, GET_MODE (op))")))
                   && imm_for_neon_mov_operand (op, GET_MODE (op))")))
(define_constraint "Dl"
(define_constraint "Dl"
 "@internal
 "@internal
  In ARM/Thumb-2 state a const_vector which can be used with a Neon vorr or
  In ARM/Thumb-2 state a const_vector which can be used with a Neon vorr or
  vbic instruction."
  vbic instruction."
 (and (match_code "const_vector")
 (and (match_code "const_vector")
      (match_test "TARGET_32BIT
      (match_test "TARGET_32BIT
                   && imm_for_neon_logic_operand (op, GET_MODE (op))")))
                   && imm_for_neon_logic_operand (op, GET_MODE (op))")))
(define_constraint "DL"
(define_constraint "DL"
 "@internal
 "@internal
  In ARM/Thumb-2 state a const_vector which can be used with a Neon vorn or
  In ARM/Thumb-2 state a const_vector which can be used with a Neon vorn or
  vand instruction."
  vand instruction."
 (and (match_code "const_vector")
 (and (match_code "const_vector")
      (match_test "TARGET_32BIT
      (match_test "TARGET_32BIT
                   && imm_for_neon_inv_logic_operand (op, GET_MODE (op))")))
                   && imm_for_neon_inv_logic_operand (op, GET_MODE (op))")))
(define_constraint "Dv"
(define_constraint "Dv"
 "@internal
 "@internal
  In ARM/Thumb-2 state a const_double which can be used with a VFP fconsts
  In ARM/Thumb-2 state a const_double which can be used with a VFP fconsts
  instruction."
  instruction."
 (and (match_code "const_double")
 (and (match_code "const_double")
      (match_test "TARGET_32BIT && vfp3_const_double_rtx (op)")))
      (match_test "TARGET_32BIT && vfp3_const_double_rtx (op)")))
(define_constraint "Dy"
(define_constraint "Dy"
 "@internal
 "@internal
  In ARM/Thumb-2 state a const_double which can be used with a VFP fconstd
  In ARM/Thumb-2 state a const_double which can be used with a VFP fconstd
  instruction."
  instruction."
 (and (match_code "const_double")
 (and (match_code "const_double")
      (match_test "TARGET_32BIT && TARGET_VFP_DOUBLE && vfp3_const_double_rtx (op)")))
      (match_test "TARGET_32BIT && TARGET_VFP_DOUBLE && vfp3_const_double_rtx (op)")))
(define_constraint "Dt"
(define_constraint "Dt"
 "@internal
 "@internal
  In ARM/ Thumb2 a const_double which can be used with a vcvt.f32.s32 with fract bits operation"
  In ARM/ Thumb2 a const_double which can be used with a vcvt.f32.s32 with fract bits operation"
  (and (match_code "const_double")
  (and (match_code "const_double")
       (match_test "TARGET_32BIT && TARGET_VFP && vfp3_const_double_for_fract_bits (op)")))
       (match_test "TARGET_32BIT && TARGET_VFP && vfp3_const_double_for_fract_bits (op)")))
(define_memory_constraint "Ua"
(define_memory_constraint "Ua"
 "@internal
 "@internal
  An address valid for loading/storing register exclusive"
  An address valid for loading/storing register exclusive"
 (match_operand 0 "mem_noofs_operand"))
 (match_operand 0 "mem_noofs_operand"))
(define_memory_constraint "Ut"
(define_memory_constraint "Ut"
 "@internal
 "@internal
  In ARM/Thumb-2 state an address valid for loading/storing opaque structure
  In ARM/Thumb-2 state an address valid for loading/storing opaque structure
  types wider than TImode."
  types wider than TImode."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "TARGET_32BIT && neon_struct_mem_operand (op)")))
      (match_test "TARGET_32BIT && neon_struct_mem_operand (op)")))
(define_memory_constraint "Uv"
(define_memory_constraint "Uv"
 "@internal
 "@internal
  In ARM/Thumb-2 state a valid VFP load/store address."
  In ARM/Thumb-2 state a valid VFP load/store address."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "TARGET_32BIT && arm_coproc_mem_operand (op, FALSE)")))
      (match_test "TARGET_32BIT && arm_coproc_mem_operand (op, FALSE)")))
(define_memory_constraint "Uy"
(define_memory_constraint "Uy"
 "@internal
 "@internal
  In ARM/Thumb-2 state a valid iWMMX load/store address."
  In ARM/Thumb-2 state a valid iWMMX load/store address."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "TARGET_32BIT && arm_coproc_mem_operand (op, TRUE)")))
      (match_test "TARGET_32BIT && arm_coproc_mem_operand (op, TRUE)")))
(define_memory_constraint "Un"
(define_memory_constraint "Un"
 "@internal
 "@internal
  In ARM/Thumb-2 state a valid address for Neon doubleword vector
  In ARM/Thumb-2 state a valid address for Neon doubleword vector
  load/store instructions."
  load/store instructions."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "TARGET_32BIT && neon_vector_mem_operand (op, 0)")))
      (match_test "TARGET_32BIT && neon_vector_mem_operand (op, 0)")))
(define_memory_constraint "Um"
(define_memory_constraint "Um"
 "@internal
 "@internal
  In ARM/Thumb-2 state a valid address for Neon element and structure
  In ARM/Thumb-2 state a valid address for Neon element and structure
  load/store instructions."
  load/store instructions."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "TARGET_32BIT && neon_vector_mem_operand (op, 2)")))
      (match_test "TARGET_32BIT && neon_vector_mem_operand (op, 2)")))
(define_memory_constraint "Us"
(define_memory_constraint "Us"
 "@internal
 "@internal
  In ARM/Thumb-2 state a valid address for non-offset loads/stores of
  In ARM/Thumb-2 state a valid address for non-offset loads/stores of
  quad-word values in four ARM registers."
  quad-word values in four ARM registers."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "TARGET_32BIT && neon_vector_mem_operand (op, 1)")))
      (match_test "TARGET_32BIT && neon_vector_mem_operand (op, 1)")))
(define_memory_constraint "Uq"
(define_memory_constraint "Uq"
 "@internal
 "@internal
  In ARM state an address valid in ldrsb instructions."
  In ARM state an address valid in ldrsb instructions."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "TARGET_ARM
      (match_test "TARGET_ARM
                   && arm_legitimate_address_outer_p (GET_MODE (op), XEXP (op, 0),
                   && arm_legitimate_address_outer_p (GET_MODE (op), XEXP (op, 0),
                                                      SIGN_EXTEND, 0)")))
                                                      SIGN_EXTEND, 0)")))
(define_memory_constraint "Q"
(define_memory_constraint "Q"
 "@internal
 "@internal
  In ARM/Thumb-2 state an address that is a single base register."
  In ARM/Thumb-2 state an address that is a single base register."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "REG_P (XEXP (op, 0))")))
      (match_test "REG_P (XEXP (op, 0))")))
(define_memory_constraint "Uu"
(define_memory_constraint "Uu"
 "@internal
 "@internal
  In Thumb state an address that is valid in 16bit encoding."
  In Thumb state an address that is valid in 16bit encoding."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "TARGET_THUMB
      (match_test "TARGET_THUMB
                   && thumb1_legitimate_address_p (GET_MODE (op), XEXP (op, 0),
                   && thumb1_legitimate_address_p (GET_MODE (op), XEXP (op, 0),
                                                   0)")))
                                                   0)")))
; The 16-bit post-increment LDR/STR accepted by thumb1_legitimate_address_p
; The 16-bit post-increment LDR/STR accepted by thumb1_legitimate_address_p
; are actually LDM/STM instructions, so cannot be used to access unaligned
; are actually LDM/STM instructions, so cannot be used to access unaligned
; data.
; data.
(define_memory_constraint "Uw"
(define_memory_constraint "Uw"
 "@internal
 "@internal
  In Thumb state an address that is valid in 16bit encoding, and that can be
  In Thumb state an address that is valid in 16bit encoding, and that can be
  used for unaligned accesses."
  used for unaligned accesses."
 (and (match_code "mem")
 (and (match_code "mem")
      (match_test "TARGET_THUMB
      (match_test "TARGET_THUMB
                   && thumb1_legitimate_address_p (GET_MODE (op), XEXP (op, 0),
                   && thumb1_legitimate_address_p (GET_MODE (op), XEXP (op, 0),
                                                   0)
                                                   0)
                   && GET_CODE (XEXP (op, 0)) != POST_INC")))
                   && GET_CODE (XEXP (op, 0)) != POST_INC")))
;; We used to have constraint letters for S and R in ARM state, but
;; We used to have constraint letters for S and R in ARM state, but
;; all uses of these now appear to have been removed.
;; all uses of these now appear to have been removed.
;; Additionally, we used to have a Q constraint in Thumb state, but
;; Additionally, we used to have a Q constraint in Thumb state, but
;; this wasn't really a valid memory constraint.  Again, all uses of
;; this wasn't really a valid memory constraint.  Again, all uses of
;; this now seem to have been removed.
;; this now seem to have been removed.
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.