This is the mail archive of the 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]
Other format: [Raw text]

[PATCH] Fix ipa-reference clearing TREE_ADDRESSABLE on comparisons

This fixes an oversight in ipa-reference where it misses to scan
tcc_comparison class trees for operands that take the address of
a variable.

With the pending rework of the fortran allocator interface we then
ICE in verify_stmts on

 D.1234_5 = D.2345_3 == &bvD.1245;

because this is the only place left where we take bvs address.
(gfortran.dg/alloc_comp_assign_4.f90 is the testcase that starts to
fail this way)

Bootstrapped and tested on x86_64-unknown-linux-gnu.

I'll check this in together with the allocator work if that is


2006-12-11  Richard Guenther  <>

	* ipa-reference.c (scan_for_static_refs): Also scan
	tcc_comparison class trees.

Index: ipa-reference.c
*** ipa-reference.c	(revision 119733)
--- ipa-reference.c	(working copy)
*************** scan_for_static_refs (tree *tp, 
*** 507,512 ****
--- 507,513 ----
  	switch (TREE_CODE_CLASS (TREE_CODE (rhs))) 
  	  case tcc_binary:	    
+ 	  case tcc_comparison:	    
   	      tree op0 = TREE_OPERAND (rhs, 0);
   	      tree op1 = TREE_OPERAND (rhs, 1);

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