summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorErik Schnetter <schnetter@gmail.com>2015-01-21 20:52:43 -0500
committerErik Schnetter <schnetter@gmail.com>2015-01-21 20:52:43 -0500
commit90ccc0c129eb4455150e2a1203904121a2a585a1 (patch)
treecf9d2172f832031232040de8195f2787b65ee9b5
parent293067dda9228c8114f7b3cf8cdd70a6c8477f25 (diff)
downloadvecmathlib-90ccc0c129eb4455150e2a1203904121a2a585a1.zip
vecmathlib-90ccc0c129eb4455150e2a1203904121a2a585a1.tar.gz
Describe exponent offset of float8 and float16
-rw-r--r--floattypes.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/floattypes.h b/floattypes.h
index 2c22a10..f3c1af6 100644
--- a/floattypes.h
+++ b/floattypes.h
@@ -213,14 +213,14 @@ namespace vml_std {
namespace vecmathlib {
struct fp8 {
- // 1 bit sign, 4 bits exponent, 3 bits mantissa
+ // 1 bit sign, 4 bits exponent, 3 bits mantissa, exponent offset 7 (?)
vml_std::uint8_t val;
fp8() {}
fp8(double x) { __builtin_unreachable(); }
};
struct fp16 {
- // 1 bit sign, 5 bits exponent, 10 bits mantissa
+ // 1 bit sign, 5 bits exponent, 10 bits mantissa, exponent offset 15 (?)
vml_std::uint16_t val;
fp16() {}
fp16(double x) { __builtin_unreachable(); }
OpenPOWER on IntegriCloud