> Hi,
> 
> I have made a mistake when I decided to redirect member-pointer calls
> to builtin_unreachable because I wrongly thought there are two calls,
> one for the VMT lookup and other for non-virtual members and thought
> only the second got redirected.  However, even though there are two
> different lookups, there is only one call and thus we must refrain
> from killing it when the value coming from a caller is not an address
> of a function.  I have pondered about overloading the polymorphic flag
> for marking member pointer calls but eventually decided to introduce a
> new one, as there are plenty bits still available in indirect info and
> the added complexity of overloading the flag quickly turned ugly.
> 
> Bootstrapped and tested on x86_64-linux.  OK for trunk?
> 
> Thanks and sorry for the confusion,
> 
> Martin
> 
> 
> 2013-06-21  Martin Jambor  <mjam...@suse.cz>
> 
>       PR middle-end/57670
>       * cgraph.h (cgraph_indirect_call_info): New flag member_ptr.
>       * ipa-prop.c (ipa_print_node_jump_functions): Mark member pointer
>       calls in the dump.
>       (ipa_note_param_call): Initialize member_ptr flag.
>       (ipa_analyze_indirect_call_uses): Set member_ptr flag.
>       (ipa_make_edge_direct_to_target): Bail out if member_ptr is set.
>       (ipa_write_indirect_edge_info): Stream member_ptr flag.
>       (ipa_read_indirect_edge_info): Likewise.
> 
> testsuite/
>       * g++.dg/ipa/pr57670.C (H): New test.

OK,
thanks!
Honza

Reply via email to