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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [config/] [rs6000/] [7xx.md] - Blame information for rev 38

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 38 julius
;; Scheduling description for Motorola PowerPC 750 and PowerPC 7400 processors.
2
;;   Copyright (C) 2003, 2004, 2007 Free Software Foundation, Inc.
3
;;
4
;; This file is part of GCC.
5
 
6
;; GCC is free software; you can redistribute it and/or modify it
7
;; under the terms of the GNU General Public License as published
8
;; by the Free Software Foundation; either version 3, or (at your
9
;; option) any later version.
10
 
11
;; GCC is distributed in the hope that it will be useful, but WITHOUT
12
;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13
;; or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
14
;; License for more details.
15
 
16
;; You should have received a copy of the GNU General Public License
17
;; along with GCC; see the file COPYING3.  If not see
18
;; .
19
 
20
(define_automaton "ppc7xx,ppc7xxfp")
21
(define_cpu_unit "iu1_7xx,iu2_7xx" "ppc7xx")
22
(define_cpu_unit "fpu_7xx" "ppc7xxfp")
23
(define_cpu_unit "lsu_7xx,bpu_7xx,sru_7xx" "ppc7xx")
24
(define_cpu_unit "du1_7xx,du2_7xx" "ppc7xx")
25
(define_cpu_unit "veccmplx_7xx,vecperm_7xx,vdu_7xx" "ppc7xx")
26
 
27
;; PPC740/PPC750/PPC7400  32-bit 2xIU, LSU, SRU, FPU, BPU
28
;; IU1 can perform all integer operations
29
;; IU2 can perform all integer operations except imul and idiv
30
;; LSU 2 stage pipelined
31
;; FPU 3 stage pipelined
32
;; Max issue 3 insns/clock cycle (includes 1 branch)
33
;; In-order execution
34
 
35
 
36
;; The PPC750 user's manual recommends that to reduce branch mispredictions,
37
;; the insn that sets CR bits should be separated from the branch insn
38
;; that evaluates them.  There is no advantage have more than 10 cycles
39
;; of separation.
40
;; This could be artificially achieved by exaggerating the latency of
41
;; compare insns but at the expense of a poorer schedule.
42
 
43
;; Branches go straight to the BPU.  All other insns are handled
44
;; by a dispatch unit which can issue a max of 2 insns per cycle.
45
(define_reservation "ppc750_du" "du1_7xx|du2_7xx")
46
(define_reservation "ppc7400_vec_du" "vdu_7xx")
47
 
