1#ifndef TRITON_INCLUDE_TRITON_CODEGEN_TRANSFORM_PREFETCH_H
2#define TRITON_INCLUDE_TRITON_CODEGEN_TRANSFORM_PREFETCH_H
3
4#include <set>
5
6// forward dclaration
7namespace triton::ir{
8class module;
9class value;
10}
11
12namespace triton::codegen {
13class target;
14}
15
16namespace triton::codegen::transform {
17class prefetch {
18 target* tgt_;
19 std::set<ir::value*> prefetched_vals_;
20public:
21 prefetch(target *tgt) : tgt_(tgt) {}
22 void run(ir::module &module);
23 bool is_prefetched(ir::value* v) { return prefetched_vals_.find(v) != prefetched_vals_.end(); }
24};
25}
26
27#endif