Rev 2745 | Rev 3874 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2745 | Rev 3069 | ||
---|---|---|---|
Line 124... | Line 124... | ||
124 | e = e + 1 / d; |
124 | e = e + 1 / d; |
125 | } |
125 | } |
126 | 126 | ||
127 | if ((int) (100000000 * e) != E_10e8) { |
127 | if ((int) (100000000 * e) != E_10e8) { |
128 | if (!sh_quiet) |
128 | if (!sh_quiet) |
129 | printf("tid%llu: e*10e8=%zd should be %zd\n", THREAD->tid, (unative_t) (100000000 * e), (unative_t) E_10e8); |
129 | printf("tid%" PRIu64 ": e*10e8=%zd should be %" PRIun "\n", THREAD->tid, (unative_t) (100000000 * e), (unative_t) E_10e8); |
130 | atomic_inc(&threads_fault); |
130 | atomic_inc(&threads_fault); |
131 | break; |
131 | break; |
132 | } |
132 | } |
133 | } |
133 | } |
134 | atomic_inc(&threads_ok); |
134 | atomic_inc(&threads_ok); |
Line 159... | Line 159... | ||
159 | } |
159 | } |
160 | 160 | ||
161 | #ifdef KERN_ia64_ARCH_H_ |
161 | #ifdef KERN_ia64_ARCH_H_ |
162 | if ((int) (1000000 * pi) != PI_10e8) { |
162 | if ((int) (1000000 * pi) != PI_10e8) { |
163 | if (!sh_quiet) |
163 | if (!sh_quiet) |
164 | printf("tid%llu: pi*10e8=%zd should be %zd\n", THREAD->tid, (unative_t) (1000000 * pi), (unative_t) (PI_10e8 / 100)); |
164 | printf("tid%" PRIu64 ": pi*10e8=%zd should be %" PRIun "\n", THREAD->tid, (unative_t) (1000000 * pi), (unative_t) (PI_10e8 / 100)); |
165 | atomic_inc(&threads_fault); |
165 | atomic_inc(&threads_fault); |
166 | break; |
166 | break; |
167 | } |
167 | } |
168 | #else |
168 | #else |
169 | if ((int) (100000000 * pi) != PI_10e8) { |
169 | if ((int) (100000000 * pi) != PI_10e8) { |
170 | if (!sh_quiet) |
170 | if (!sh_quiet) |
171 | printf("tid%llu: pi*10e8=%zd should be %zd\n", THREAD->tid, (unative_t) (100000000 * pi), (unative_t) PI_10e8); |
171 | printf("tid%" PRIu64 ": pi*10e8=%zd should be %" PRIun "\n", THREAD->tid, (unative_t) (100000000 * pi), (unative_t) PI_10e8); |
172 | atomic_inc(&threads_fault); |
172 | atomic_inc(&threads_fault); |
173 | break; |
173 | break; |
174 | } |
174 | } |
175 | #endif |
175 | #endif |
176 | } |
176 | } |
Line 185... | Line 185... | ||
185 | waitq_initialize(&can_start); |
185 | waitq_initialize(&can_start); |
186 | atomic_set(&threads_ok, 0); |
186 | atomic_set(&threads_ok, 0); |
187 | atomic_set(&threads_fault, 0); |
187 | atomic_set(&threads_fault, 0); |
188 | 188 | ||
189 | if (!quiet) |
189 | if (!quiet) |
190 | printf("Creating %d threads... ", 2 * THREADS); |
190 | printf("Creating %u threads... ", 2 * THREADS); |
191 | 191 | ||
192 | for (i = 0; i < THREADS; i++) { |
192 | for (i = 0; i < THREADS; i++) { |
193 | thread_t *t; |
193 | thread_t *t; |
194 | 194 | ||
195 | if (!(t = thread_create(e, NULL, TASK, 0, "e", false))) { |
195 | if (!(t = thread_create(e, NULL, TASK, 0, "e", false))) { |
196 | if (!quiet) |
196 | if (!quiet) |
197 | printf("could not create thread %d\n", 2 * i); |
197 | printf("could not create thread %u\n", 2 * i); |
198 | break; |
198 | break; |
199 | } |
199 | } |
200 | thread_ready(t); |
200 | thread_ready(t); |
201 | total++; |
201 | total++; |
202 | 202 | ||
203 | if (!(t = thread_create(pi, NULL, TASK, 0, "pi", false))) { |
203 | if (!(t = thread_create(pi, NULL, TASK, 0, "pi", false))) { |
204 | if (!quiet) |
204 | if (!quiet) |
205 | printf("could not create thread %d\n", 2 * i + 1); |
205 | printf("could not create thread %u\n", 2 * i + 1); |
206 | break; |
206 | break; |
207 | } |
207 | } |
208 | thread_ready(t); |
208 | thread_ready(t); |
209 | total++; |
209 | total++; |
210 | } |
210 | } |