3 ms·
If the compiler mis-optimises this... foo.bar(baz); ... in a way which has unacceptable performance don't just replace it with inexplicable nonsense that y
by tialaramex 4y ago
If the compiler mis-optimises this...
foo.bar(baz);
... in a way which has unacceptable performance don't just replace it with inexplicable nonsense that you happen to know does the right thing in this particular compiler on this particular day for this particular architecture...
let tmp = baz << 2; foo |= (tmp ^ 0x34F2A7);
... instead the correct thing is something like this:
inline function compiler_hack(foo, bar) {
let tmp = bar << 2; foo |= (tmp ^ 0x34F2A7);
}
// FooCompiler 11.65 mis-optimises foo.bar(baz); for the Axilon 480
compiler_hack(foo, bar);