source: src/examples/multicore.c @ 4a3334cf

aaron-thesisarm-ehcleanup-dtorsdeferred_resndemanglerjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprnew-envno_listpersistent-indexerresolv-newwith_gc
Last change on this file since 4a3334cf was 4a3334cf, checked in by Thierry Delisle <tdelisle@…>, 5 years ago

Fixed tests after rename

  • Property mode set to 100644
File size: 371 bytes
Line 
1#include <kernel>
2#include <thread>
3
4struct MyThread { thread t; };
5
6DECL_THREAD(MyThread);
7
8void ?{}( MyThread * this ) {}
9
10void main( MyThread* this ) {
11        for(int i = 0; i < 1000000; i++) {
12                yield();
13        }
14}
15
16int main(int argc, char* argv[]) {
17        // sout | "User main begin" | endl;
18        {
19                processor p;
20                {
21                        scoped(MyThread) f[4];
22                }
23        }
24        // sout | "User main end" | endl;
25}
Note: See TracBrowser for help on using the repository browser.