From: Richard Guenther <richard.guenther@gmail.com>
To: Xinliang David Li <davidxl@google.com>
Cc: GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: FDO usability -- sanity check indirect call target
Date: Fri, 08 Apr 2011 09:27:00 -0000 [thread overview]
Message-ID: <BANLkTinQS9_T5wXvdFSkZ=8ePk7y53_K_g@mail.gmail.com> (raw)
In-Reply-To: <BANLkTinQHM_Qkotfo0uCk5sXEh5ak-Gicg@mail.gmail.com>
On Fri, Apr 8, 2011 at 8:06 AM, Xinliang David Li <davidxl@google.com> wrote:
> 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?
Please instead refactor and re-use gimple_check_call_args ().
Also look at tree_can_inline_p () which has code to deal with
result mismatches.
Richard.
> Thanks,
>
> David
>
> 2011-04-07 Xinliang David Li <davidxl@google.com>
>
> * value-profile.c (function_decl_num_args): New function.
> (check_ic_target): New function.
> (gimple_ic_transform): Sanity check indirect call target.
>
next prev parent reply other threads:[~2011-04-08 9:27 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-08 6:06 Xinliang David Li
2011-04-08 9:27 ` Richard Guenther [this message]
2011-04-08 21:42 ` Xinliang David Li
2011-04-09 16:35 ` Xinliang David Li
2011-04-11 6:06 ` Xinliang David Li
2011-04-11 9:09 ` Richard Guenther
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='BANLkTinQS9_T5wXvdFSkZ=8ePk7y53_K_g@mail.gmail.com' \
--to=richard.guenther@gmail.com \
--cc=davidxl@google.com \
--cc=gcc-patches@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).