On Sun, 30 Dec 2012, Jonas Walld?n @ Pike  developers forum wrote:

Too bad with the name clash, but a Pike-prefixed name would also be
quite annoying due to its length.

Yes I agree. I will add an undef before the libvpx includes, which
should fix that.

Do you mean that my latest changes introduced the gcc overflow issues
or only that you noticed them as of now? I'm also concerned about the
overflow detection method using costly integer division on every Pike
variable adjustment (machine-code excepted) so if we can optimize that
it would be great. Here's a link that I found that could be useful:

 
https://www.securecoding.cert.org/confluence/display/seccode/INT32-C.+Ensure+that+operations+on+signed+integers+do+not+result+in+overflow?showComments=false

As far as I can see its the latest change, which turned the macro into
fuctions. I think its overall quite mysterious under which circumstances
gcc (or clang) optimize that check away. In particular because compilers
change and something that works now might break tomorrow. That said, I
think it makes sense to use something which does _not_ involve any
undefined behavior.
Thanks for the link. I will have a look at that. I was thinking about
using __int128 for those compilers that support it and "manual"
multiplication otherwise (see http://www.fefe.de/intof.html).

arne
  • War... Jonas Walld�n @ Pike developers forum
    • ... Martin Nilsson (Opera Mini - AFK!) @ Pike (-) developers forum
    • ... Mirar @ Pike developers forum
      • ... Marcus Comstedt (ACROSS) (Hail Ilpalazzo!) @ Pike (-) developers forum
        • ... Marcus Comstedt (ACROSS) (Hail Ilpalazzo!) @ Pike (-) developers forum
          • ... Jonas Walld�n @ Pike developers forum
            • ... Jonas Walld�n @ Pike developers forum
              • ... Arne Goedeke
                • ... Jonas Walld�n @ Pike developers forum
                • ... Arne Goedeke
                • ... Jonas Walld�n @ Pike developers forum
                • ... Arne Goedeke
              • ... Peter Bortas @ Pike developers forum
    • ... Martin Nilsson (Opera Mini - AFK!) @ Pike (-) developers forum
    • ... Mirar @ Pike developers forum

Reply via email to