-
Notifications
You must be signed in to change notification settings - Fork 934
Closed
Labels
Description
Due to the TSC frequency debacle in #3003 MPI_Wtime got switched back to clock_gettime() but opal_timer_linux_find_freq has been left broken. This only affects the one remaining call to opal_timer_base_get_freq left in opal_progress_set_event_poll_rate but I'd like to take a shot at fixing it anyway.
Some alternatives I've been thinking about:
- Measure the frequency between a couple of samples of
rdtscandclock_gettime. The longer the period the better, butopal_timer_linux_find_freqdoesn't do much so it would take callingusleepfor a few µs or taking the measurements elsewhere duringopal_init. There's a small difference between sockets, so context switches + migration would be problematic. Ugh. - Take bogomips instead of cpu MHz from
/proc/cpuinfo, divide by 2 and hope it keeps working in the future. Linux tries to avoid breaking userspace, so it's probably a safe bet. - Make it a configurable parameter and let users/admins worry about it.
Any comments?