https://github.com/halide/Halide
Raw File
Tip revision: cacda0e5e019a87d07b9eba8a7f4b25a8138f57f authored by Shoaib Kamil on 12 June 2020, 21:05:45 UTC
Merge remote-tracking branch 'origin/abadams/fix_cuda_mat_mul_assert' into shoaibkamil/correct_memory_fences
Tip revision: cacda0e
FuzzFloatStores.h
#ifndef FUZZ_FLOAT_STORES_H
#define FUZZ_FLOAT_STORES_H

#include "Expr.h"

/** \file
 * Defines a lowering pass that messes with floating point stores.
 */

namespace Halide {
namespace Internal {

/** On every store of a floating point value, mask off the
 * least-significant-bit of the mantissa. We've found that whether or
 * not this dramatically changes the output of a pipeline correlates
 * very well with whether or not a pipeline will produce very
 * different outputs on different architectures (e.g. with and without
 * FMA). It's also a useful way to detect bad tests, such as those
 * that expect exact floating point equality across platforms. */
Stmt fuzz_float_stores(const Stmt &s);

}  // namespace Internal
}  // namespace Halide

#endif
back to top