Integer/long swaps: shaving off a few cycles
-
- Enthusiast
- Posts: 767
- Joined: Sat Jan 24, 2004 6:56 pm
Integer/long swaps: shaving off a few cycles
Deleted, see posts below....
Last edited by dell_jockey on Mon Jan 28, 2008 2:15 pm, edited 1 time in total.
-
- Enthusiast
- Posts: 767
- Joined: Sat Jan 24, 2004 6:56 pm
1: not even to compare the relative merit of two methods? I know the durations measured will not be correct by a large margin, but surely that will be true for both methods tested?Trond wrote:1. Don't do speed testing with the debugger on.
2. A normal "Swap a, b" is twice as fast as your XOR swap.
2: I stand corrected here, I didn't even know PB had a swap built-in
