aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Law <law@gcc.gnu.org>1992-09-11 10:39:13 -0600
committerJeff Law <law@gcc.gnu.org>1992-09-11 10:39:13 -0600
commite9cfad814ffb9f98aff768846faf17f3078ddf4a (patch)
treec303a6c2ee561d642f9dad8812a638574f9d92de
parent17651386eecee506fb6ea2e15c0bb9171464cf43 (diff)
downloadgcc-e9cfad814ffb9f98aff768846faf17f3078ddf4a.zip
gcc-e9cfad814ffb9f98aff768846faf17f3078ddf4a.tar.gz
gcc-e9cfad814ffb9f98aff768846faf17f3078ddf4a.tar.bz2
pa.md (non-[cf]branch define_delay): Use a single delay description for the delay slots in "branch"...
* pa.md (non-[cf]branch define_delay): Use a single delay description for the delay slots in "branch", "call", and "milli" insns. (fbranch define_delay): fbranches have a single delay slot which may be nullified when the branch is taken (regardless of direction or distance to the target.) (in_branch_delay attribute): Disallow fbranch insns explicitly. (floating point branches): Use "fbranch" attribute for these insns. Update output template to properly handle nullification. From-SVN: r2107
-rw-r--r--gcc/config/pa/pa.md40
1 files changed, 27 insertions, 13 deletions
diff --git a/gcc/config/pa/pa.md b/gcc/config/pa/pa.md
index d74186a..dc0d700 100644
--- a/gcc/config/pa/pa.md
+++ b/gcc/config/pa/pa.md
@@ -30,7 +30,7 @@
;; type "binary" insns have two input operands (1,2) and one output (0)
(define_attr "type"
- "move,unary,binary,compare,load,store,branch,cbranch,call,dyncall,fpload,fpstore,fpalu,fpcc,fpmul,fpdivsgl,fpdivdbl,fpsqrtsgl,fpsqrtdbl,multi,misc,milli"
+ "move,unary,binary,compare,load,store,branch,cbranch,fbranch,call,dyncall,fpload,fpstore,fpalu,fpcc,fpmul,fpdivsgl,fpdivdbl,fpsqrtsgl,fpsqrtdbl,multi,misc,milli"
(const_string "binary"))
;; Length (in # of insns).
@@ -59,22 +59,24 @@
;; Attributes for instruction and branch scheduling
-(define_delay (eq_attr "type" "call")
- [(eq_attr "in_branch_delay" "true") (nil) (nil)])
-
(define_attr "in_branch_delay" "false,true"
- (if_then_else (and (eq_attr "type" "!branch,cbranch,call,dyncall,multi,milli")
+ (if_then_else (and (eq_attr "type" "!branch,cbranch,fbranch,call,dyncall,multi,milli")
(eq_attr "length" "1"))
(const_string "true")
(const_string "false")))
-(define_delay (eq_attr "type" "branch")
+;; Unconditional branch, call, and millicode call delay slot description.
+(define_delay (eq_attr "type" "branch,call,milli")
[(eq_attr "in_branch_delay" "true") (nil) (nil)])
-(define_delay (eq_attr "type" "cbranch")
- [(eq_attr "in_branch_delay" "true") (nil) (nil)])
+;; Floating point conditional branch delay slot description.
+(define_delay (eq_attr "type" "fbranch")
+ [(eq_attr "in_branch_delay" "true")
+ (eq_attr "in_branch_delay" "true")
+ (nil)])
-(define_delay (eq_attr "type" "milli")
+;; Integer conditional branch delay slot description.
+(define_delay (eq_attr "type" "cbranch")
[(eq_attr "in_branch_delay" "true") (nil) (nil)])
;; Function units of the HPPA. The following data is for the "Snake"
@@ -627,8 +629,14 @@
(label_ref (match_operand 0 "" ""))
(pc)))]
""
- "ftest\;bl%* %0,0"
- [(set_attr "type" "cbranch")
+ "*
+{
+ if (INSN_ANNULLED_BRANCH_P (insn))
+ return \"ftest\;bl,n %0,0\";
+ else
+ return \"ftest\;bl%* %0,0\";
+}"
+ [(set_attr "type" "fbranch")
(set_attr "length" "2")])
(define_insn ""
@@ -636,8 +644,14 @@
(pc)
(label_ref (match_operand 0 "" ""))))]
""
- "ftest\;add,tr 0,0,0\;bl%* %0,0"
- [(set_attr "type" "cbranch")
+ "*
+{
+ if (INSN_ANNULLED_BRANCH_P (insn))
+ return \"ftest\;add,tr 0,0,0\;bl,n %0,0\";
+ else
+ return \"ftest\;add,tr 0,0,0\;bl%* %0,0\";
+}"
+ [(set_attr "type" "fbranch")
(set_attr "length" "3")])
;; Move instructions