[llvm-commits] [PATCH 01/20] Add DenseMapInfo for std::string
David A. Greene
greened at obbligato.org
Tue Jul 19 15:56:13 PDT 2011
Eli Friedman <eli.friedman at gmail.com> writes:
> On Tue, Jul 19, 2011 at 2:11 PM, David A. Greene <greened at obbligato.org> wrote:
>> Eli Friedman <eli.friedman at gmail.com> writes:
>>
>>> On Tue, Jul 19, 2011 at 1:11 PM, David Greene <dag at cray.com> wrote:
>>> This is unsafe in general; TableGen might never see the string
>>> "<<<EMPTY KEY>>>", but you can't assume arbitrary code using this
>>> header will not see it.
>>
>> True, but it's highly unlikely. Do you have a better alternative? I
>> certainly would like to do this the Right Way.
>
> Use std::map? It's not like performance matters here.
Well, Chris suggested using DenseMap with std::string and this is all I
could come up with. Originally I used a FoldingSet but several people
objected due to performance concerns. So I'm a bit stuck. :(
-Dave
More information about the llvm-commits
mailing list