This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Question on RTX_COST
- To: gcc at gcc dot gnu dot org
- Subject: Question on RTX_COST
- From: Michael Collison <mkc at maker dot com>
- Date: Wed, 06 Oct 1999 15:22:39 -0400
- Organization: Maker Communications
I have a question as to how the RTX_COST macro should be defined for a
particular processor. The docs. indicate that the macro expresses the
"relative" costs of a operation. My questions are:
1.) What are the costs relative to (i.e how should I think about costs
and their impact on cse)?
2.) Do the costs reflect the number of cycles or the size of an
instruction?
Additionally I do not understand the macro COSTS_N_INSNS (which is
defined as N * 4 -2). What does it reflect? Looking at its definition
gives no clue. Normally I look at other machine ports to see how they
define things but there is no common thread. Some ports use
COSTS_N_INSNS, and some just return numbers. What is the right thing to
do here?
Mike
--
Michael Collison
Maker Communications
mkc@maker.com
(508) 766-3297