On 02/08, Stéphane Letz wrote: > > The ‘pow' operation computed on integer arguments was indeed incorrect at > compile time. Should be fixed in 2.30.12 version on master-dev.
commit bb0bf13334e9a1320f0f90b6ae56da277b9d96a5 adds + Type1 ipow(Type1 a, Type2 ex) + { + if (0 == ex) return 1; + else { + Type1 z = a; + Type1 y = 1; + while (true) { + if (ex & 1) y *= z; + ex /= 2; + if (0 == ex) break; + z *= z; + } + return y; + } + } Perhaps this is what PowPrim::generateCode() should generate when arg1 is int/const? Just look at the c++ code generated from process = ^(100000); to me mydsp_faustpower100000_f() makes no sense. ------------------------------------------------------------------------------- and to remind, process = 100000000000000; outputs 276447232 ;) IIRC, simply because faust uses atoi() without any check, but I am not sure. Oleg. _______________________________________________ Faudiostream-users mailing list Faudiostream-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/faudiostream-users