Skip to content

Commit 09e5a91

Browse files
authored
Merge pull request #46261 from iarspider/iarspider-llvman-het
[LLVM Analyzer][Heterogeneous] Remove dead assignments
2 parents f727e25 + 75a3e09 commit 09e5a91

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

HeterogeneousCore/CUDAUtilities/src/CachingDeviceAllocator.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,7 @@ namespace notcub {
425425

426426
// Attempt to allocate
427427
// CMS: silently ignore errors and retry or pass them to the caller
428-
if ((error = cudaMalloc(&search_key.d_ptr, search_key.bytes)) == cudaErrorMemoryAllocation) {
428+
if (cudaMalloc(&search_key.d_ptr, search_key.bytes) == cudaErrorMemoryAllocation) {
429429
// The allocation attempt failed: free all cached blocks on device and retry
430430
if (debug)
431431
// CMS: use raw printf

HeterogeneousCore/CUDAUtilities/src/CachingHostAllocator.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -396,8 +396,7 @@ namespace notcub {
396396
if (!found) {
397397
// Attempt to allocate
398398
// TODO: eventually support allocation flags
399-
if ((error = cudaHostAlloc(&search_key.d_ptr, search_key.bytes, cudaHostAllocDefault)) ==
400-
cudaErrorMemoryAllocation) {
399+
if (cudaHostAlloc(&search_key.d_ptr, search_key.bytes, cudaHostAllocDefault) == cudaErrorMemoryAllocation) {
401400
// The allocation attempt failed: free all cached blocks on device and retry
402401
if (debug)
403402
printf(

0 commit comments

Comments
 (0)