Re: [Mesa-dev] [PATCH 7/7] mesa: Replace uses of IROUND{, 64} with libm functions.

2015-08-01 Thread Brian Paul
I don't remember the specifics, but I recall some of the old conformance tests being sensitive to float->int conversion in a few areas. Matt, if you have access to the conform tests and can run the old swrast driver with your change, that'd be interesting. -Brian On Fri, Jul 31, 2015 at 7:52 PM

Re: [Mesa-dev] [PATCH 7/7] mesa: Replace uses of IROUND{, 64} with libm functions.

2015-07-31 Thread Roland Scheidegger
I have some doubts of this. Given that IROUND was just plain incorrect, I think we should just use _mesa_lroundevenf() and see what happens. lroundf() is quite the shocker, my libm's implementation is totalling 40 instructions (!) for it (not counting the last return, vs 1 for lrintf). Now it's pro

[Mesa-dev] [PATCH 7/7] mesa: Replace uses of IROUND{, 64} with libm functions.

2015-07-31 Thread Matt Turner
lroundf is the most common replacement. I replaced uses of IROUND() where there was a comment saying "rounded to nearest integer" with _mesa_lroundevenf. IROUND64 is replaced with llroundf. --- src/mesa/main/drawpix.c | 21 +++-- src/mesa/main/eval.c| 14 ++