Bug 183391 - clock-test.sh broken on 64cpus
Summary: clock-test.sh broken on 64cpus
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Ready Certification Tests
Classification: Retired
Component: rhr2-externals
Version: 2
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Will Woods
QA Contact: Will Woods
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2006-02-28 20:02 UTC by Doug Chapman
Modified: 2007-04-18 17:38 UTC (History)
1 user (show)

Fixed In Version: RHBA-2006-0278
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-05-08 13:40:56 UTC
Embargoed:


Attachments (Terms of Use)
suggestion for replacement of clock-test.sh (1.39 KB, text/plain)
2006-03-01 16:36 UTC, Doug Chapman
no flags Details
updated clocktest.c (1.89 KB, text/plain)
2006-03-01 22:15 UTC, Doug Chapman
no flags Details
modified clocktest.c (2.54 KB, text/plain)
2006-03-02 19:34 UTC, Will Woods
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2006:0278 0 normal SHIPPED_LIVE rhr2 bug fix update 2006-05-08 04:00:00 UTC
Red Hat Product Errata RHBA-2006:0284 0 normal SHIPPED_LIVE rhr2 bug fix update 2006-05-08 04:00:00 UTC

Description Doug Chapman 2006-02-28 20:02:49 UTC
Description of problem:

The clock-test.sh test from the CORE2 suite is breaks when it hits the 54'th
CPU.  It appears the actual bug may be in the taskset utility.  I will
investigate more deeply but am filing this now as documentation.


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. try taskset with 2^54 (bitmask with 54th bit set) on 64 bit system
2.taskset 18014398509481984 echo hello
3.
  
Actual results:

sched_setaffinity: Invalid argument


Expected results:


Additional info:

Comment 1 Doug Chapman 2006-02-28 20:30:06 UTC
Looks like the best fix for the test (avoid what appears to be a taskset bug and
also make for a much cleaner script) is to change clock-test.sh

old:
cur_time=$(/usr/bin/taskset $((2**$cpu)) bash -c "$nanotime")


new:
cur_time=$(/usr/bin/taskset -c $cpu bash -c "$nanotime")


I have another test running now so I cannot verify there are no other issues yet
but I will ASAP.

- Doug


Comment 2 Will Woods 2006-02-28 21:20:09 UTC
Unfortunately the -c option to taskset is not available in RHEL3, but we can use
this for RHEL4. 

This is only a problem for RHEL3 if we support more than 32 cpus there. I will
investigate that.

Comment 3 Doug Chapman 2006-03-01 16:36:05 UTC
I am attaching a suggestion for the replacement of the clock-test.sh script. 
This is a C program that should be more accurate.  The test runs much faster
since it does not require a "sleep" between each iteration.  This allows it to
see if the clocks accross the system are mostly in-sync at the same time.

It will need some cleaning up before being used as a real test.  Mostly it will
need to be generalized for more than 64 cpus.  I have run this on my 64cpu ia64
system.



Comment 4 Doug Chapman 2006-03-01 16:36:57 UTC
Created attachment 125479 [details]
suggestion for replacement of clock-test.sh

Comment 5 Doug Chapman 2006-03-01 22:15:17 UTC
Created attachment 125502 [details]
updated clocktest.c

Updated to use clock_gettime instead of gettimeofday as suggested by wwoods. 
Note that this must be compiled with -lrt since clock_gettime lives in the
real-time lib.

Comment 6 Will Woods 2006-03-02 19:34:50 UTC
Created attachment 125560 [details]
modified clocktest.c

This is a modified clocktest.c that can be built on RHEL3. It also checks all
processors on each pass, and calculates the jitter as the difference between
the minimum and maximum time value found. Does this work on your system?

Comment 9 Red Hat Bugzilla 2006-05-08 13:39:48 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2006-0284.html


Comment 10 Red Hat Bugzilla 2006-05-08 13:40:57 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2006-0278.html



Note You need to log in before you can comment on or make changes to this bug.