Correction of warnings

Richard Kenner kenner@vlsi1.ultra.nyu.edu
Fri Oct 20 12:25:00 GMT 2000


Fri Oct 20 13:33:16 2000  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>

	* gcse.c (set_hash_table_size): Now unsigned.
	* sdbout.c (template_name_p): Add "const" to avoid warnings.
	(sdbout_record_type_name, plain_type_1, sdbout_symbol): Likewise.
	(sdbout_one_type, sdbout_parms, sdbout_reg_parms): Likewise.
	(sdbout_end_epilogue): Remove variable NAME.
	* system.h (getopt): Add default definition.
	* config/alpha/alpha.c (print_operand): Don't continue processing
	after issuing error.
	(summarize_insn): Avoid use of UL in constant.

*** gcse.c	2000/10/13 06:26:26	1.106
--- gcse.c	2000/10/20 15:03:43
*************** static struct expr **expr_hash_table;
*** 373,377 ****
  
  /* Total size of the copy propagation hash table, in elements.  */
! static int set_hash_table_size;
  
  /* The table itself.
--- 373,377 ----
  
  /* Total size of the copy propagation hash table, in elements.  */
! static unsigned int set_hash_table_size;
  
  /* The table itself.
*** sdbout.c	2000/10/13 06:26:28	1.35
--- sdbout.c	2000/10/20 15:04:33
*************** template_name_p (name)
*** 430,434 ****
       tree name;
  {
!   register char *ptr = IDENTIFIER_POINTER (name);
    while (*ptr && *ptr != '<')
      ptr++;
--- 430,434 ----
       tree name;
  {
!   register const char *ptr = IDENTIFIER_POINTER (name);
    while (*ptr && *ptr != '<')
      ptr++;
*************** sdbout_record_type_name (type)
*** 441,445 ****
       tree type;
  {
!   char *name = 0;
    int no_name;
  
--- 441,445 ----
       tree type;
  {
!   const char *name = 0;
    int no_name;
  
*************** plain_type_1 (type, level)
*** 517,521 ****
  	    && TREE_CODE (DECL_NAME (TYPE_NAME (type))) == IDENTIFIER_NODE)
  	  {
! 	    char *name = IDENTIFIER_POINTER (DECL_NAME (TYPE_NAME (type)));
  
  	    if (!strcmp (name, "char"))
--- 517,522 ----
  	    && TREE_CODE (DECL_NAME (TYPE_NAME (type))) == IDENTIFIER_NODE)
  	  {
! 	    const char *name
! 	      = IDENTIFIER_POINTER (DECL_NAME (TYPE_NAME (type)));
  
  	    if (!strcmp (name, "char"))
*************** sdbout_symbol (decl, local)
*** 710,714 ****
    rtx value;
    int regno = -1;
!   char *name;
  
    sdbout_one_type (type);
--- 711,715 ----
    rtx value;
    int regno = -1;
!   const char *name;
  
    sdbout_one_type (type);
*************** sdbout_one_type (type)
*** 1247,1251 ****
  		&& host_integerp (bit_position (tem), 0))
  	      {
! 		char *name;
  
  		CONTIN;
--- 1248,1252 ----
  		&& host_integerp (bit_position (tem), 0))
  	      {
! 		const char *name;
  
  		CONTIN;
*************** sdbout_parms (parms)
*** 1303,1307 ****
        {
  	int current_sym_value = 0;
! 	char *name = IDENTIFIER_POINTER (DECL_NAME (parms));
  
  	if (name == 0 || *name == 0)
--- 1304,1308 ----
        {
  	int current_sym_value = 0;
! 	const char *name = IDENTIFIER_POINTER (DECL_NAME (parms));
  
  	if (name == 0 || *name == 0)
*************** sdbout_reg_parms (parms)
*** 1434,1438 ****
      if (DECL_NAME (parms))
        {
! 	char *name = IDENTIFIER_POINTER (DECL_NAME (parms));
  
  	/* Report parms that live in registers during the function
--- 1435,1439 ----
      if (DECL_NAME (parms))
        {
! 	const char *name = IDENTIFIER_POINTER (DECL_NAME (parms));
  
  	/* Report parms that live in registers during the function
*************** void
*** 1595,1600 ****
  sdbout_end_epilogue ()
  {
!   char *name = IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (current_function_decl));
!   PUT_SDB_EPILOGUE_END (name);
  }
  
--- 1596,1601 ----
  sdbout_end_epilogue ()
  {
!   PUT_SDB_EPILOGUE_END
!     (IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (current_function_decl)));
  }
  
*** system.h	2000/09/25 22:54:04	1.79
--- system.h	2000/10/20 15:04:45
*************** extern char *getenv PARAMS ((const char 
*** 397,400 ****
--- 397,404 ----
  #endif
  
+ #if defined (HAVE_DECL_GETOPT) && !HAVE_DECL_GETOPT
+ extern int getopt PARAMS ((int, char **, char *));
+ #endif
+ 
  #if defined (HAVE_DECL_GETWD) && !HAVE_DECL_GETWD
  extern char *getwd PARAMS ((char *));
*** config/alpha/alpha.c	2000/10/06 05:19:40	1.146
--- config/alpha/alpha.c	2000/10/20 15:05:18
*************** print_operand (file, x, code)
*** 3795,3799 ****
  	  output_operand_lossage ("invalid %%C value");
  
! 	if (code == 'D')
  	  c = reverse_condition (c);
  	else if (code == 'c')
--- 3795,3799 ----
  	  output_operand_lossage ("invalid %%C value");
  
! 	else if (code == 'D')
  	  c = reverse_condition (c);
  	else if (code == 'c')
*************** summarize_insn (x, sum, set)
*** 5221,5225 ****
        {
  	int regno = REGNO (x);
! 	unsigned long mask = 1UL << (regno % 32);
  
  	if (regno == 31 || regno == 63)
--- 5221,5225 ----
        {
  	int regno = REGNO (x);
! 	unsigned long mask = ((unsigned long) 1) << (regno % 32);
  
  	if (regno == 31 || regno == 63)


More information about the Gcc-patches mailing list