There's a pre-cursor to this - code to unpack and perform arbitrary floating-point. There's also subtle problems in attempting up conversion such as float->double alter the value: print 1.4 $1 = 1.3999999999999999 vs: print 1.4 1.4 someone into hard-core floating-point isn't going to accept the former.
See printf(3)'s "a" and "A" formats for a guidelines.
Eg: (fhpd) print 2.0 -format x 0x1.0p1 Commit: Format floating points as hex constants for '-format x'. frysk-core/frysk/value/ChangeLog 2008-01-24 Teresa Thomas <tthomas@redhat.com> * FloatingPointType.java (printAsHexConstant): New. * Format.java (printHexadecimalFP): Call printAsHexConstant. * TestFormat.java (testHexadecimal): Update values.