SWDEV-478929 - Benchmark ReallyQuickPureX Failed
Ensure the member function Alloc() and Free() of command_pool_ will not be accessed after command_pool_ be destructed. Signed-off-by: Chong Li <chongli2@amd.com> Change-Id: Ic2d36423302518a030bd61fa399290ebe2ed8194
Этот коммит содержится в:
@@ -318,16 +318,15 @@ Command::Command(HostQueue& queue, cl_command_type type, const EventWaitList& ev
|
||||
}
|
||||
}
|
||||
|
||||
SysmemPool<ComputeCommand> Command::command_pool_ ROCCLR_INIT_PRIORITY(101);
|
||||
|
||||
SysmemPool<ComputeCommand>* Command::command_pool_ = new SysmemPool<ComputeCommand>;
|
||||
// ================================================================================================
|
||||
void Command::operator delete(void* ptr) {
|
||||
command_pool_.Free(ptr);
|
||||
return command_pool_->Free(ptr);
|
||||
}
|
||||
|
||||
// ================================================================================================
|
||||
void* Command::operator new(size_t size) {
|
||||
return command_pool_.Alloc(size);
|
||||
return command_pool_->Alloc(size);
|
||||
}
|
||||
|
||||
// ================================================================================================
|
||||
|
||||
Ссылка в новой задаче
Block a user