mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-22 10:42:39 +01:00
Use emplace_back to replace size() and resize().
Summary: This speeds-up thin-link for ~29% for large programs. Reviewers: tejohnson Reviewed By: tejohnson Subscribers: grandinj, sanjoy, llvm-commits Differential Revision: https://reviews.llvm.org/D35145 llvm-svn: 307543
This commit is contained in:
parent
5b32b3eca8
commit
8a5ac9762b
@ -477,7 +477,7 @@ static ld_plugin_status claim_file_hook(const ld_plugin_input_file *file,
|
||||
|
||||
std::unique_ptr<InputFile> Obj = std::move(*ObjOrErr);
|
||||
|
||||
Modules.resize(Modules.size() + 1);
|
||||
Modules.emplace_back();
|
||||
claimed_file &cf = Modules.back();
|
||||
|
||||
cf.handle = file->handle;
|
||||
|
Loading…
Reference in New Issue
Block a user