tune launch for mrt on crusher

This commit is contained in:
James E McClure 2022-02-02 11:15:00 -05:00
parent a7296535b0
commit a181dfc85d
4 changed files with 11 additions and 4 deletions

View File

@ -463,7 +463,8 @@ dvc_ScaLBL_AAodd_Compact(char * ID, int *d_neighborList, double *dist, int Np) {
}
__global__ void
__global__ void
__launch_bounds__(256,1)
dvc_ScaLBL_AAodd_MRT(int *neighborList, double *dist, int start, int finish, int Np, double rlx_setA, double rlx_setB, double Fx, double Fy, double Fz) {
int n;
@ -932,7 +933,8 @@ dvc_ScaLBL_AAodd_MRT(int *neighborList, double *dist, int start, int finish, int
//__launch_bounds__(512,1)
__global__ void
__global__ void
__launch_bounds__(256,1)
dvc_ScaLBL_AAeven_MRT(double *dist, int start, int finish, int Np, double rlx_setA, double rlx_setB, double Fx, double Fy, double Fz) {
int n;

View File

@ -20,7 +20,7 @@
#include "hip/hip_runtime.h"
#define NBLOCKS 560
#define NTHREADS 128
#define NTHREADS 256
__global__ void INITIALIZE(char *ID, double *f_even, double *f_odd, int Nx, int Ny, int Nz)
{

View File

@ -36,6 +36,7 @@ void ScaLBL_MRTModel::ReadParams(string filename) {
tau = 1.0;
timestepMax = 100000;
ANALYSIS_INTERVAL = 1000;
tolerance = 1.0e-8;
Fx = Fy = 0.0;
Fz = 1.0e-5;
@ -46,6 +47,9 @@ void ScaLBL_MRTModel::ReadParams(string filename) {
if (mrt_db->keyExists("timestepMax")) {
timestepMax = mrt_db->getScalar<int>("timestepMax");
}
if (mrt_db->keyExists("analysis_interval")) {
ANALYSIS_INTERVAL = mrt_db->getScalar<int>("analysis_interval");
}
if (mrt_db->keyExists("tolerance")) {
tolerance = mrt_db->getScalar<double>("tolerance");
}
@ -318,7 +322,7 @@ void ScaLBL_MRTModel::Run() {
comm.barrier();
//************************************************************************/
if (timestep % 1000 == 0) {
if (timestep % ANALYSIS_INTERVAL == 0) {
ScaLBL_D3Q19_Momentum(fq, Velocity, Np);
ScaLBL_DeviceBarrier();
comm.barrier();

View File

@ -48,6 +48,7 @@ public:
bool Restart, pBC;
int timestep, timestepMax;
int ANALYSIS_INTERVAL;
int BoundaryCondition;
double tau, mu;
double Fx, Fy, Fz, flux;