setitimer shows different between amd64 and ia32
Dave Hylands
dhylands at gmail.com
Mon Jul 25 00:09:55 EDT 2011
Hi Adam,
On Sun, Jul 24, 2011 at 8:10 PM, Adam Lee <adam8157 at gmail.com> wrote:
> Hi, all
>
> I'm working on a test which invoking setitimer(), and it hang in
> ia32 and ppc, but passed in amd64, could you guys give some help?
>
> 1, I know the 'value.it_interval.tv_usec' is too short, but why amd64
> passed?
>
> 2, If I switch clock source from "tsc" to "hpet" on ia32, it passed.
>
> 3, I compiled it in ia32 and run it with ia32-libs in amd64, it passed.
I ran it on my 64-bit machine and it hung because the interval was so
short that it generated a continuous stream of signals.
Each signal took longer to process than the interval of the timer.
I added some memset's (since stack variables are uninitialized, and
stuff like sact will get some random values in it if you don't).
I changed the interval of the timer to be 1000 usec, and changed
LOOP_LIMIT to be 1E6, and I got the catcher to be called multiple
times.
--
Dave Hylands
Shuswap, BC, Canada
http://www.davehylands.com
More information about the Kernelnewbies
mailing list