[llvm-commits] [llvm] r122819 - /llvm/trunk/lib/Transforms/Scalar/GVN.cpp

Chris Lattner clattner at apple.com
Tue Jan 4 13:33:11 PST 2011


On Jan 4, 2011, at 1:32 PM, Owen Anderson wrote:

> 
> On Jan 4, 2011, at 1:29 PM, Chris Lattner wrote:
> 
>> 
>> On Jan 4, 2011, at 10:54 AM, Owen Anderson wrote:
>> 
>>> Author: resistor
>>> Date: Tue Jan  4 12:54:18 2011
>>> New Revision: 122819
>>> 
>>> URL: http://llvm.org/viewvc/llvm-project?rev=122819&view=rev
>>> Log:
>>> Branch instructions don't produce values, so there's no need to generate a value number for them.  This
>>> avoids adding them to the various value numbering tables, resulting in a minor (~3%) speedup for GVN
>>> on 40.gcc.
>> 
>> Is there a way to handle "everything that returns void" in one place?  Stores are pretty common as well.
>> 
>> -Chris
> 
> I actually experimented with adding a check for stores to do the same thing when I was writing this patch, but it made absolutely no difference in GVN's runtime.

How about I->getType()->isVoidTy()?

-Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110104/1eba21ce/attachment.html>


More information about the llvm-commits mailing list