Hi, due to race conditions, it is common that the value profile information for an indirect call site is 'corrupted' -- resulting in false target function to be recorded. The value profile transformation won't cause runtime problem as the path will never be executed, however it may cause compile time ICE because of the incompatible signature of the callee target. The attached patch does minimal sanity check to make compiler happy in such cases. The fix was tested with lots of MT programs and works really well in practice.
Ok for trunk after testing? Thanks, David 2011-04-07 Xinliang David Li <davi...@google.com> * value-profile.c (function_decl_num_args): New function. (check_ic_target): New function. (gimple_ic_transform): Sanity check indirect call target.
check_ic.p
Description: Binary data