Cache GPU main-path device buffers

This commit is contained in:
2026-04-08 19:43:17 +08:00
parent ea470737db
commit 01ac1f9250
3 changed files with 697 additions and 222 deletions

View File

@@ -4,10 +4,8 @@
#include "bssn_macro.h"
#include "macrodef.fh"
#define DEVICE_ID 0
// #define DEVICE_ID_BY_MPI_RANK
#define GRID_DIM 256
#define BLOCK_DIM 128
#define GRID_DIM 256
#define BLOCK_DIM 128
#define _FH2_(i, j, k) fh[(i) + (j) * _1D_SIZE[2] + (k) * _2D_SIZE[2]]
#define _FH3_(i, j, k) fh[(i) + (j) * _1D_SIZE[3] + (k) * _2D_SIZE[3]]