From: Shang Y. <Yan...@wi...> - 2011-12-20 03:23:12
|
testcase create NCPU=4 threads running with a high priority with the same sched policy and one with a low-priority. The low-priority thread should not run until the other threads stop running, unless the machine has more than NCPU processors when cpu core >4,testcase failed. redefine NCPU = sysconf(_SC_NPROCESSORS_CONF) signed-off-by: YanFeng.Shang <Yan...@wi...> --- .../conformance/interfaces/pthread_create/1-6.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/testcases/open_posix_testsuite/conformance/interfaces/pthread_create/1-6.c b/testcases/open_posix_testsuite/conformance/interfaces/pthread_create/1-6.c index 5424439..932367a 100644 --- a/testcases/open_posix_testsuite/conformance/interfaces/pthread_create/1-6.c +++ b/testcases/open_posix_testsuite/conformance/interfaces/pthread_create/1-6.c @@ -78,7 +78,7 @@ #endif /* The value below shall be >= to the # of CPU on the test architecture */ -#define NCPU (4) +#define NCPU sysconf(_SC_NPROCESSORS_CONF) /********************************************************************************************/ /*********************************** Test cases *****************************************/ @@ -274,4 +274,4 @@ void * threaded (void * arg) if (ret == -1) { UNRESOLVED(errno, "Failed to post the semaphore"); } return arg; -} \ No newline at end of file +} -- 1.6.3.1 |