Bug: 148976166

Clone this repo:
  1. 6321f9e Upgrade FP16 to 4dfe081cf6bcd15db339cf2680b9281b8451eeb3 am: 7cea9a0f20 by Haibo Huang · 3 months ago master android-r-beta-2 android-r-beta-3
  2. 7cea9a0 Upgrade FP16 to 4dfe081cf6bcd15db339cf2680b9281b8451eeb3 by Haibo Huang · 3 months ago
  3. 4dfe081 Optimized FP16 bitcasts for MSVC on ARM/ARM64 by Marat Dukhan · 3 months ago upstream-master
  4. 3c4a5dc Upgrade FP16 to 3c54eacb74f6f5e39077300c5564156c424d77ba am: 2ea5ac4e63 by Haibo Huang · 4 months ago
  5. 2ea5ac4 Upgrade FP16 to 3c54eacb74f6f5e39077300c5564156c424d77ba by Haibo Huang · 4 months ago


Header-only library for conversion to/from half-precision floating point formats


  • Supports IEEE and ARM alternative half-precision floating-point format
    • Property converts infinities and NaNs
    • Properly converts denormal numbers, even on systems without denormal support
  • Header-only library, no installation or build required
  • Compatible with C99 and C++11
  • Fully covered with unit tests and microbenchmarks


HPC Garage logo Georgia Tech College of Computing logo

The library is developed by Marat Dukhan of Georgia Tech. FP16 is a research project at Richard Vuduc's HPC Garage lab in the Georgia Institute of Technology, College of Computing, School of Computational Science and Engineering.

This material is based upon work supported by the U.S. National Science Foundation (NSF) Award Number 1339745. Any opinions, findings and conclusions or recommendations expressed in this material are those of the authors and do not necessarily reflect those of NSF.