Changeset 201abde in mainline for kernel/test/synch/rwlock4.c
- Timestamp:
- 2007-04-07T20:06:52Z (18 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 7e58979
- Parents:
- 6adbe3c2
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/test/synch/rwlock4.c
r6adbe3c2 r201abde 75 75 76 76 if (!sh_quiet) 77 printf("cpu%d, tid % dw+ (%d)\n", CPU->id, THREAD->tid, to);77 printf("cpu%d, tid %llu w+ (%d)\n", CPU->id, THREAD->tid, to); 78 78 79 79 rc = rwlock_write_lock_timeout(&rwlock, to); 80 80 if (SYNCH_FAILED(rc)) { 81 81 if (!sh_quiet) 82 printf("cpu%d, tid % dw!\n", CPU->id, THREAD->tid);82 printf("cpu%d, tid %llu w!\n", CPU->id, THREAD->tid); 83 83 atomic_dec(&thread_count); 84 84 return; … … 86 86 87 87 if (!sh_quiet) 88 printf("cpu%d, tid % dw=\n", CPU->id, THREAD->tid);88 printf("cpu%d, tid %llu w=\n", CPU->id, THREAD->tid); 89 89 90 90 if (rwlock.readers_in) { … … 107 107 108 108 if (!sh_quiet) 109 printf("cpu%d, tid % dw-\n", CPU->id, THREAD->tid);109 printf("cpu%d, tid %llu w-\n", CPU->id, THREAD->tid); 110 110 atomic_dec(&thread_count); 111 111 } … … 120 120 121 121 if (!sh_quiet) 122 printf("cpu%d, tid % dr+ (%d)\n", CPU->id, THREAD->tid, to);122 printf("cpu%d, tid %llu r+ (%d)\n", CPU->id, THREAD->tid, to); 123 123 124 124 rc = rwlock_read_lock_timeout(&rwlock, to); 125 125 if (SYNCH_FAILED(rc)) { 126 126 if (!sh_quiet) 127 printf("cpu%d, tid % dr!\n", CPU->id, THREAD->tid);127 printf("cpu%d, tid %llu r!\n", CPU->id, THREAD->tid); 128 128 atomic_dec(&thread_count); 129 129 return; … … 131 131 132 132 if (!sh_quiet) 133 printf("cpu%d, tid % dr=\n", CPU->id, THREAD->tid);133 printf("cpu%d, tid %llu r=\n", CPU->id, THREAD->tid); 134 134 135 135 thread_usleep(30000); … … 137 137 138 138 if (!sh_quiet) 139 printf("cpu%d, tid % dr-\n", CPU->id, THREAD->tid);139 printf("cpu%d, tid %llu r-\n", CPU->id, THREAD->tid); 140 140 atomic_dec(&thread_count); 141 141 }
Note:
See TracChangeset
for help on using the changeset viewer.