[llvm] r320814 - [InlineCost] Find repeated loads in the callee

Haicheng Wu via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 18 16:09:15 PST 2017


I am working on it now.

Haicheng

-----Original Message-----
From: Tobias Edler von Koch [mailto:tobias at codeaurora.org] 
Sent: Monday, December 18, 2017 5:53 PM
To: Haicheng Wu <haicheng at codeaurora.org>; llvm-commits at lists.llvm.org
Subject: Re: [llvm] r320814 - [InlineCost] Find repeated loads in the callee

Hi Haicheng,

This should not kick in for volatile loads. Repeat volatile loads of the same address are obviously not free. This broke an internal lit test for us. Would you mind fixing this in a follow-up?

Thanks,
Tobias

On 12/15/2017 08:34 AM, Haicheng Wu via llvm-commits wrote:
> Author: haicheng
> Date: Fri Dec 15 06:34:41 2017
> New Revision: 320814
>
> URL: http://llvm.org/viewvc/llvm-project?rev=320814&view=rev
> Log:
> [InlineCost] Find repeated loads in the callee
>
> SROA analysis of InlineCost can figure out that some stores can be 
> removed after inlining and then the repeated loads clobbered by these 
> stores are also free.  This patch finds these clobbered loads and 
> adjust the inline cost accordingly.
>
> Differential Revision: https://reviews.llvm.org/D33946
>
> Added:
>      llvm/trunk/test/Transforms/Inline/redundant-loads.ll
> Modified:
>      llvm/trunk/include/llvm/Analysis/ValueTracking.h
>      llvm/trunk/lib/Analysis/InlineCost.cpp
>      llvm/trunk/lib/Analysis/ValueTracking.cpp
>
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project.




More information about the llvm-commits mailing list