HomeAbout Us A-Z IndexSearch * Contact Us Register LoginPress Shop

The Open Brand -- Problem Reporting and Interpretations System


Problem Report 2729 Details

Help Show help | Quick Search | Submit a Test Suite Support Request | Click here to view your privileges

This page provides all information on Problem Report 2729.


Report 2729 Actions


    Problem Report Number 2729
    Submitter's Classification Test Suite problem
    State Resolved
    Resolution Test Suite Deficiency (TSD)
    Problem Resolution ID TSD.X.1427
    Raised 2020-10-28 11:48
    Updated 2020-12-01 15:48
    Published 2020-12-01 15:48
    Product Standard Internationalised System Calls and Libraries Extended (UNIX 95)
    Certification Program The Open Brand certification program
    Test Suite VSU version 5.3.19
    Test Identification /tset/CAPI.os/procprim/usleep/T.usleep{1}
    Specification System Interfaces and Libraries Issue 4 Version 2
    Location in Spec page 661 of C435
    Problem Summary /tset/CAPI.os/procprim/usleep/T.usleep{1}
    Problem Text 1. I got a failure for /tset/CAPI.os/procprim/usleep/T.usleep{1}.
    Log is as below,
    ==================================================
    0|340 /tset/CAPI.os/procprim/usleep/T.usleep 08:47:58|TC Start, scenario ref 342-0
    15|340 3.8-lite 7|TCM Start
    400|340 1 1 08:47:58|IC Start
    200|340 1 08:47:58|TP Start
    520|340 1 00016844080 1 1|PREP: Get clock ticks per second for time conversion
    520|340 1 00016844080 1 2|PREP: Obtain the time before call to usleep
    520|340 1 00016844080 1 3|TEST: usleep() returns 0 on success
    520|340 1 00016844080 1 4|PREP: Obtain the time after call to usleep
    520|340 1 00016844080 1 5|TEST: Process suspended for correct time
    520|340 1 00016844080 1 6|ERROR: Expected sleep of at least: 879000 usecs, was: 860000 usecs
    220|340 1 1 08:47:58|FAIL
    410|340 1 1 08:47:58|IC End
    ====================================================

    2. The test claims that the process didn't sleep as long as it should have, but the real problem is the way the test calculates the time.
    The test calls times() before and after calling usleep(), and uses the difference between the two times() results to determine how long usleep() was asleep. This is unreliable just as mentioned in the report that reported by someone else [The test converts the times to "double" needlessly, which loses precision.] Besides, I?m not sure if times() is really reliable to use. https://www2.opengroup.org/pr/public/openbrand/PRView?PR=1473

    3. The previous PR is very old and a fix for the problem was made in 1995 (by changing to use times() instead of getitimer()). However, the code still uses double inappropriately. Also, the VSX4 tests of times() allow a 5% leeway for clock accuracy.

    4. I tried the new version of usleep1.c that you provided in request #1188, and it cures the problem. See the log as below,
    ==================================================
    10|0 /tset/CAPI.os/procprim/usleep/T.usleep 21:56:58|TC Start, scenario ref 1-0, ICs: {1}
    15|0 3.8-lite 1|TCM Start
    400|0 1 1 21:56:58|IC Start
    200|0 1 21:56:58|TP Start
    520|0 1 00066005 1 1|PREP: Get clock ticks per second for time conversion
    520|0 1 00066005 1 2|PREP: Obtain the time before call to usleep
    520|0 1 00066005 1 3|TEST: usleep() returns 0 on success
    520|0 1 00066005 1 4|PREP: Obtain the time after call to usleep
    520|0 1 00066005 1 5|TEST: Process suspended for correct time
    220|0 1 0 21:56:59|PASS
    410|0 1 1 21:56:59|IC End
    80|0 0 21:56:59|TC End, scenario ref 1-0
    900|21:56:59|TCC End
    ==================================================
    5. Just apply for a TSD for VSU5.3.19.
    Thanks so much for your help!
    Test Output 0|340 /tset/CAPI.os/procprim/usleep/T.usleep 08:47:58|TC Start, scenario ref 342-0
    15|340 3.8-lite 7|TCM Start
    400|340 1 1 08:47:58|IC Start
    200|340 1 08:47:58|TP Start
    520|340 1 00016844080 1 1|PREP: Get clock ticks per second for time conversion
    520|340 1 00016844080 1 2|PREP: Obtain the time before call to usleep
    520|340 1 00016844080 1 3|TEST: usleep() returns 0 on success
    520|340 1 00016844080 1 4|PREP: Obtain the time after call to usleep
    520|340 1 00016844080 1 5|TEST: Process suspended for correct time
    520|340 1 00016844080 1 6|ERROR: Expected sleep of at least: 879000 usecs, was: 860000 usecs
    220|340 1 1 08:47:58|FAIL
    410|340 1 1 08:47:58|IC End

    Review Information

    Review Type TSMA Review
    Start Date 2020-10-28 11:48
    Last Updated 2020-10-28 09:57
    Completed 2020-10-28 09:57
    Status Complete
    Review Recommendation Test Suite Deficiency (TSD)
    Review Response This is accepted as a fault in the test suite.

    Review Type SA Review
    Start Date 2020-10-28 17:57
    Last Updated 2020-11-03 06:24
    Completed 2020-11-03 06:24
    Status Complete
    Review Resolution Test Suite Deficiency (TSD)
    Review Conclusion A test suite deficiency is granted.

    Problem Reporting System Options:

     

    Back   


Contact the Certification Authority