The Prefetch class is declared in an ordinary header file (runtime/prefetch.hpp), as an AllStatic class with two static member functions. The implementation of those functions is provided by platform-specific definitions in .inline.hpp files that are included via runtime/prefetch.inline.hpp.
So to do anything with Prefetch one must include the inline header. Just including the ordinary header is useless. And this means calling a prefetch function in an ordinary header requires including the inline header in that ordinary header, contrary to the rule against doing so.
The simplest thing to do would be to merge prefetch.hpp into prefetch.inline.hpp and remove the former. There is currently only one ordinary header including prefetch.inline.hpp (gc/serial/generation.hpp), and that include isn't needed. Alternatively, rename some .inline.hpp files.
So to do anything with Prefetch one must include the inline header. Just including the ordinary header is useless. And this means calling a prefetch function in an ordinary header requires including the inline header in that ordinary header, contrary to the rule against doing so.
The simplest thing to do would be to merge prefetch.hpp into prefetch.inline.hpp and remove the former. There is currently only one ordinary header including prefetch.inline.hpp (gc/serial/generation.hpp), and that include isn't needed. Alternatively, rename some .inline.hpp files.