Crazy Ideas

Jump to navigation Jump to search
Revision as of 22 March 2013 at 15:15.
The highlighted comment was created in this revision.

Crazy Ideas

Edited by author.
Last edit: 15:08, 22 March 2013

First, we initialize integer to 255 to save a byte. :)
Then, in the PM code we use (integer = integer >> 1), instead of (integer = integer - 1).

If I'm right (which I rarely am), this would be smaller, faster and smarter. How does it sound to you?

    Sheldor13:51, 22 March 2013

    Sounds good. I did a geometric reduction of the key length in Toorkild as well, and it worked fine.

      Skilgannon13:58, 22 March 2013
       

      Hmm, for some reason, under Jikes, both of those changes add a byte of codesize. Any number above 127 takes an extra byte, and >> is one more byte than --

        Skilgannon16:13, 22 March 2013

        Were you using Jikes when you compiled Toorkild and got the weird savings from 255?

          Sheldor16:35, 22 March 2013
           

          Yes, but I was using it for an array size, so that might have been something else happening.

            Skilgannon17:15, 22 March 2013