[Mesa-dev] [PATCH 03/13] gallium/auxiliary: Use exp2(x) instead of pow(2.0, x).

Matt Turner mattst88 at gmail.com
Wed Jul 15 12:58:58 PDT 2015


On Wed, Jul 15, 2015 at 12:44 PM, Matt Turner <mattst88 at gmail.com> wrote:
> On Mon, Jul 13, 2015 at 5:13 PM, Roland Scheidegger <sroland at vmware.com> wrote:
>> Did you replace 2 of them by exp2f but one by exp2f on purpose?
>>
>> I don't think we can use exp2/exp2f in gallium. This requires msvc 2013
>> (all of exp2, exp2f, powf are c99, powf is supported by older msvc but
>> the others are not). I guess though could throw some wrappers into
>> c99_math.h.
>
> I think this series adds uses of sinf, cosf, exp2f, logf, and powf.
>
> I see existing uses of sinf, cosf, logf, and powf in tgsi_exec.c.
> Presumably that means they're safe for me to use elsewhere?
>
> I also see that lp_test_arit.c uses exp2f. Presumably that means it's
> also safe to use?
>
> I don't see wrappers for any of these.

Additionally, I've added calls to copysignf and ldexpf. I don't see
existing uses of either of these.


More information about the mesa-dev mailing list