mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-22 10:17:01 +08:00
fix: add checks to avoid invalid behavior
Related-To: NEO-9038 Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
0c8a514349
commit
ece03e6bbf
@@ -226,7 +226,9 @@ int BinaryEncoder::processKernel(size_t &line, const std::vector<std::string> &p
|
|||||||
|
|
||||||
// Write KernelName and padding
|
// Write KernelName and padding
|
||||||
kernelBlob.write(kernelName.c_str(), kernelName.size());
|
kernelBlob.write(kernelName.c_str(), kernelName.size());
|
||||||
addPadding(kernelBlob, kernelNameSizeInBinary - kernelName.size());
|
if (kernelNameSizeInBinary > kernelName.size()) {
|
||||||
|
addPadding(kernelBlob, kernelNameSizeInBinary - kernelName.size());
|
||||||
|
}
|
||||||
|
|
||||||
// Write KernelHeap and padding
|
// Write KernelHeap and padding
|
||||||
uint32_t kernelHeapSizeUnpadded = 0U;
|
uint32_t kernelHeapSizeUnpadded = 0U;
|
||||||
|
|||||||
@@ -200,6 +200,7 @@ StorageInfo MemoryManager::createStorageInfoFromProperties(const AllocationPrope
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (DebugManager.flags.ForceSingleTileAllocPlacement.get()) {
|
if (DebugManager.flags.ForceSingleTileAllocPlacement.get()) {
|
||||||
|
UNRECOVERABLE_IF(properties.allocationType == AllocationType::UNKNOWN);
|
||||||
if ((1llu << (static_cast<int64_t>(properties.allocationType) - 1)) & DebugManager.flags.ForceSingleTileAllocPlacement.get()) {
|
if ((1llu << (static_cast<int64_t>(properties.allocationType) - 1)) & DebugManager.flags.ForceSingleTileAllocPlacement.get()) {
|
||||||
storageInfo.cloningOfPageTables = true;
|
storageInfo.cloningOfPageTables = true;
|
||||||
storageInfo.memoryBanks = preferredTile;
|
storageInfo.memoryBanks = preferredTile;
|
||||||
|
|||||||
@@ -46,7 +46,9 @@ class Timer::TimerImpl {
|
|||||||
}
|
}
|
||||||
|
|
||||||
TimerImpl &operator=(const TimerImpl &t) {
|
TimerImpl &operator=(const TimerImpl &t) {
|
||||||
startTime = t.startTime;
|
if (this != &t) {
|
||||||
|
startTime = t.startTime;
|
||||||
|
}
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user