#include #include #include int main() { const size_t count = 4; std::vector<_Float16> f16(count); std::vector f32(count); for(size_t i = 0 ; i < count; ++i) f16[i] = static_cast<_Float16>(0.123) * static_cast<_Float16>(i); std::copy_n(f16.begin(), count, f32.begin()); for(size_t i = 0; i < count; ++i) { std::cout << "loop f16=" << static_cast(f16[i]) << " f32=" << f32[i] << std::endl; } _Float16 one_f16 = 0.123; float one_f32 = one_f16; std::cout << "one f32=" << one_f32 << std::endl; return 0; }