parent
983a9061ab
commit
412dc3482f
|
@ -1533,8 +1533,9 @@
|
||||||
(define_insn ""
|
(define_insn ""
|
||||||
[(set (pc)
|
[(set (pc)
|
||||||
(if_then_else
|
(if_then_else
|
||||||
(gt (match_operand:SI 0 "general_operand" "+g")
|
(gt (plus:SI (match_operand:SI 0 "general_operand" "+g")
|
||||||
(const_int 1))
|
(const_int -1))
|
||||||
|
(const_int 0))
|
||||||
(label_ref (match_operand 1 "" ""))
|
(label_ref (match_operand 1 "" ""))
|
||||||
(pc)))
|
(pc)))
|
||||||
(set (match_dup 0)
|
(set (match_dup 0)
|
||||||
|
@ -1546,8 +1547,9 @@
|
||||||
(define_insn ""
|
(define_insn ""
|
||||||
[(set (pc)
|
[(set (pc)
|
||||||
(if_then_else
|
(if_then_else
|
||||||
(ge (match_operand:SI 0 "general_operand" "+g")
|
(ge (plus:SI (match_operand:SI 0 "general_operand" "+g")
|
||||||
(const_int 1))
|
(const_int -1))
|
||||||
|
(const_int 0))
|
||||||
(label_ref (match_operand 1 "" ""))
|
(label_ref (match_operand 1 "" ""))
|
||||||
(pc)))
|
(pc)))
|
||||||
(set (match_dup 0)
|
(set (match_dup 0)
|
||||||
|
|
|
@ -35,7 +35,8 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
|
||||||
|
|
||||||
/* Predefine this in CPP because VMS limits the size of command options
|
/* Predefine this in CPP because VMS limits the size of command options
|
||||||
and GNU CPP is not used on VMS except with GNU C. */
|
and GNU CPP is not used on VMS except with GNU C. */
|
||||||
#define CPP_PREDEFINES "-Dvax -Dvms -DVMS -D__GNU__ -D__GNUC__"
|
/* ??? __GNU__ is probably obsolete; delete it for 2.1. */
|
||||||
|
#define CPP_PREDEFINES "-Dvax -Dvms -DVMS -D__GNU__ -D__GNUC__=2"
|
||||||
|
|
||||||
/* Strictly speaking, VMS does not use DBX at all, but the interpreter built
|
/* Strictly speaking, VMS does not use DBX at all, but the interpreter built
|
||||||
into gas only speaks straight DBX. */
|
into gas only speaks straight DBX. */
|
||||||
|
@ -161,7 +162,7 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
|
||||||
? (const_section (), 0) : (data_section (), 0)), \
|
? (const_section (), 0) : (data_section (), 0)), \
|
||||||
fputs (".comm ", (FILE)), \
|
fputs (".comm ", (FILE)), \
|
||||||
assemble_name ((FILE), (NAME)), \
|
assemble_name ((FILE), (NAME)), \
|
||||||
fprintf ((FILE), ",%u\n", (ROUNDED)))
|
fprintf ((FILE), ",%u\n", (SIZE)))
|
||||||
|
|
||||||
/* We define this to prevent the name mangler from putting dollar signs into
|
/* We define this to prevent the name mangler from putting dollar signs into
|
||||||
function names. This isn't really needed, but it has been here for
|
function names. This isn't really needed, but it has been here for
|
||||||
|
@ -254,7 +255,6 @@ const_section () \
|
||||||
__CTOR_LIST__, and essentially points to the same list as __CTOR_LIST. */
|
__CTOR_LIST__, and essentially points to the same list as __CTOR_LIST. */
|
||||||
|
|
||||||
#ifdef L__main
|
#ifdef L__main
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
#define __CTOR_LIST__ __gxx_init_0
|
#define __CTOR_LIST__ __gxx_init_0
|
||||||
#define __CTOR_LIST_END__ __gxx_init_2
|
#define __CTOR_LIST_END__ __gxx_init_2
|
||||||
|
@ -269,7 +269,6 @@ do { \
|
||||||
extern func_ptr __CTOR_LIST_END__[1]; \
|
extern func_ptr __CTOR_LIST_END__[1]; \
|
||||||
extern func_ptr __CTOR_LIST_SHR__[1]; \
|
extern func_ptr __CTOR_LIST_SHR__[1]; \
|
||||||
extern func_ptr __CTOR_LIST_SHR_END__[1]; \
|
extern func_ptr __CTOR_LIST_SHR_END__[1]; \
|
||||||
fflush(stdout); \
|
|
||||||
if( &__CTOR_LIST_SHR__[0] != &__CTOR_LIST__[1]) \
|
if( &__CTOR_LIST_SHR__[0] != &__CTOR_LIST__[1]) \
|
||||||
for (p = __CTOR_LIST_SHR__ + 1; p < __CTOR_LIST_SHR_END__ ; p++ ) \
|
for (p = __CTOR_LIST_SHR__ + 1; p < __CTOR_LIST_SHR_END__ ; p++ ) \
|
||||||
if (*p) (*p) (); \
|
if (*p) (*p) (); \
|
||||||
|
|
|
@ -2459,7 +2459,7 @@ write_test_expr (exp, in_comparison)
|
||||||
printf (" / ");
|
printf (" / ");
|
||||||
break;
|
break;
|
||||||
case MOD:
|
case MOD:
|
||||||
printf (" % ");
|
printf (" %% ");
|
||||||
break;
|
break;
|
||||||
case AND:
|
case AND:
|
||||||
if (in_comparison)
|
if (in_comparison)
|
||||||
|
@ -3025,8 +3025,7 @@ write_eligible_delay (kind)
|
||||||
|
|
||||||
if (num_delays > 1)
|
if (num_delays > 1)
|
||||||
{
|
{
|
||||||
sprintf (str, "*delay_type", kind);
|
attr = find_attr ("*delay_type", 0);
|
||||||
attr = find_attr (str, 0);
|
|
||||||
if (! attr) abort ();
|
if (! attr) abort ();
|
||||||
common_av = find_most_used (attr);
|
common_av = find_most_used (attr);
|
||||||
|
|
||||||
|
|
57
gcc/unroll.c
57
gcc/unroll.c
|
@ -1248,7 +1248,7 @@ precondition_loop_p (initial_value, final_value, increment, loop_start,
|
||||||
/* Fail for floating point values, since the caller of this function
|
/* Fail for floating point values, since the caller of this function
|
||||||
does not have code to deal with them. */
|
does not have code to deal with them. */
|
||||||
if (GET_MODE_CLASS (GET_MODE (loop_final_value)) == MODE_FLOAT
|
if (GET_MODE_CLASS (GET_MODE (loop_final_value)) == MODE_FLOAT
|
||||||
|| GET_MODE_CLASS (GET_MODE (loop_initial_value) == MODE_FLOAT))
|
|| GET_MODE_CLASS (GET_MODE (loop_initial_value)) == MODE_FLOAT)
|
||||||
{
|
{
|
||||||
if (loop_dump_stream)
|
if (loop_dump_stream)
|
||||||
fprintf (loop_dump_stream,
|
fprintf (loop_dump_stream,
|
||||||
|
@ -1493,8 +1493,11 @@ copy_loop_body (copy_start, copy_end, map, exit_label, last_iteration,
|
||||||
XEXP (value, 1));
|
XEXP (value, 1));
|
||||||
|
|
||||||
/* Reset the giv to be just the register again, in case
|
/* Reset the giv to be just the register again, in case
|
||||||
it is used after the set we have just emitted. */
|
it is used after the set we have just emitted.
|
||||||
tv->dest_reg = dest_reg;
|
We must subtract the const_adjust factor added in
|
||||||
|
above. */
|
||||||
|
tv->dest_reg = plus_constant (dest_reg,
|
||||||
|
- tv->const_adjust);
|
||||||
*tv->location = tv->dest_reg;
|
*tv->location = tv->dest_reg;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2669,6 +2672,7 @@ reg_dead_after_loop (reg, loop_start, loop_end)
|
||||||
{
|
{
|
||||||
rtx insn, label;
|
rtx insn, label;
|
||||||
enum rtx_code code;
|
enum rtx_code code;
|
||||||
|
int jump_count = 0;
|
||||||
|
|
||||||
/* HACK: Must also search the loop fall through exit, create a label_ref
|
/* HACK: Must also search the loop fall through exit, create a label_ref
|
||||||
here which points to the loop_end, and append the loop_number_exit_labels
|
here which points to the loop_end, and append the loop_number_exit_labels
|
||||||
|
@ -2684,52 +2688,31 @@ reg_dead_after_loop (reg, loop_start, loop_end)
|
||||||
a conditional jump. */
|
a conditional jump. */
|
||||||
|
|
||||||
insn = NEXT_INSN (XEXP (label, 0));
|
insn = NEXT_INSN (XEXP (label, 0));
|
||||||
while (1)
|
while (insn)
|
||||||
{
|
{
|
||||||
if (insn == 0)
|
code = GET_CODE (insn);
|
||||||
break;
|
if (GET_RTX_CLASS (code) == 'i')
|
||||||
|
{
|
||||||
|
rtx set;
|
||||||
|
|
||||||
if ((code = GET_CODE (insn)) == INSN || code == JUMP_INSN
|
if (reg_referenced_p (reg, PATTERN (insn)))
|
||||||
|| code == CALL_INSN)
|
|
||||||
{
|
|
||||||
if (GET_CODE (PATTERN (insn)) == SET)
|
|
||||||
{
|
|
||||||
if (reg_mentioned_p (reg, SET_SRC (PATTERN (insn))))
|
|
||||||
return 0;
|
return 0;
|
||||||
if (SET_DEST (PATTERN (insn)) == reg)
|
|
||||||
|
set = single_set (insn);
|
||||||
|
if (set && rtx_equal_p (SET_DEST (set), reg))
|
||||||
break;
|
break;
|
||||||
if (reg_mentioned_p (reg, SET_DEST (PATTERN (insn))))
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
else if (reg_mentioned_p (reg, PATTERN (insn)))
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (code == JUMP_INSN)
|
if (code == JUMP_INSN)
|
||||||
{
|
{
|
||||||
if (GET_CODE (PATTERN (insn)) == RETURN)
|
if (GET_CODE (PATTERN (insn)) == RETURN)
|
||||||
break;
|
break;
|
||||||
else if (! simplejump_p (insn))
|
else if (! simplejump_p (insn)
|
||||||
|
/* Prevent infinite loop following infinite loops. */
|
||||||
|
|| jump_count++ > 20)
|
||||||
return 0;
|
return 0;
|
||||||
else
|
else
|
||||||
{
|
|
||||||
insn = JUMP_LABEL (insn);
|
insn = JUMP_LABEL (insn);
|
||||||
/* If this branches to a code label after a LOOP_BEG or
|
|
||||||
a LOOP_CONT note, then assume it is a loop back edge.
|
|
||||||
Must fail in that case to prevent going into an infinite
|
|
||||||
loop trying to trace infinite loops.
|
|
||||||
|
|
||||||
In the presence of syntax errors, this may be a jump to
|
|
||||||
a CODE_LABEL that was never emitted. Fail in this case
|
|
||||||
also. */
|
|
||||||
|
|
||||||
if (! PREV_INSN (insn)
|
|
||||||
|| (GET_CODE (PREV_INSN (insn)) == NOTE
|
|
||||||
&& ((NOTE_LINE_NUMBER (PREV_INSN (insn))
|
|
||||||
== NOTE_INSN_LOOP_BEG)
|
|
||||||
|| (NOTE_LINE_NUMBER (PREV_INSN (insn))
|
|
||||||
== NOTE_INSN_LOOP_CONT))))
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
insn = NEXT_INSN (insn);
|
insn = NEXT_INSN (insn);
|
||||||
|
|
Loading…
Reference in New Issue