Files
pytorch/c10/util/Float8_e4m3fn.cpp
Bin Bao cbefaf2a37 [AOTI] Move c10/util ostream function implementations to their headers (#123847)
Summary: AOTInductor generated code for CPU models may have direct reference to these c10-implemented data types, see _inductor/codegen/cpp_prefix.h. To make sure the AOTI generated code is ABI backward compatible, we need to change those headers to a header-only implementation. The next PR in this stack will add tests to use those data types without linking against libtorch.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/123847
Approved by: https://github.com/jansel
2024-04-19 00:51:24 +00:00

11 lines
210 B
C++

#include <c10/util/Float8_e4m3fn.h>
#include <type_traits>
namespace c10 {
static_assert(
std::is_standard_layout_v<Float8_e4m3fn>,
"c10::Float8_e4m3fn must be standard layout.");
} // namespace c10