Commit 0387c142 by Wolfgang Gellerich Committed by Andreas Krebbel

s390.h (S390_TDC_POSITIVE_NORMALIZED_NUMBER): Renamed to S390_TDC_POSITIVE_NORMALIZED_BFP_NUMBER.

2008-01-22  Wolfgang Gellerich  <gellerich@de.ibm.com>

	* config/s390/s390.h (S390_TDC_POSITIVE_NORMALIZED_NUMBER):
	Renamed to S390_TDC_POSITIVE_NORMALIZED_BFP_NUMBER.
	(S390_TDC_NEGATIVE_NORMALIZED_NUMBER): Renamed to
	S390_TDC_NEGATIVE_NORMALIZED_BFP_NUMBER.
	(S390_TDC_POSITIVE_DENORMALIZED_NUMBER): Renamed to
	S390_TDC_POSITIVE_DENORMALIZED_BFP_NUMBER.
	(S390_TDC_NEGATIVE_DENORMALIZED_NUMBER): Renamed to
	S390_TDC_NEGATIVE_DENORMALIZED_BFP_NUMBER.
	(S390_TDC_POSITIVE_NORMALIZED_BFP_NUMBER): New constant.
	(S390_TDC_NEGATIVE_NORMALIZED_BFP_NUMBER): New constant.
	(S390_TDC_POSITIVE_DENORMALIZED_BFP_NUMBER): New constant.
	(S390_TDC_NEGATIVE_DENORMALIZED_BFP_NUMBER): New constant.
	* config/s390/s390.md (FP_ALL): New mode iterator.
	(_d): New mode attribute.
	("*signbit<mode>2>"): Changed mode of first operand.
	("isinf<mode>2"): Changed mode of first operand.
	("*TDC_insn"): Adaptation for DFP modes.

