[cfe-commits] r159161 - in /cfe/trunk: lib/AST/ExprConstant.cpp test/SemaCXX/constexpr-many-arguments.cpp

Eli Friedman eli.friedman at gmail.com
Mon Jun 25 14:41:31 PDT 2012


On Mon, Jun 25, 2012 at 2:28 PM, Chandler Carruth <chandlerc at google.com> wrote:
> On Mon, Jun 25, 2012 at 2:26 PM, Chandler Carruth <chandlerc at google.com>
> wrote:
>>
>> On Mon, Jun 25, 2012 at 2:21 PM, Eli Friedman <eli.friedman at gmail.com>
>> wrote:
>>>
>>> Author: efriedma
>>> Date: Mon Jun 25 16:21:08 2012
>>> New Revision: 159161
>>>
>>> URL: http://llvm.org/viewvc/llvm-project?rev=159161&view=rev
>>> Log:
>>> Use std::map instead of llvm::DenseMap because we rely on the stability
>>> of references to values in these maps. PR13197.
>>
>>
>> Would it be better to use a vector for storage and a densemap of
>> pointer->pointer?
>
>
> Obviously, a vector doesn't work for the same reason a densemap doesn't...
>
> However, we could model a reference as a stable index into a vector, or use
> a deque-like storage system, potentially even a bumpptrallocator...

Better in terms of performance?  Maybe... but it's a rather invasive
change considering the number of "APValue&"s floating around
ExprConstant, and I don't feel like I know this code as well as I used
to.

-Eli



More information about the cfe-commits mailing list