Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: tsc_get_timecount() panic on SMP



xtraeme%gmail.com@localhost wrote:

> > Do you remember what the fault was? Divide by zero or a page fault or
> > something else?
> 
> I think I saw the divide word, but can't say for sure (sorry I can't
> use this computer now).

This also happens on my i386 Duron (UP) machine:
---
# sysctl -w kern.timecounter.hardware=TSC
kern.timecounter.hardware: ACPI-Fast -> TSC
# cd /usr/src/regress/sys/kern/time
# make regress
./timetest -v -v -c -t 120 -A
Will test active counter and counters with positive quality \
from clockinterrupt(q=0, f=100 Hz) TSC(q=800, f=1300124530 Hz) \
viaenv0(q=1000, f=3579545 Hz) ACPI-Fast(q=1000, f=3579545 Hz) \
i8254(q=100, f=1193182 Hz) dummy(q=-1000000, f=1000000 Hz)
Testing time for monotonicity of timecounter "TSC" for 120 seconds...
kernel: supervisor trap integer divide fault, code=0
Stopped in pid 49.1 (timetest) at       netbsd:tsc_get_timecount+0x2e:  \
divl    0x1c(%edi),%eax
db> tr
tsc_get_timecount(cbd58c9c,7811087b,cbd58c98,1,cbd58ccc) at 
netbsd:tsc_get_timecount+0x2e
bintime(cbd58c9c,8052007,60,fa5c0263,c1a2177f) at netbsd:bintime+0x17
nanotime(cbd58ccc,bfbfed40,8,7,cbd67f80) at netbsd:nanotime+0x15
sys_clock_gettime(cac1e7e0,cbd58d00,cbd58d28,0,0) at 
netbsd:sys_clock_gettime+0x32
syscall(cbd58d48,b3,ab,bfbf001f,36b0001f) at netbsd:syscall+0xb9
db> 
---

cc_denom is updated by tsc_calibrate_cpu() via hardclock()
between zero check and divide?

---
Izumi Tsutsui


Home | Main Index | Thread Index | Old Index