From-SVN: r131714
parent fd1935d5
2008-01-22 Wolfgang Gellerich <gellerich@de.ibm.com>
* config/s390/s390.h (S390_TDC_POSITIVE_NORMALIZED_NUMBER):
Renamed to S390_TDC_POSITIVE_NORMALIZED_BFP_NUMBER.
(S390_TDC_NEGATIVE_NORMALIZED_NUMBER): Renamed to
S390_TDC_NEGATIVE_NORMALIZED_BFP_NUMBER.
(S390_TDC_POSITIVE_DENORMALIZED_NUMBER): Renamed to
S390_TDC_POSITIVE_DENORMALIZED_BFP_NUMBER.
(S390_TDC_NEGATIVE_DENORMALIZED_NUMBER): Renamed to
S390_TDC_NEGATIVE_DENORMALIZED_BFP_NUMBER.
(S390_TDC_POSITIVE_NORMALIZED_BFP_NUMBER): New constant.
(S390_TDC_NEGATIVE_NORMALIZED_BFP_NUMBER): New constant.
(S390_TDC_POSITIVE_DENORMALIZED_BFP_NUMBER): New constant.
(S390_TDC_NEGATIVE_DENORMALIZED_BFP_NUMBER): New constant.
* config/s390/s390.md (FP_ALL): New mode iterator.
(_d): New mode attribute.
("*signbit<mode>2>"): Changed mode of first operand.
("isinf<mode>2"): Changed mode of first operand.
("*TDC_insn"): Adaptation for DFP modes.
2008-01-22 Ben Elliston <bje@au.ibm.com>
* tree.c (check_qualified_type): Improve function description.
......
......@@ -144,10 +144,10 @@ extern enum processor_flags s390_arch_flags;
/* Constants needed to control the TEST DATA CLASS (TDC) instruction. */
#define S390_TDC_POSITIVE_ZERO (1 << 11)
#define S390_TDC_NEGATIVE_ZERO (1 << 10)
#define S390_TDC_POSITIVE_NORMALIZED_NUMBER (1 << 9)
#define S390_TDC_NEGATIVE_NORMALIZED_NUMBER (1 << 8)
#define S390_TDC_POSITIVE_DENORMALIZED_NUMBER (1 << 7)
#define S390_TDC_NEGATIVE_DENORMALIZED_NUMBER (1 << 6)
#define S390_TDC_POSITIVE_NORMALIZED_BFP_NUMBER (1 << 9)
#define S390_TDC_NEGATIVE_NORMALIZED_BFP_NUMBER (1 << 8)
#define S390_TDC_POSITIVE_DENORMALIZED_BFP_NUMBER (1 << 7)
#define S390_TDC_NEGATIVE_DENORMALIZED_BFP_NUMBER (1 << 6)
#define S390_TDC_POSITIVE_INFINITY (1 << 5)
#define S390_TDC_NEGATIVE_INFINITY (1 << 4)
#define S390_TDC_POSITIVE_QUIET_NAN (1 << 3)
......@@ -155,9 +155,16 @@ extern enum processor_flags s390_arch_flags;
#define S390_TDC_POSITIVE_SIGNALING_NAN (1 << 1)
#define S390_TDC_NEGATIVE_SIGNALING_NAN (1 << 0)
/* The following values are different for DFP. */
#define S390_TDC_POSITIVE_DENORMALIZED_DFP_NUMBER (1 << 9)
#define S390_TDC_NEGATIVE_DENORMALIZED_DFP_NUMBER (1 << 8)
#define S390_TDC_POSITIVE_NORMALIZED_DFP_NUMBER (1 << 7)
#define S390_TDC_NEGATIVE_NORMALIZED_DFP_NUMBER (1 << 6)
/* For signbit, the BFP-DFP-difference makes no difference. */
#define S390_TDC_SIGNBIT_SET (S390_TDC_NEGATIVE_ZERO \
| S390_TDC_NEGATIVE_NORMALIZED_NUMBER \
| S390_TDC_NEGATIVE_DENORMALIZED_NUMBER\
| S390_TDC_NEGATIVE_NORMALIZED_BFP_NUMBER \
| S390_TDC_NEGATIVE_DENORMALIZED_BFP_NUMBER\
| S390_TDC_NEGATIVE_INFINITY \
| S390_TDC_NEGATIVE_QUIET_NAN \
| S390_TDC_NEGATIVE_SIGNALING_NAN )
......
......@@ -251,6 +251,8 @@
;; These mode iterators allow floating point patterns to be generated from the
;; same template.
(define_mode_iterator FP_ALL [TF DF SF (TD "TARGET_HARD_DFP") (DD "TARGET_HARD_DFP")
(SD "TARGET_HARD_DFP")])
(define_mode_iterator FP [TF DF SF (TD "TARGET_HARD_DFP") (DD "TARGET_HARD_DFP")])
(define_mode_iterator BFP [TF DF SF])
(define_mode_iterator DFP [TD DD])
......@@ -346,6 +348,10 @@
;; within instruction mnemonics.
(define_mode_attr bt [(TF "b") (DF "b") (SF "b") (TD "t") (DD "t") (SD "t")])
;; This attribute is used within instruction mnemonics. It evaluates to d for dfp
;; modes and to an empty string for bfp modes.
(define_mode_attr _d [(TF "") (DF "") (SF "") (TD "d") (DD "d") (SD "d")])
;; Although it is imprecise for z9-ec we handle all dfp instructions like
;; bfp regarding the pipeline description.
(define_mode_attr bfp [(TF "tf") (DF "df") (SF "sf")
......@@ -2310,7 +2316,7 @@
(define_expand "signbit<mode>2"
[(set (reg:CCZ CC_REGNUM)
(unspec:CCZ [(match_operand:BFP 1 "register_operand" "f")
(unspec:CCZ [(match_operand:FP_ALL 1 "register_operand" "f")
(match_dup 2)]
UNSPEC_TDC_INSN))
(set (match_operand:SI 0 "register_operand" "=d")
......@@ -2322,7 +2328,7 @@
(define_expand "isinf<mode>2"
[(set (reg:CCZ CC_REGNUM)
(unspec:CCZ [(match_operand:BFP 1 "register_operand" "f")
(unspec:CCZ [(match_operand:FP_ALL 1 "register_operand" "f")
(match_dup 2)]
UNSPEC_TDC_INSN))
(set (match_operand:SI 0 "register_operand" "=d")
......@@ -2339,12 +2345,12 @@
;
(define_insn "*TDC_insn_<mode>"
[(set (reg:CCZ CC_REGNUM)
(unspec:CCZ [(match_operand:BFP 0 "register_operand" "f")
(unspec:CCZ [(match_operand:FP_ALL 0 "register_operand" "f")
(match_operand:SI 1 "const_int_operand")] UNSPEC_TDC_INSN))]
"TARGET_HARD_FLOAT"
"tc<xde>b\t%0,%1"
"t<_d>c<xde><bt>\t%0,%1"
[(set_attr "op_type" "RXE")
(set_attr "type" "fsimp<mode>")])
(set_attr "type" "fsimp<bfp>")])
(define_insn_and_split "*ccz_to_int"
[(set (match_operand:SI 0 "register_operand" "=d")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment