[GOOGLE] Fixup varpool references after LIPO linking

2014-08-28 Thread Teresa Johnson
This patch fixes up varpool nodes after LIPO linking as we were doing for cgraph node references. While, here I made some fixes to the cgraph fixup as well (mark address taken as appropriate) and removed old references. The latter exposed an issue with resolved cgraph nodes getting eliminated when

Re: [GOOGLE] Fixup varpool references after LIPO linking

2014-08-28 Thread Teresa Johnson
On Thu, Aug 28, 2014 at 1:40 PM, Xinliang David Li wrote: > > Do you know why the previous check is not enough ? > > cgraph_can_remove_if_no_direct_calls_and_refs_p (struct cgraph_node *node) This will return true for the external node, but it also returns true for the non-external node. The non-

Re: [GOOGLE] Fixup varpool references after LIPO linking

2014-08-28 Thread Xinliang David Li
ok. The patch is fine. On Thu, Aug 28, 2014 at 1:46 PM, Teresa Johnson wrote: > On Thu, Aug 28, 2014 at 1:40 PM, Xinliang David Li wrote: >> >> Do you know why the previous check is not enough ? >> >> cgraph_can_remove_if_no_direct_calls_and_refs_p (struct cgraph_node *node) > > This will return