[perf] Replace copy-assign by move-assign in llvm/lib/IR/* (#178175)
This commit is contained in:
parent
4a60ee9332
commit
9e62b779cc
@ -1010,13 +1010,13 @@ int ModuleSlotTracker::getLocalSlot(const Value *V) {
|
||||
void ModuleSlotTracker::setProcessHook(
|
||||
std::function<void(AbstractSlotTrackerStorage *, const Module *, bool)>
|
||||
Fn) {
|
||||
ProcessModuleHookFn = Fn;
|
||||
ProcessModuleHookFn = std::move(Fn);
|
||||
}
|
||||
|
||||
void ModuleSlotTracker::setProcessHook(
|
||||
std::function<void(AbstractSlotTrackerStorage *, const Function *, bool)>
|
||||
Fn) {
|
||||
ProcessFunctionHookFn = Fn;
|
||||
ProcessFunctionHookFn = std::move(Fn);
|
||||
}
|
||||
|
||||
static SlotTracker *createSlotTracker(const Value *V) {
|
||||
@ -1304,13 +1304,13 @@ int SlotTracker::getGlobalSlot(const GlobalValue *V) {
|
||||
void SlotTracker::setProcessHook(
|
||||
std::function<void(AbstractSlotTrackerStorage *, const Module *, bool)>
|
||||
Fn) {
|
||||
ProcessModuleHookFn = Fn;
|
||||
ProcessModuleHookFn = std::move(Fn);
|
||||
}
|
||||
|
||||
void SlotTracker::setProcessHook(
|
||||
std::function<void(AbstractSlotTrackerStorage *, const Function *, bool)>
|
||||
Fn) {
|
||||
ProcessFunctionHookFn = Fn;
|
||||
ProcessFunctionHookFn = std::move(Fn);
|
||||
}
|
||||
|
||||
/// getMetadataSlot - Get the slot number of a MDNode.
|
||||
|
||||
@ -139,7 +139,7 @@ void ConstantRangeList::subtract(const ConstantRange &SubRange) {
|
||||
}
|
||||
}
|
||||
|
||||
Ranges = Result;
|
||||
Ranges = std::move(Result);
|
||||
}
|
||||
|
||||
ConstantRangeList
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user