This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: law - Re: 2nd try for patch for automaton based pipeline hazardrecognizer


On Fri, 20 Jul 2001, Vladimir Makarov wrote:

> ! use an immediate operand; but if the immediate value is between @minus{}128
>   and 127, better code results from loading the value into a register and
>   using the register.  This is because the load into the register can be
>   done with a @samp{moveq} instruction.  We arrange for this to happen
>   by defining the letter @samp{K} to mean ``any integer outside the
> ! range @minus{}128 to 127'', and then specifying @samp{Ks} in the operand
>   constraints.
>   
>   @cindex @samp{g} in constraint
> --- 864,875 ----
>   better code to be generated.
>   
>   For example, on the 68000 in a fullword instruction it is possible to
> ! use an immediate operand; but if the immediate value is between -128
>   and 127, better code results from loading the value into a register and
>   using the register.  This is because the load into the register can be
>   done with a @samp{moveq} instruction.  We arrange for this to happen
>   by defining the letter @samp{K} to mean ``any integer outside the
> ! range -128 to 127'', and then specifying @samp{Ks} in the operand

These changes are bogus.  Why do you want to make the manual look uglier
again?  Please read patches carefully before sending or committing them to
make sure that every line of code changed is genuinely meant to be
changed.

> ! @item @var{other-letters}
>   Other letters can be defined in machine-dependent fashion to stand for
>   particular classes of registers or other arbitrary operand types.
>   @samp{d}, @samp{a} and @samp{f} are defined on the 68000/68020 to stand
> --- 946,952 ----
>   
>   @cindex other register constraints
>   @cindex extensible constraints
> ! @item @var{other letters}

Bogus.  Read what the Texinfo manual says about the contents of @var.

> ! Integer in the range @minus{}4095 to 4095
>   
>   @item K
>   Integer that satisfies constraint @samp{I} when inverted (ones complement)
> --- 1344,1350 ----
>   multiple of 2
>   
>   @item J
> ! Integer in the range -4095 to 4095

Bogus.

> ! Constant greater than @minus{}1, less than 64
>   
>   @item J
> ! Constant greater than @minus{}64, less than 1
>   
>   @item K
>   Constant integer 2
> --- 1456,1465 ----
>   Register pair Z (r31:r30)
>   
>   @item I
> ! Constant greater than -1, less than 64
>   
>   @item J
> ! Constant greater than -64, less than 1

Bogus.

> ! Constant integer @minus{}1
>   
>   @item O
>   Constant integer 8, 16, or 24
> --- 1471,1477 ----
>   Constant that fits in 8 bits
>   
>   @item N
> ! Constant integer -1

Bogus.

> ! Constant in range @minus{}2147483648 to 2147483647 or symbolic reference known to fit specified range.
>   (for using immediates in 64-bit x86-64 instructions)
>   
>   @item G
> --- 1636,1642 ----
>   (for using immediates in zero extending 32-bit to 64-bit x86-64 instructions)
>   
>   @item e
> ! Constant in range -2147483648 to 2147483647 or symbolic reference known to fit specified range.

Bogus.

> ! Integers from @minus{}31 to 0
>   
>   @item G
>   Floating point 0
> --- 1664,1670 ----
>   0
>   
>   @item K
> ! Integers from -31 to 0

Bogus.

> ! Integer in the range @minus{}8 to @minus{}1
>   
>   @item M
>   Signed number whose magnitude is greater than 0x100
> --- 1764,1770 ----
>   Signed number whose magnitude is greater than 0x80
>   
>   @item L
> ! Integer in the range -8 to -1

Bogus.

> ! Constants in the range @minus{}65536 to 65535
>   
>   @item M
>   Constants whose 16-bit low part is zero
>   
>   @item N
> ! Constant integer 1 or @minus{}1
>   
>   @item O
>   Constant integer 16
>   
>   @item P
> ! Constants in the range @minus{}8 to 2
>   
>   @end table
>   
> --- 1818,1836 ----
>   Register pair (x:d) to form a 32-bit value
>   
>   @item L
> ! Constants in the range -65536 to 65535
>   
>   @item M
>   Constants whose 16-bit low part is zero
>   
>   @item N
> ! Constant integer 1 or -1
>   
>   @item O
>   Constant integer 16
>   
>   @item P
> ! Constants in the range -8 to 2

Bogus.

> ! Extract a bit-field from operand 1 (a register or memory operand), where
>   operand 2 specifies the width in bits and operand 3 the starting bit,
>   and store it in operand 0.  Operand 0 must have mode @code{word_mode}.
>   Operand 1 may have mode @code{byte_mode} or @code{word_mode}; often
> --- 2397,2403 ----
>   
>   @cindex @code{extv} instruction pattern
>   @item @samp{extv}
> ! Extract a bit field from operand 1 (a register or memory operand), where

