Hmp files are not written correctly when compiler optimization is used. This probably has to do with compression of constant data types by the optimizations. I don't think that my patch is the optimal solution to this problem, but it shows where the problem is and how it can be fixed. With this patch hmp files work at least. One obvious problem is that little/big endianess is not taken into account in my solution.