From: Maynard J. <may...@us...> - 2010-01-11 21:10:10
|
When the oprofile testsuite is run using tcl 8.5 or later, it appears to go into an infinite loop. But in fact, it just slows way down. This is a result of how a spin loop is being implemented in testsuite/lib/op_util.exp. As of tcl 8.5, integers of arbitrary length are supported, which means they *never* overflow. But since the arithmetic operations for the integer variables used within the spin loop rely on the overflowing behaviour of C-stle integers, the results of the operations were not as expected. With the latest tcl, the size of the variables grows exponentially with the number of iterations, and so does the run time. In order for the arithmetic operations within the spin loop to behave as expected, the calculations should use modulo 2**32 = 4294967296. See the attached patch for details. *Will* -- can you please review this patch? Signed-off-by: Maynard Johnson <may...@us...> |