[PATCH] D83283: [Attributor] AAPotentialValues Interface

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Aug 2 06:41:14 PDT 2020


fhahn added a comment.

In D83283#2189481 <https://reviews.llvm.org/D83283#2189481>, @okura wrote:

> In D83283#2189444 <https://reviews.llvm.org/D83283#2189444>, @thakis wrote:
>
>> This causes:
>>
>> llvm/lib/Transforms/IPO/AttributorAttributes.cpp:56:49: error: explicit specialization of 'MaxPotentialValues' after instantiation
>> unsigned llvm::PotentialConstantIntValuesState::MaxPotentialValues = 0;
>>
>>   ^
>>
>> ../../llvm/lib/Transforms/IPO/AttributorAttributes.cpp:52:57: note: implicit instantiation first required here
>>
>>   cl::location(llvm::PotentialConstantIntValuesState::MaxPotentialValues),
>>                                                       ^
>
> I confirmed that I can build successfully with g++ but fail with clang.
> Should I revert the commit right away?

I'd just make the option a 'regular' global for now. This will avoid this problem. If the extra complexity is needed in the future, it can always be added back.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D83283/new/

https://reviews.llvm.org/D83283



More information about the llvm-commits mailing list