Skip to content

Commit

Permalink
HIP: Remove the call to hipDeviceSetSharedMemConfig (AMReX-Codes#2884)
Browse files Browse the repository at this point in the history
AMD devices do not support shared cache banking.

Thanks @afanfa for reporting this. (AMReX-Codes#2883)
  • Loading branch information
WeiqunZhang committed Jul 21, 2022
1 parent 8e40952 commit 4b7e200
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions Src/Base/AMReX_GpuDevice.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -397,11 +397,7 @@ Device::initialize_gpu ()

// check compute capability

if (sizeof(Real) == 8) {
AMREX_HIP_SAFE_CALL(hipDeviceSetSharedMemConfig(hipSharedMemBankSizeEightByte));
} else if (sizeof(Real) == 4) {
AMREX_HIP_SAFE_CALL(hipDeviceSetSharedMemConfig(hipSharedMemBankSizeFourByte));
}
// AMD devices do not support shared cache banking.

AMREX_HIP_SAFE_CALL(hipStreamCreate(&gpu_default_stream));
for (int i = 0; i < max_gpu_streams; ++i) {
Expand Down

0 comments on commit 4b7e200

Please sign in to comment.