          1 (.put bb (unchecked-byte (get int8-special-map b b)))
          2 (.putShort bb (unchecked-short (get int16-special-map b b)))
          3 (.putInt bb (unchecked-int (get int32-special-map b b)))
-         5 (.putFloat bb (float (get float32-special-map b b)))
+         5 (.putInt bb (unchecked-int (or (get float32-special-map b)
+                                          (Float/floatToRawIntBits b))))
          7 (.put bb (byte b))))
      (.array bb))))
 

      (.putInt chrom-id)
      (.putInt pos)
      (.putInt rlen)
      (.putFloat qual)
      (.putInt n-allele-info)
      (.putInt n-fmt-sample)
      (.put ^bytes id)

  (let [chrom-id (:chr v)
        pos (dec (:pos v))
        rlen (:ref-length v)
        qual (unchecked-int
              (if-let [qual-val (:qual v)]
                (Float/floatToRawIntBits qual-val)
                (float32-special-map nil)))
        n-allele (inc (count (:alt v)))
        n-info (count (:info v))
        n-allele-info (bit-or (bit-shift-left n-allele 16) n-info)
