Steven Harp steven.harp at adventiumlabs.com
Mon Jun 18 22:33:42 CEST 2018

I've noticed that sometimes a double value is rendered strangely
in log output. (Genode 18.05, x86_32)  E.g.

    unsigned N1 = 3300;
    unsigned N2 = 5000 - N1;
    double div1 = N1 / 1000.0;
    double div2 = N2 / 1000.0;
    log(N1,"/1000.=",div1,", ",N2,"/1000. =",div2);
// ...

[init -> test] 3300/1000.=3.299999, 1700/1000. =1.6a0

I know the log facility is not the place for fancy math-mode,
but it would be handy not to have to mentally parse out the
extraneous "a".  I could file an issue if this is deemed 
something worth fixing.  Maybe there is a workaround short of
linking with libc?

// Steve

More information about the users mailing list