diff options
author | kenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4> | 1994-05-17 22:06:24 +0000 |
---|---|---|
committer | kenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4> | 1994-05-17 22:06:24 +0000 |
commit | 5a6ff0bd011b8f49ed312c63975a09562a41a823 (patch) | |
tree | e0aa1f1e3abc29ea3dffcd351ff90fee856f1c96 /gcc/config/ns32k/ns32k.md | |
parent | 120ba21ebe8f9f7674316eddf56e481075b84493 (diff) | |
download | gcc-5a6ff0bd011b8f49ed312c63975a09562a41a823.tar.gz |
Don't use the extsd/extd instructions on the ns32532.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@7321 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/ns32k/ns32k.md')
-rw-r--r-- | gcc/config/ns32k/ns32k.md | 23 |
1 files changed, 20 insertions, 3 deletions
diff --git a/gcc/config/ns32k/ns32k.md b/gcc/config/ns32k/ns32k.md index 3a32e2fa8ee..2adef963310 100644 --- a/gcc/config/ns32k/ns32k.md +++ b/gcc/config/ns32k/ns32k.md @@ -1,6 +1,6 @@ ;;- Machine description for GNU compiler, ns32000 Version ;; Copyright (C) 1988, 1994 Free Software Foundation, Inc. -;; Contributed by Michael Tiemann (tiemann@mcc.com) +;; Contributed by Michael Tiemann (tiemann@cygnus.com) ;; This file is part of GNU CC. @@ -1861,12 +1861,29 @@ return \"adjspb %$-4\"; }") +;; The extsd/extd isntructions have the problem that they always access +;; 32 bits even if the bitfield is smaller. For example the instruction +;; extsd 7(r1),r0,2,5 +;; would read not only at address 7(r1) but also at 8(r1) to 10(r1). +;; If these addresses are in a different (unmapped) page a memory fault +;; is the result. +;; +;; Timing considerations: +;; movd 0(r1),r0 3 bytes +;; lshd -26,r0 4 +;; andd 0x1f,r0 5 +;; takes about 13 cycles on the 532 while +;; extsd 7(r1),r0,2,5 5 bytes +;; takes about 21 cycles. +;; +;; So lets forget about extsd/extd on the 532. + (define_insn "" [(set (match_operand:SI 0 "general_operand" "=g<") (zero_extract:SI (match_operand:SI 1 "register_operand" "g") (match_operand:SI 2 "const_int_operand" "i") (match_operand:SI 3 "general_operand" "rK")))] - "" + "! TARGET_32532" "* { if (GET_CODE (operands[3]) == CONST_INT) return \"extsd %1,%0,%3,%2\"; @@ -1878,7 +1895,7 @@ (zero_extract:SI (match_operand:QI 1 "general_operand" "g") (match_operand:SI 2 "const_int_operand" "i") (match_operand:SI 3 "general_operand" "rK")))] - "" + "! TARGET_32532" "* { if (GET_CODE (operands[3]) == CONST_INT) return \"extsd %1,%0,%3,%2\"; |