Astaroth  3.1
Scalable Multi-GPU Stencil Computations
Loading...
Searching...
No Matches
mem_access_helper_funcs.h
Go to the documentation of this file.
1#pragma once
2
3#include "builtin_enums.h"
4
5// clang-format off
6#include "user_defines.h"
7// clang-format on
8
9static bool
10kernel_reduces_profile(const int curr_kernel)
11{
12 for(int j = 0; j < NUM_PROFILES; ++j)
13 if(reduced_profiles[curr_kernel][j]) return true;
14 return false;
15}
16static bool
17kernel_reads_profile(const int curr_kernel)
18{
19 for(int j = 0; j < NUM_PROFILES; ++j)
20 if(read_profiles[curr_kernel][j]) return true;
21 return false;
22}
23static bool
24kernel_has_block_loops(const int curr_kernel)
25{
26 return has_mem_access_info && kernel_reduces_profile(curr_kernel);
27}
39