[llvm-commits] [llvm] r171738 - /llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp
Bill Wendling
wendling at apple.com
Sat Jan 12 20:17:45 PST 2013
On Jan 12, 2013, at 3:46 PM, Chandler Carruth <chandlerc at gmail.com> wrote:
> On Fri, Jan 11, 2013 at 3:28 PM, Bill Wendling <wendling at apple.com> wrote:
> Hi Chandler,
>
> On Jan 7, 2013, at 7:04 AM, Chandler Carruth <chandlerc at gmail.com> wrote:
>
> > Author: chandlerc
> > Date: Mon Jan 7 09:04:40 2013
> > New Revision: 171738
> >
> > URL: http://llvm.org/viewvc/llvm-project?rev=171738&view=rev
> > Log:
> > Remove LSR's use of the random AddrMode struct. These variables were
> > already in a class, just inline the four of them. I suspect that this
> > class could be simplified some to not always keep distinct variables for
> > these things, but it wasn't clear to me how given the usage so I opted
> > for a trivial and mechanical translation.
> >
> > This removes one of the two remaining users of a header in include/llvm
> > which does nothing more than define a 4 member struct.
> >
> > Modified:
> > llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp
> >
> > Modified: llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp
> > URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp?rev=171738&r1=171737&r2=171738&view=diff
> > ==============================================================================
> > @@ -2893,7 +2903,6 @@
> > LSRUse &LU, size_t LUIdx) {
> > Formula F;
> > F.BaseRegs.push_back(S);
> > - F.AM.HasBaseReg = true;
>
> Did you intend to remove this assignment entirely?
>
> Good catch. I also didn't intend to add the HasBaseReg line in the function above this. I think this was just a misfire when patching things up and it went into the wrong function. I've fixed this in r172336, but let me know if you have a test case that would have caught this. Would be nice to add one.
>
How I found it was kind of by accident. When I fixed these two places, it didn't affect the test case I've been looking at. :-/
-bw
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130112/79815e00/attachment.html>
More information about the llvm-commits
mailing list