Changeset 72ff756 in rtems
- Timestamp:
- 12/01/13 02:27:44 (10 years ago)
- Branches:
- 4.11, 5, master
- Children:
- 972579d
- Parents:
- 95d7ac7
- git-author:
- Daniel Ramirez <javamonn@…> (12/01/13 02:27:44)
- git-committer:
- Gedare Bloom <gedare@…> (12/01/13 02:31:30)
- Location:
- testsuites/psxtmtests
- Files:
-
- 3 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
testsuites/psxtmtests/Makefile.am
r95d7ac7 r72ff756 11 11 SUBDIRS += psxtmcond02 12 12 SUBDIRS += psxtmcond03 13 SUBDIRS += psxtmcond04 13 14 SUBDIRS += psxtmcond05 14 15 SUBDIRS += psxtmcond08 -
testsuites/psxtmtests/configure.ac
r95d7ac7 r72ff756 85 85 psxtmcond02/Makefile 86 86 psxtmcond03/Makefile 87 psxtmcond04/Makefile 87 88 psxtmcond05/Makefile 88 89 psxtmcond08/Makefile -
testsuites/psxtmtests/psxtmcond03/init.c
r95d7ac7 r72ff756 31 31 ) 32 32 { 33 int status; 34 35 status = pthread_mutex_lock(&MutexID); 36 rtems_test_assert( status == 0 ); 37 38 /* Unlock mutex, block, wait for CondID to be signaled */ 33 39 pthread_cond_wait(&CondID,&MutexID); 34 /* should never return */ 40 41 /* should never return */ 35 42 rtems_test_assert( FALSE ); 36 43 … … 45 52 pthread_t threadId; 46 53 long end_time; 54 struct sched_param param; 55 int policy; 47 56 48 57 puts( "\n\n*** POSIX TIME TEST PSXTMCOND03 ***" ); … … 58 67 59 68 /* 60 * Ensure the mutex is unavailable so the other threads block.61 */62 status = pthread_mutex_lock(&MutexID);63 rtems_test_assert( status == 0 );64 65 /*66 69 * Let the other thread start so the thread startup overhead, 67 70 * is accounted for. When we return, we can start the benchmark. … … 69 72 sched_yield(); 70 73 /* let other thread run */ 74 75 /* To be extra sure we don't get preempted on the signal */ 76 status = pthread_getschedparam(pthread_self(), &policy, ¶m); 77 rtems_test_assert( status == 0); 78 param.sched_priority = sched_get_priority_max(policy) - 1; 79 status = pthread_setschedparam(pthread_self(), policy, ¶m); 80 rtems_test_assert( status == 0); 71 81 72 82 benchmark_timer_initialize(); -
testsuites/psxtmtests/psxtmtests_plan.csv
r95d7ac7 r72ff756 18 18 "pthread_cond_signal - no threads waiting","psxtmcond02","psxtmtest_single","Yes" 19 19 "pthread_cond_signal - thread waiting: no preempt","psxtmcond03","psxtmtest_unblocking_nopreempt","Yes" 20 "pthread_cond_signal - thread waiting: preempt","psxtmcond04","psxtmtest_unblocking_preempt"," No"20 "pthread_cond_signal - thread waiting: preempt","psxtmcond04","psxtmtest_unblocking_preempt","Yes" 21 21 "pthread_cond_broadcast - no threads waiting","psxtmcond05","psxtmtest_single","Yes" 22 22 "pthread_cond_broadcast - threads waiting: no preempt","psxtmcond06","psxtmtest_unblocking_nopreempt","No"
Note: See TracChangeset
for help on using the changeset viewer.