48
(define_insn_reservation "ppc750-load" 2
49
  (and (eq_attr "type" "load,load_ext,load_ext_u,load_ext_ux,\
50
                        load_ux,load_u,fpload,fpload_ux,fpload_u,\
51
                        vecload,load_l")
52
       (eq_attr "cpu" "ppc750,ppc7400"))
53
  "ppc750_du,lsu_7xx")
54
 
55
(define_insn_reservation "ppc750-store" 2
56
  (and (eq_attr "type" "store,store_ux,store_u,\
57
                        fpstore,fpstore_ux,fpstore_u,vecstore")
58
       (eq_attr "cpu" "ppc750,ppc7400"))
59
  "ppc750_du,lsu_7xx")
60
 
61
(define_insn_reservation "ppc750-storec" 8
62
  (and (eq_attr "type" "store_c")
63
       (eq_attr "cpu" "ppc750,ppc7400"))
64
  "ppc750_du,lsu_7xx")
65
 
66
(define_insn_reservation "ppc750-integer" 1
67
  (and (eq_attr "type" "integer,insert_word")
68
       (eq_attr "cpu" "ppc750,ppc7400"))
69
  "ppc750_du,iu1_7xx|iu2_7xx")
70
 
71
(define_insn_reservation "ppc750-two" 1
72
  (and (eq_attr "type" "two")
73
       (eq_attr "cpu" "ppc750,ppc7400"))
74
  "ppc750_du,iu1_7xx|iu2_7xx,iu1_7xx|iu2_7xx")
75
 
76
(define_insn_reservation "ppc750-three" 1
77
  (and (eq_attr "type" "three")
78
       (eq_attr "cpu" "ppc750,ppc7400"))
79
  "ppc750_du,iu1_7xx|iu2_7xx,iu1_7xx|iu2_7xx,iu1_7xx|iu2_7xx")
80
 
81
(define_insn_reservation "ppc750-imul" 4
82
  (and (eq_attr "type" "imul,imul_compare")
83
       (eq_attr "cpu" "ppc750,ppc7400"))
84
  "ppc750_du,iu1_7xx*4")
85
 
86
(define_insn_reservation "ppc750-imul2" 3
87
  (and (eq_attr "type" "imul2")
88
       (eq_attr "cpu" "ppc750,ppc7400"))
89
  "ppc750_du,iu1_7xx*2")
90
 
91
(define_insn_reservation "ppc750-imul3" 2
92
  (and (eq_attr "type" "imul3")
93
       (eq_attr "cpu" "ppc750,ppc7400"))
94
  "ppc750_du,iu1_7xx")
95
 
96
(define_insn_reservation "ppc750-idiv" 19
97
  (and (eq_attr "type" "idiv")
98
       (eq_attr "cpu" "ppc750,ppc7400"))
99
  "ppc750_du,iu1_7xx*19")
100
 
101
(define_insn_reservation "ppc750-compare" 2
102
  (and (eq_attr "type" "cmp,fast_compare,compare,delayed_compare")
103
       (eq_attr "cpu" "ppc750,ppc7400"))
104
  "ppc750_du,(iu1_7xx|iu2_7xx)")
105
 
106
(define_insn_reservation "ppc750-fpcompare" 2
107
  (and (eq_attr "type" "fpcompare")
108
       (eq_attr "cpu" "ppc750,ppc7400"))
109
  "ppc750_du,fpu_7xx")
110
 
111
(define_insn_reservation "ppc750-fp" 3
112
  (and (eq_attr "type" "fp")
113
       (eq_attr "cpu" "ppc750,ppc7400"))
114
  "ppc750_du,fpu_7xx")
115
 
116
(define_insn_reservation "ppc750-dmul" 4
117
  (and (eq_attr "type" "dmul")
118
       (eq_attr "cpu" "ppc750"))
119
  "ppc750_du,fpu_7xx*2")
120
 
121
(define_insn_reservation "ppc7400-dmul" 3
122
  (and (eq_attr "type" "dmul")
123
       (eq_attr "cpu" "ppc7400"))
124
  "ppc750_du,fpu_7xx")
125
 
126
; Divides are not pipelined
127
(define_insn_reservation "ppc750-sdiv" 17
128
  (and (eq_attr "type" "sdiv")
129
       (eq_attr "cpu" "ppc750,ppc7400"))
130
  "ppc750_du,fpu_7xx*17")
131
 
132
(define_insn_reservation "ppc750-ddiv" 31
133
  (and (eq_attr "type" "ddiv")
134
       (eq_attr "cpu" "ppc750,ppc7400"))
135
  "ppc750_du,fpu_7xx*31")
136
 
137
(define_insn_reservation "ppc750-mfcr" 2
138
  (and (eq_attr "type" "mfcr,mtcr")
139
       (eq_attr "cpu" "ppc750,ppc7400"))
140
  "ppc750_du,iu1_7xx")
141
 
142
(define_insn_reservation "ppc750-crlogical" 3
143
  (and (eq_attr "type" "cr_logical,delayed_cr")
144
       (eq_attr "cpu" "ppc750,ppc7400"))
145
  "nothing,sru_7xx*2")
146
 
147
(define_insn_reservation "ppc750-mtjmpr" 2
148
  (and (eq_attr "type" "mtjmpr,isync,sync")
149
       (eq_attr "cpu" "ppc750,ppc7400"))
150
  "nothing,sru_7xx*2")
151
 
152
(define_insn_reservation "ppc750-mfjmpr" 3
153
  (and (eq_attr "type" "mfjmpr")
154
       (eq_attr "cpu" "ppc750,ppc7400"))
155
  "nothing,sru_7xx*2")
156
 
157
(define_insn_reservation "ppc750-jmpreg" 1
158
  (and (eq_attr "type" "jmpreg,branch,isync")
159
       (eq_attr "cpu" "ppc750,ppc7400"))
160
  "nothing,bpu_7xx")
161
 
162
;; Altivec
163
(define_insn_reservation "ppc7400-vecsimple" 1
164
  (and (eq_attr "type" "vecsimple,veccmp")
165
       (eq_attr "cpu" "ppc7400"))
166
  "ppc750_du,ppc7400_vec_du,veccmplx_7xx")
167
 
168
(define_insn_reservation "ppc7400-veccomplex" 4
169
  (and (eq_attr "type" "veccomplex")
170
       (eq_attr "cpu" "ppc7400"))
171
  "ppc750_du,ppc7400_vec_du,veccmplx_7xx")
172
 
173
(define_insn_reservation "ppc7400-vecfloat" 4
174
  (and (eq_attr "type" "vecfloat")
175
       (eq_attr "cpu" "ppc7400"))
176
  "ppc750_du,ppc7400_vec_du,veccmplx_7xx")
177
 
178
(define_insn_reservation "ppc7400-vecperm" 2
179
  (and (eq_attr "type" "vecperm")
180
       (eq_attr "cpu" "ppc7400"))
181
  "ppc750_du,ppc7400_vec_du,vecperm_7xx")
182
 

powered by: WebSVN 2.1.0

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