ADT
aaron-thesis
arm-eh
ast-experimental
cleanup-dtors
deferred_resn
demangler
enum
forall-pointer-decay
jacob/cs343-translation
jenkins-sandbox
new-ast
new-ast-unique-expr
no_list
persistent-indexer
pthread-emulation
qualifiedEnum
|
Last change
on this file since 094a42c was 7bdcac1, checked in by Thierry Delisle <tdelisle@…>, 7 years ago |
|
Added the option to make longrun tests run until failure
|
-
Property mode
set to
100644
|
|
File size:
435 bytes
|
| Line | |
|---|
| 1 | #include <kernel>
|
|---|
| 2 | #include <thread>
|
|---|
| 3 | #include <time>
|
|---|
| 4 |
|
|---|
| 5 | #include "long_tests.h"
|
|---|
| 6 |
|
|---|
| 7 | #ifndef PREEMPTION_RATE
|
|---|
| 8 | #error PREEMPTION_RATE not defined in makefile
|
|---|
| 9 | #endif
|
|---|
| 10 |
|
|---|
| 11 | Duration default_preemption() {
|
|---|
| 12 | return PREEMPTION_RATE;
|
|---|
| 13 | }
|
|---|
| 14 |
|
|---|
| 15 | static const unsigned long N = 60_000ul;
|
|---|
| 16 |
|
|---|
| 17 | thread worker_t {};
|
|---|
| 18 |
|
|---|
| 19 | void main(worker_t & this) {}
|
|---|
| 20 |
|
|---|
| 21 | int main(int argc, char* argv[]) {
|
|---|
| 22 | processor p;
|
|---|
| 23 | for(int i = 0; TEST(i < N); i++) {
|
|---|
| 24 | worker_t w[7];
|
|---|
| 25 | KICK_WATCHDOG;
|
|---|
| 26 | }
|
|---|
| 27 | }
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.