Bogus.  gcc.texi has a list of preferred terminology.

> ! Store operand 3 (which must be valid for @code{word_mode}) into a
> ! bit-field in operand 0, where operand 1 specifies the width in bits and
>   operand 2 the starting bit.  Operand 0 may have mode @code{byte_mode} or
>   @code{word_mode}; often @code{word_mode} is allowed only for registers.
>   Operands 1 and 2 must be valid for @code{word_mode}.
> --- 2416,2423 ----
>   
>   @cindex @code{insv} instruction pattern
>   @item @samp{insv}
> ! Store operand 3 (which must be valid for @code{word_mode}) into a bit
> ! field in operand 0, where operand 1 specifies the width in bits and

Bogus.

> ! built-in setjmp that isn't needed at the site of a nonlocal goto.  You
>   will not normally need to define this pattern.  A typical reason why you
>   might need this pattern is if some value, such as a pointer to a global
>   table, must be restored.  It takes one argument, which is the label
> --- 2877,2883 ----
>   @cindex @code{builtin_setjmp_receiver} instruction pattern
>   @item @samp{builtin_setjmp_receiver}
>   This pattern, if defined, contains code needed at the site of an
> ! builtin setjmp that isn't needed at the site of a nonlocal goto.  You

Bogus.  gcc.texi has a list of preferred terminology.  As Kenner has
explained, "builtin" isn't a word.

> ! front end to signal `invalid array index' exceptions.
>   
>   @cindex @code{conditional_trap} instruction pattern
>   @item @samp{conditional_trap}
> --- 2950,2956 ----
>   @item @samp{trap}
>   This pattern, if defined, signals an error, typically by causing some
>   kind of signal to be raised.  Among other places, it is used by the Java
> ! frontend to signal `invalid array index' exceptions.

Bogus.  "frontend" isn't a word.

> ! @samp{dbra}-like instruction and avoids pipeline stalls associated with
>   the jump.
>   
>   GCC has three special named patterns to support low overhead looping,
> --- 3208,3214 ----
>   DSPs have a block repeat instruction that loads special registers to
>   mark the top and end of a loop and to count the number of loop
>   iterations.  This avoids the need for fetching and executing a
> ! @samp{dbra}-like instruction and avoids pipeline stalls asociated with

Bogus.  You're introducing a spelling error here.

> !   "@dots{}")
>   @end group
>   @end smallexample
>   
> --- 3238,3244 ----
>   	(plus:SI (match_dup 0)
>   		 (const_int -1)))]
>     "find_reg_note (insn, REG_NONNEG, 0)"
> !   "...")

Bogus.

> ! decrement operation, in this case @minus{}1.  Note that the following similar
>   pattern will not be matched by the combiner.
>   
>   @smallexample
> --- 3247,3253 ----
>   since this insn is generated by the instruction combination phase
>   combining two sequential insns together into an implicit parallel insn,
>   the iteration counter needs to be biased by the same amount as the
> ! decrement operation, in this case -1.  Note that the following similar

Bogus.

> !   "@dots{}")
>   @end group
>   @end smallexample
>   
> --- 3263,3269 ----
>   	(plus:SI (match_dup 0)
>   		 (const_int -1)))]
>     "find_reg_note (insn, REG_NONNEG, 0)"
> !   "...")

Bogus.

> ! shifting, etc.) and bit-field (@code{extv}, @code{extzv}, and @code{insv})
>   operations.
>   @end table
>   
> --- 3513,3519 ----
>   compiler will try other strategies for code generation using other patterns.
>   
>   Failure is currently supported only for binary (addition, multiplication,
> ! shifting, etc.) and bitfield (@code{extv}, @code{extzv}, and @code{insv})

Bogus.

> ! standard binary or unary arithmetic operation or a bit-field operation,
>   then the last insn it generates must not be a @code{code_label},
>   @code{barrier} or @code{note}.  It must be an @code{insn},
>   @code{jump_insn} or @code{call_insn}.  If you don't need a real insn
> --- 3625,3631 ----
>   @end smallexample
>   
>   @strong{Note:} If the @code{define_expand} is used to serve a
> ! standard binary or unary arithmetic operation or a bitfield operation,

Bogus.

> !   "@var{preparation-statements}")
>   @end smallexample
>   
>   @var{insn-pattern} is a pattern that needs to be split and
> --- 3676,3682 ----
>     [@var{new-insn-pattern-1}
>      @var{new-insn-pattern-2}
>      @dots{}]
> !   "@var{preparation statements}")

Bogus.

