* i386.c (ix86_fp_comparison_arithmetics_cost,
authorhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 13 Jan 2001 08:57:29 +0000 (08:57 +0000)
committerhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 13 Jan 2001 08:57:29 +0000 (08:57 +0000)
commit59112222d25f29607ab7c59b150e080d33b5cfa5
treec70ae326ad613b614bd7ef8b4da3a8ae9e7fabd0
parent74f75696ebc3430c17fbadd13a8bb4789146b6df
* i386.c (ix86_fp_comparison_arithmetics_cost,
ix86_fp_comparison_fcomi_cost, ix86_fp_comparison_sahf_cost,
ix86_fp_comparison_cost): New functions.
(ix86_expand_fp_compare): Use the costs to choose best bethod; add
two new parameters SECOND_TEST and BYPASS_TEST; allow generating
two-branch sequences; make static.
(ix86_use_fcomi_compare): Do decision according to the costs.
(split_fp_branch): New.
* i386.md (compare-and-branch patterns): Use split_fp_branch.
* i386-protos.h (ix86_expand_fp_compare): Remove
(ix86_split_fp_branch): Declare.

* i386.h (PREDICATE_CODES): Update codes from fcmov_comparison_operand
and ix86_comparison_operator.

* i386.c (ix86_prepare_fp_compare_args): Try to rearange the comparison
to make it cheaper.

* i386.c (put_condition_code): Output properly the unordered/ordered
compares in fp case.
(ix86_expand_fp_movcc): Use ix86_expand_compare infrastructure.

* tm.texi (REVERSE_CONDITION): Document.
* i386.c (ix86_fp_compare_mode): Simplify; return always CCFPmode
in -ffast-math mode.
* i386.h (REVERSE_CONDITION, REVERSIBLE_CC_MODE): New macro.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@38979 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/config/i386/i386-protos.h
gcc/config/i386/i386.c
gcc/config/i386/i386.h
gcc/config/i386/i386.md
gcc/tm.texi