patch to clean up warning on alpha-dec-osf4.0
Weiwen Liu
liu@hepvms.physics.yale.edu
Mon Sep 8 08:54:00 GMT 1997
Hi,
The following patch cleans up warnings on alpha-osf-dec4.0.
Sun Sep 7 23:57:50 1997 Weiwen Liu <liu@hepunix.physics.yale.edu>
* alias.c (init_alias_analysis): Clean up incompatible pointer
type warning in bzero.
* regmove.c (regmove_optimize): Ditto.
* haifa-sched.c (find_rgns): Ditto.
* haifa-sched.c (print_value): Clean up ptr->int cast
warnings.
*** gcc/alias.c.~1~ Wed Sep 3 15:28:49 1997
--- gcc/alias.c Sun Sep 7 23:57:41 1997
*************** init_alias_analysis ()
*** 925,931 ****
reg_base_value_size = maxreg * 2;
reg_base_value = (rtx *)oballoc (reg_base_value_size * sizeof (rtx));
reg_seen = (char *)alloca (reg_base_value_size);
! bzero (reg_base_value, reg_base_value_size * sizeof (rtx));
bzero (reg_seen, reg_base_value_size);
/* Mark all hard registers which may contain an address.
--- 925,931 ----
reg_base_value_size = maxreg * 2;
reg_base_value = (rtx *)oballoc (reg_base_value_size * sizeof (rtx));
reg_seen = (char *)alloca (reg_base_value_size);
! bzero ((char *) reg_base_value, reg_base_value_size * sizeof (rtx));
bzero (reg_seen, reg_base_value_size);
/* Mark all hard registers which may contain an address.
*** gcc/regmove.c.~1~ Tue Aug 12 00:07:12 1997
--- gcc/regmove.c Sun Sep 7 23:55:52 1997
*************** regmove_optimize (f, nregs, regmove_dump
*** 152,158 ****
/* Must initialize this before the loop, because the code for
the commutative case may set matches for operands other than
the current one. */
! bzero (matches, sizeof (matches));
for (operand_number = 0;
operand_number < insn_n_operands[insn_code_number];
--- 152,158 ----
/* Must initialize this before the loop, because the code for
the commutative case may set matches for operands other than
the current one. */
! bzero ((char *)matches, sizeof (matches));
for (operand_number = 0;
operand_number < insn_n_operands[insn_code_number];
*************** regmove_optimize (f, nregs, regmove_dump
*** 714,720 ****
/* Must initialize this before the loop, because the code for
the commutative case may set matches for operands other than
the current one. */
! bzero (matches, sizeof (matches));
for (operand_number = 0;
operand_number < insn_n_operands[insn_code_number];
--- 714,720 ----
/* Must initialize this before the loop, because the code for
the commutative case may set matches for operands other than
the current one. */
! bzero ((char *) matches, sizeof (matches));
for (operand_number = 0;
operand_number < insn_n_operands[insn_code_number];
*** gcc/haifa-sched.c.~1~ Fri Sep 5 15:36:35 1997
--- gcc/haifa-sched.c Sun Sep 7 23:55:02 1997
*************** find_rgns ()
*** 1628,1634 ****
/* function's inner arrays allocation and initialization */
max_hdr = (int *) alloca (n_basic_blocks * sizeof (int));
dfs_nr = (int *) alloca (n_basic_blocks * sizeof (int));
! bzero ((int *) dfs_nr, n_basic_blocks * sizeof (int));
stack = (int *) alloca (nr_edges * sizeof (int));
queue = (int *) alloca (n_basic_blocks * sizeof (int));
--- 1628,1634 ----
/* function's inner arrays allocation and initialization */
max_hdr = (int *) alloca (n_basic_blocks * sizeof (int));
dfs_nr = (int *) alloca (n_basic_blocks * sizeof (int));
! bzero ((char *) dfs_nr, n_basic_blocks * sizeof (int));
stack = (int *) alloca (nr_edges * sizeof (int));
queue = (int *) alloca (n_basic_blocks * sizeof (int));
*************** print_value (buf, x, verbose)
*** 6089,6099 ****
strcpy (t, "fr");
else
strcpy (t, "r");
! sprintf (buf, "%s%d", t, (int) XEXP (x, 0));
break;
case SUBREG:
print_value (t, XEXP (x, 0), verbose);
! sprintf (buf, "%s#%d", t, (int) XEXP (x, 1));
break;
case SCRATCH:
sprintf (buf, "scratch");
--- 6089,6099 ----
strcpy (t, "fr");
else
strcpy (t, "r");
! sprintf (buf, "%s%d", t, !! XEXP (x, 0));
break;
case SUBREG:
print_value (t, XEXP (x, 0), verbose);
! sprintf (buf, "%s#%d", t, !! XEXP (x, 1));
break;
case SCRATCH:
sprintf (buf, "scratch");
More information about the Gcc
mailing list