SWDEV-514959 - Fix memory leaks in streamperthread tests (#14)

Change-Id: I7b133d422f675d45050d7f724d632fa2dc997baf

[ROCm/hip-tests commit: fde891bc76]
이 커밋은 다음에 포함됨:
Dittakavi, Satyanvesh 작성하고 GitHub가 2025-08-18 17:27:47 +05:30를 커밋함
1 부모 1d9c8b7f6d
커밋 5ad57c1d9a
3 파일이 변경됨
+14 -4

검색과 일치하는 파일 없음

+4 -1
파일 보기
@@ -1,5 +1,5 @@
/*
Copyright (c) 2021 Advanced Micro Devices, Inc. All rights reserved.
Copyright (c) 2025 Advanced Micro Devices, Inc. All rights reserved.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
@@ -88,6 +88,9 @@ TEST_CASE("Unit_hipStreamPerThread_DeviceReset_2") {
if (status != hipSuccess) return;
HIP_CHECK(hipStreamSynchronize(hipStreamPerThread));
// Host Memory is not destroyed with hipDeviceReset, need to free it
// explicitly to avoid memory leaks
HIP_CHECK(hipHostFree(A_h));
HIP_CHECK(hipDeviceReset());
// After reset all memory objects will be destroyed hence allocating them again