Vlasiator
ebf0dd394 on dev (v5.4.0 + 1054 commits)
Loading...
Searching...
No Matches
prefetch.hpp
Go to the documentation of this file.
1
#ifdef __GNUC__
2
#define CACHELINE_BYTES 64
3
inline
void
prefetch
(
const
char
*addr,
int
sz){
4
const
int
Nlines = sz/CACHELINE_BYTES+1;
5
for
(
int
c
=0;
c
<Nlines;
c
++) {
6
__builtin_prefetch(addr+CACHELINE_BYTES*
c
);
7
}
8
}
9
10
#else
11
12
inline
void
prefetch
(
const
char
*,
int
);
13
14
#endif
15
16
17
18
19
20
21
c
Constants c
Definition
Dispersion.m:45
prefetch
void prefetch(const char *, int)
prefetch.hpp
Generated on
for Vlasiator by
1.16.1