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]

64bit cleanup in tree,c (print_type_hash_statistics)


htab_size and htab_elements are size_t, not int, so I believe the following
patch is needed to get rid of the messages:

../../gcc/tree.c:4125: warning: int format, different type arg (arg 3)
../../gcc/tree.c:4125: warning: int format, different type arg (arg 4)

	* tree.c (print_type_hash_statistics): Make format match integer size
	on all machines.

===================================================================
RCS file: RCS/tree.c,v
retrieving revision 1.1
diff -c -r1.1 tree.c
*** tree.c	2000/03/20 21:17:57	1.1
--- tree.c	2000/03/20 21:21:24
***************
*** 4120,4127 ****
  static void
  print_type_hash_statistics ()
  {
!   fprintf (stderr, "Type hash: size %d, %d elements, %f collisions\n",
! 	   htab_size (type_hash_table), htab_elements (type_hash_table),
  	   htab_collisions (type_hash_table));
  }
  
--- 4120,4128 ----
  static void
  print_type_hash_statistics ()
  {
!   fprintf (stderr, "Type hash: size %ld, %ld elements, %f collisions\n",
! 	   (long) htab_size (type_hash_table), 
! 	   (long) htab_elements (type_hash_table),
  	   htab_collisions (type_hash_table));
  }
  

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