search for: computationresult

Displaying 3 results from an estimated 3 matches for "computationresult".

2009 Mar 02
0
[LLVMdev] Tight overlapping loops and performance
...you'll probably get better results from LLVM with properly nested loops; LLVM's loop optimizers don't know how to deal with deal with overlapping loops. I'd suggest writing it more like the following: int timeout = 2000; int loopcond; do { timeoutwork(); do { timeout--; loopcond = computationresult(); } while (loopcond && timeout); } while (loopcond); -Eli
2009 Mar 02
2
[LLVMdev] Tight overlapping loops and performance
I was playing around in x86 assembly the other day, looking at ways to optimize my cooperative multitasking system. Currently, it uses a 'timeout' counter that is decremented each time through a loop, letting me stop the loop and go to the next cooperative thread if the loop runs a little long. The asm has two overlapping loops: --- _main: mov ecx, 1000000000 timeoutloop:
2009 Mar 02
3
[LLVMdev] Tight overlapping loops and performance
...sters. That's why I was asking about other optimization passes, at first glance -mem2reg looked like a good candidate, but I didn't notice any improvement using it blindly. > int timeout = 2000; > int loopcond; > do { > timeoutwork(); > do { > timeout--; > loopcond = computationresult(); > } while (loopcond && timeout); > } while (loopcond); My current implementation uses something very similar, but if you'll notice the difference between this example and my examples is that the branch for checking 'timeout' is taken in the majority case where in mine...