Author: mlai
Date: 2011-04-25 17:05:49 -0400 (Mon, 25 Apr 2011)
New Revision: 3570
Modified:
trunk/osprey/ipa/main/optimize/ipo_struct_opt.cxx
Log:
This change affects the existing "array remapping" optimization by adding a
restriction to exclude arrays with non-zero field_id (e.g., arrays that are
themselves members of structs) from being considered as array remapping
candidates.
Approved by Min Zhao.
Modified: trunk/osprey/ipa/main/optimize/ipo_struct_opt.cxx
===================================================================
--- trunk/osprey/ipa/main/optimize/ipo_struct_opt.cxx 2011-04-25 07:30:50 UTC
(rev 3569)
+++ trunk/osprey/ipa/main/optimize/ipo_struct_opt.cxx 2011-04-25 21:05:49 UTC
(rev 3570)
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2009-2010 Advanced Micro Devices, Inc. All Rights Reserved.
+ * Copyright (C) 2009-2011 Advanced Micro Devices, Inc. All Rights Reserved.
*/
////////////////////////////////////////////////////////////////////////////
@@ -1669,6 +1669,10 @@
TY_mtype(TY_etype(TY_pointed(WN_ty(array_base_wn)))) !=
array_remapping_candidate_mtype)
return FALSE; // array of another type
+ if (WN_operator(array_base_wn) == OPR_LDA &&
+ WN_field_id(array_base_wn) != 0)
+ return FALSE; // base array just a little too complicated: e.g. it is a
+ // member of a struct, etc.
}
return TRUE;
}
------------------------------------------------------------------------------
WhatsUp Gold - Download Free Network Management Software
The most intuitive, comprehensive, and cost-effective network
management toolset available today. Delivers lowest initial
acquisition cost and overall TCO of any competing solution.
http://p.sf.net/sfu/whatsupgold-sd
_______________________________________________
Open64-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/open64-devel