https://github.com/halide/Halide
Raw File
Tip revision: 1c5993e753a08e6b491592da829ba101d2c4d07e authored by Volodymyr Kysenko on 06 December 2020, 20:42:15 UTC
Merge branch 'vksnk/simplify-slice' of https://github.com/halide/Halide into vksnk/simplify-slice
Tip revision: 1c5993e
prefetch.cpp
#include "HalideRuntime.h"

extern "C" {

// These need to inline, otherwise the extern call with the ptr
// parameter breaks a lot of optimizations, but needs to be WEAK
// so that Codegen_LLVM can find an instance of the Function to insert.
WEAK_INLINE int _halide_prefetch(const void *ptr) {
    __builtin_prefetch(ptr, 1, 3);
    return 0;
}
}
back to top