> ! The @var{preparation-statements} are similar to those statements that
>   are specified for @code{define_expand} (@pxref{Expander Definitions})
>   and are executed before the new RTL is generated to prepare for the
>   generated code or emit some insns whose pattern is not fixed.  Unlike
> --- 3686,3692 ----
>   with the insns given by @var{new-insn-pattern-1},
>   @var{new-insn-pattern-2}, etc.
>   
> ! The @var{preparation statements} are similar to those statements that

Bogus.

> !   "@var{preparation-statements}"
>     [@var{insn-attributes}])
>   
>   @end smallexample
> --- 3811,3817 ----
>     [@var{new-insn-pattern-1}
>      @var{new-insn-pattern-2}
>      @dots{}]
> !   "@var{preparation statements}"

Bogus.

> !   "@var{optional-insn-attributes}")
>   @end smallexample
>   
>   @noindent
> --- 3892,3898 ----
>      @dots{}]
>     "@var{condition}"
>     "@var{template}"
> !   "@var{optional insn-attributes}")

Bogus.

> !   "@var{preparation-statements}")
>   @end smallexample
>   
>   The definition is almost identical to @code{define_split}
> --- 4087,4093 ----
>     [@var{new-insn-pattern-1}
>      @var{new-insn-pattern-2}
>      @dots{}]
> !   "@var{preparation statements}")

Bogus.

> !   "/* @r{determine 1 does not overlap 0 and 2} */"
>     [(set (match_dup 4) (match_dup 1))
>      (set (match_dup 0) (match_dup 4))
>      (set (match_dup 2) (match_dup 4))]
> --- 4141,4147 ----
>      (set (match_operand:SI 2 "" "") (match_dup 1))
>      (match_dup 4)
>      (set (match_operand:SI 3 "" "") (match_dup 1))]
> !   "@var{determine 1 does not overlap 0 and 2}"

Bogus.

> ! If @var{value} is specified as @samp{"*"}, it means that the default value of
>   the attribute is to be used for the insn containing this expression.
> ! @samp{"*"} obviously cannot be used in the @var{default} expression
> ! of a @code{define_attr}.
>   
>   If the attribute whose value is being specified is numeric, @var{value}
>   must be a string containing a non-negative integer (normally
> --- 4264,4273 ----
>   @cindex @code{const_string} and attributes
>   @item (const_string @var{value})
>   The string @var{value} specifies a constant attribute value.
> ! If @var{value} is specified as @samp{*}, it means that the default value of
>   the attribute is to be used for the insn containing this expression.
> ! @samp{*} obviously cannot be used in the @var{default} expression
> ! of a @code{define_attr}.@refill

Bogus.

> + of successor instructions (or demands nop instructions, e.g. for some

The "e.g." doesn't end a sentence, so should be "e.g.," or "e.g.@:".

> + future code generation goals (e.g. to generate @acronym{VLIW} insn

Likewise.

> + @samp{reservation_name} --- see description of construction

No spaces around TeX dashes.

> + recognize complicated bypasses, e.g. when consumer is only an address

e.g. not ending a sentence.

> + (e.g. some SPARC processors) with a fully pipelined floating point

Likewise.

> !   "@var{output-template}")
>   @end smallexample
>   
>   @var{predicate-pattern} is the condition that must be true for the
> --- 5396,5402 ----
>   (define_cond_exec
>     [@var{predicate-pattern}]
>     "@var{condition}"
> !   "@var{output template}")

Bogus.

> ! @var{output-template} is a string similar to the @code{define_insn}
>   output template (@pxref{Output Template}), except that the @samp{*}
>   and @samp{@@} special cases do not apply.  This is only useful if the
>   assembly text for the predicate is a simple prefix to the main insn.
> --- 5409,5415 ----
>   pattern to match.
>   
>   @findex current_insn_predicate
> ! @var{output template} is a string similar to the @code{define_insn}

Bogus.

> ! @option{-fsched-verbose-@var{n}}.  @var{max_ready} is the maximum number

> ! @samp{-fsched-verbose-}@var{n}.  @var{max_ready} is the maximum number

Bogus.  Did you actually look at the formatted output and where the quotes
appear?

> ! provided by @option{-fsched-verbose-@var{n}}.  @var{ready} is a pointer to

> ! verbose level provided by @samp{-fsched-verbose-}@var{n}.  @var{ready}

Bogus.

> ! value of @var{more} (typically by @samp{@var{more}--}).
>   
>   @findex MAX_INTEGER_COMPUTATION_MODE
>   @item MAX_INTEGER_COMPUTATION_MODE
> --- 8640,8730 ----
>   @var{insn} is the instruction that was scheduled.  @var{more} is the
>   number of instructions that can be issued in the current cycle.  The
>   @samp{MD_SCHED_VARIABLE_ISSUE} macro is responsible for updating the
> ! value of @var{more} (typically by @var{more}--).

Bogus.

-- 
Joseph S. Myers
jsm28@cam.ac.uk



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]