| 1 |
709 |
jeremybenn |
;; Scheduling description for IBM PowerPC 476 processor.
|
| 2 |
|
|
;; Copyright (C) 2009
|
| 3 |
|
|
;; Free Software Foundation, Inc.
|
| 4 |
|
|
;; Contributed by Peter Bergner (bergner@vnet.ibm.com).
|
| 5 |
|
|
;;
|
| 6 |
|
|
;; This file is part of GCC.
|
| 7 |
|
|
;;
|
| 8 |
|
|
;; GCC is free software; you can redistribute it and/or modify
|
| 9 |
|
|
;; it under the terms of the GNU General Public License as published by
|
| 10 |
|
|
;; the Free Software Foundation; either version 3, or (at your option)
|
| 11 |
|
|
;; any later version.
|
| 12 |
|
|
;;
|
| 13 |
|
|
;; GCC is distributed in the hope that it will be useful,
|
| 14 |
|
|
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
| 15 |
|
|
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
| 16 |
|
|
;; GNU General Public License for more details.
|
| 17 |
|
|
;;
|
| 18 |
|
|
;; You should have received a copy of the GNU General Public License
|
| 19 |
|
|
;; along with GCC; see the file COPYING3. If not see
|
| 20 |
|
|
;; .
|
| 21 |
|
|
|
| 22 |
|
|
;; PPC476 Embedded PowerPC controller
|
| 23 |
|
|
;; 3 issue (476) / 4 issue (476fp)
|
| 24 |
|
|
;;
|
| 25 |
|
|
;; i_pipe - complex integer / compare
|
| 26 |
|
|
;; lj_pipe - load-store / simple integer arithmetic
|
| 27 |
|
|
;; b_pipe - branch pipe
|
| 28 |
|
|
;; f_pipe - floating point arithmetic
|
| 29 |
|
|
|
| 30 |
|
|
(define_automaton "ppc476_core,ppc476_apu")
|
| 31 |
|
|
|
| 32 |
|
|
(define_cpu_unit "ppc476_i_pipe,ppc476_lj_pipe,ppc476_b_pipe" "ppc476_core")
|
| 33 |
|
|
(define_cpu_unit "ppc476_issue_fp,ppc476_f_pipe" "ppc476_apu")
|
| 34 |
|
|
(define_cpu_unit "ppc476_issue_0,ppc476_issue_1,ppc476_issue_2" "ppc476_core")
|
| 35 |
|
|
|
| 36 |
|
|
(define_reservation "ppc476_issue" "ppc476_issue_0|ppc476_issue_1|ppc476_issue_2")
|
| 37 |
|
|
(define_reservation "ppc476_issue2" "ppc476_issue_0+ppc476_issue_1\
|
| 38 |
|
|
|ppc476_issue_0+ppc476_issue_2\
|
| 39 |
|
|
|ppc476_issue_1+ppc476_issue_2")
|
| 40 |
|
|
(define_reservation "ppc476_issue3" "ppc476_issue_0+ppc476_issue_1+ppc476_issue_2")
|
| 41 |
|
|
|
| 42 |
|
|
(define_insn_reservation "ppc476-load" 4
|
| 43 |
|
|
(and (eq_attr "type" "load,load_ext,load_ext_u,load_ext_ux,load_ux,load_u,\
|
| 44 |
|
|
load_l,store_c,sync")
|
| 45 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 46 |
|
|
"ppc476_issue,\
|
| 47 |
|
|
ppc476_lj_pipe")
|
| 48 |
|
|
|
| 49 |
|
|
(define_insn_reservation "ppc476-store" 4
|
| 50 |
|
|
(and (eq_attr "type" "store,store_ux,store_u")
|
| 51 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 52 |
|
|
"ppc476_issue,\
|
| 53 |
|
|
ppc476_lj_pipe")
|
| 54 |
|
|
|
| 55 |
|
|
(define_insn_reservation "ppc476-fpload" 4
|
| 56 |
|
|
(and (eq_attr "type" "fpload,fpload_ux,fpload_u")
|
| 57 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 58 |
|
|
"ppc476_issue,\
|
| 59 |
|
|
ppc476_lj_pipe")
|
| 60 |
|
|
|
| 61 |
|
|
(define_insn_reservation "ppc476-fpstore" 4
|
| 62 |
|
|
(and (eq_attr "type" "fpstore,fpstore_ux,fpstore_u")
|
| 63 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 64 |
|
|
"ppc476_issue,\
|
| 65 |
|
|
ppc476_lj_pipe")
|
| 66 |
|
|
|
| 67 |
|
|
(define_insn_reservation "ppc476-simple-integer" 1
|
| 68 |
|
|
(and (eq_attr "type" "integer,insert_word,var_shift_rotate,exts,shift")
|
| 69 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 70 |
|
|
"ppc476_issue,\
|
| 71 |
|
|
ppc476_i_pipe|ppc476_lj_pipe")
|
| 72 |
|
|
|
| 73 |
|
|
(define_insn_reservation "ppc476-complex-integer" 1
|
| 74 |
|
|
(and (eq_attr "type" "cmp,cr_logical,delayed_cr,cntlz,isel,isync,sync,trap")
|
| 75 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 76 |
|
|
"ppc476_issue,\
|
| 77 |
|
|
ppc476_i_pipe")
|
| 78 |
|
|
|
| 79 |
|
|
(define_insn_reservation "ppc476-compare" 4
|
| 80 |
|
|
(and (eq_attr "type" "compare,delayed_compare,fast_compare,mfcr,mfcrf,\
|
| 81 |
|
|
mtcr,mfjmpr,mtjmpr,var_delayed_compare")
|
| 82 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 83 |
|
|
"ppc476_issue,\
|
| 84 |
|
|
ppc476_i_pipe")
|
| 85 |
|
|
|
| 86 |
|
|
(define_insn_reservation "ppc476-imul" 4
|
| 87 |
|
|
(and (eq_attr "type" "imul,imul_compare,imul2,imul3")
|
| 88 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 89 |
|
|
"ppc476_issue,\
|
| 90 |
|
|
ppc476_i_pipe")
|
| 91 |
|
|
|
| 92 |
|
|
(define_insn_reservation "ppc476-idiv" 11
|
| 93 |
|
|
(and (eq_attr "type" "idiv")
|
| 94 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 95 |
|
|
"ppc476_issue,\
|
| 96 |
|
|
ppc476_i_pipe*11")
|
| 97 |
|
|
|
| 98 |
|
|
(define_insn_reservation "ppc476-branch" 1
|
| 99 |
|
|
(and (eq_attr "type" "branch,jmpreg")
|
| 100 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 101 |
|
|
"ppc476_issue,\
|
| 102 |
|
|
ppc476_b_pipe")
|
| 103 |
|
|
|
| 104 |
|
|
(define_insn_reservation "ppc476-two" 2
|
| 105 |
|
|
(and (eq_attr "type" "two")
|
| 106 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 107 |
|
|
"ppc476_issue2,\
|
| 108 |
|
|
ppc476_i_pipe|ppc476_lj_pipe,\
|
| 109 |
|
|
ppc476_i_pipe|ppc476_lj_pipe")
|
| 110 |
|
|
|
| 111 |
|
|
(define_insn_reservation "ppc476-three" 3
|
| 112 |
|
|
(and (eq_attr "type" "three")
|
| 113 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 114 |
|
|
"ppc476_issue3,\
|
| 115 |
|
|
ppc476_i_pipe|ppc476_lj_pipe,\
|
| 116 |
|
|
ppc476_i_pipe|ppc476_lj_pipe,\
|
| 117 |
|
|
ppc476_i_pipe|ppc476_lj_pipe")
|
| 118 |
|
|
|
| 119 |
|
|
(define_insn_reservation "ppc476-fpcompare" 6
|
| 120 |
|
|
(and (eq_attr "type" "fpcompare")
|
| 121 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 122 |
|
|
"ppc476_issue+ppc476_issue_fp,\
|
| 123 |
|
|
ppc476_f_pipe+ppc476_i_pipe")
|
| 124 |
|
|
|
| 125 |
|
|
(define_insn_reservation "ppc476-fp" 6
|
| 126 |
|
|
(and (eq_attr "type" "fp,dmul")
|
| 127 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 128 |
|
|
"ppc476_issue_fp,\
|
| 129 |
|
|
ppc476_f_pipe")
|
| 130 |
|
|
|
| 131 |
|
|
(define_insn_reservation "ppc476-sdiv" 19
|
| 132 |
|
|
(and (eq_attr "type" "sdiv")
|
| 133 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 134 |
|
|
"ppc476_issue_fp,
|
| 135 |
|
|
ppc476_f_pipe*19")
|
| 136 |
|
|
|
| 137 |
|
|
(define_insn_reservation "ppc476-ddiv" 33
|
| 138 |
|
|
(and (eq_attr "type" "ddiv")
|
| 139 |
|
|
(eq_attr "cpu" "ppc476"))
|
| 140 |
|
|
"ppc476_issue_fp,\
|
| 141 |
|
|
ppc476_f_pipe*33")
|
| 142 |
|
|
|