(Existing) Test Coverage

of NPTL functions


Revision Date Changes
A Mar 08, 2004 Initial release
B Apr 05, 2004
  • Added Introduction.
  • Conform the document structure to the site style.
  • Changes in paragraphes order and contents.
C Apr 06, 2004
  • Added tests from directories signal and posix in the NPTL source included tests paragraph.

Back

Introduction

This paper is an analysis of the test coverage for NPTL function.

The analysed tests come from the Open POSIX Test Suite, the Linux Test Project and the glibc source tree.

This analysis is based on the Feb 2004 testsuits.

NPTL source included tests

The libc source tree contains 162 test programs for NPTL functions in the nptl subdirectory, plus 4 in the signal subdirectory, plus 2 in the posix subdirectory, for a total of 168 files.

A brief overview of each test is located in this document.

Once you have successfully compiled the glibc, you can run those tests by doing:

make check

Linux Test Project

The LTP test suite contains (almost) every tests from the Open POSIX Test Suite.

It also contains some other tests, described here:

testcases/kernel/sched/pthreads/pth_str01.c
Complex test creating a tree of threads, synchronizing them. It uses mutex and conditional variables.
testcases/kernel/sched/pthreads/pth_str02.c
Creates recursively N threads, then exits.
testcases/kernel/sched/pthreads/pth_str03.c
Create a tree of threads does calculations, and returns result to parent. This sample is the same as pth_str01.c, plus 3 lines for the calculation stuff.

Open POSIX Test Suite

According to the Open POSIX Test Suite homepage, this project tests every POSIX THR functions.

This document contains the complete description for coverage.

Comparing to those from NPTL, missing functions are: