[llvm-commits] CVS: llvm/lib/VMCore/Constants.cpp

Reid Spencer rspencer at reidspencer.com
Tue Feb 27 15:25:52 PST 2007


On Tue, 2007-02-27 at 14:20 -0800, Chris Lattner wrote:
> On Feb 27, 2007, at 12:51 PM, Reid Spencer wrote:
> > Can't we just change this part of ConstantInt:

.. snip ..

> >
> > into:

.. snip ..

> Yes we could.  I would like to do that, but we should do (compile  
> time) timings to see if it is a significant perf hit.

It's basically a DenseMap lookup versus returning a global value. Its
going to be slower, but I doubt it makes much difference in the overall
scheme of things. In any event, I'm going to leave it as is since we
know it will make it slower. The only question is whether cleaning up
the extra globals is worth the performance hit.

Reid.




More information about the llvm-commits mailing list