[cfe-commits] r106441 - in /cfe/trunk/lib: CodeGen/CGDeclCXX.cpp CodeGen/CodeGenModule.h Sema/SemaDeclAttr.cpp
Fariborz Jahanian
fjahanian at apple.com
Mon Jun 21 12:51:01 PDT 2010
On Jun 21, 2010, at 12:40 PM, Chris Lattner wrote:
>
> On Jun 21, 2010, at 11:45 AM, Fariborz Jahanian wrote:
>
>> Author: fjahanian
>> Date: Mon Jun 21 13:45:05 2010
>> New Revision: 106441
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=106441&view=rev
>> Log:
>> IRGen for implementation of init-priority attribute.
>> Test case will be checked in llvm test suite.
>> (finishes off radar 8076356).
>
> Nice!
>
>> + if (!PrioritizedCXXGlobalInits.empty()) {
>> + std::vector<llvm::Constant*> LocalCXXGlobalInits;
>> + std::sort(PrioritizedCXXGlobalInits.begin(),
>> + PrioritizedCXXGlobalInits.end());
>
> Please use SmallVector and array_pod_sort (from llvm/ADT/
> STLExtras.h). Smallvector saves a bit of time. std::sort is
> generally bad because it instantiates into a ton of code.
>
> Thanks for working on this Fariborz,
Checked in r106453.
- Fariborz
>
>
> -Chris
>
More information about the cfe-commits
mailing list