rocr: uninitialized pointer read in InitScratchPool
Initialized 'scratch_base' as a nullptr to avoid
uninitialized read in hsaKmtAllocMemory()
Change-Id: I3b0e67f3fd3b591e1d21d691f0777b1d1a059b73
Signed-off-by: Apurv Mishra <apurv.mishra@amd.com>
[ROCm/ROCR-Runtime commit: 6f6ee9679c]
이 커밋은 다음에 포함됨:
@@ -555,7 +555,7 @@ void GpuAgent::InitScratchPool() {
|
||||
}
|
||||
#endif
|
||||
|
||||
void* scratch_base;
|
||||
void* scratch_base = nullptr;
|
||||
HSAKMT_STATUS err =
|
||||
hsaKmtAllocMemory(node_id(), max_scratch_len, flags, &scratch_base);
|
||||
assert(err == HSAKMT_STATUS_SUCCESS && "hsaKmtAllocMemory(Scratch) failed");
|
||||
|
||||
새 이슈에서 참조
사용자 차단