source:
src/libcfa/concurrency/threads
@
5c81105
Last change on this file since 5c81105 was 5c81105, checked in by , 7 years ago | |
---|---|
|
|
File size: 890 bytes |
Rev | Line | |
---|---|---|
[78b3f52] | 1 | // -*- Mode: CFA -*- |
[0e76cf4f] | 2 | // |
[78b3f52] | 3 | // Cforall Version 1.0.0 Copyright (C) 2016 University of Waterloo |
[0e76cf4f] | 4 | // |
5 | // The contents of this file are covered under the licence agreement in the | |
6 | // file "LICENCE" distributed with Cforall. | |
7 | // | |
[78b3f52] | 8 | // threads -- |
[0e76cf4f] | 9 | // |
[78b3f52] | 10 | // Author : Thierry Delisle |
11 | // Created On : Mon Nov 28 12:27:26 2016 | |
12 | // Last Modified By : Thierry Delisle | |
13 | // Last Modified On : Mon Nov 28 12:27:26 2016 | |
14 | // Update Count : 0 | |
[0e76cf4f] | 15 | // |
16 | ||
17 | #ifndef __THREADS_H__ | |
18 | #define __THREADS_H__ | |
19 | ||
[5c81105] | 20 | #include "invoke.h" |
[78b3f52] | 21 | |
22 | void ?{}(coStack_t* this); | |
[0e76cf4f] | 23 | |
[9129a84] | 24 | void ?{}(coroutine* this); |
[5c81105] | 25 | void ?{}(coroutine* this, covptr_t* object); |
[9129a84] | 26 | |
[0e76cf4f] | 27 | trait coroutine_t(dtype T) { |
[78b3f52] | 28 | void co_main(T* this); |
[5c81105] | 29 | covptr_t* vtable(T* this); |
[0e76cf4f] | 30 | }; |
31 | ||
[9129a84] | 32 | void suspend(void); |
[0e76cf4f] | 33 | |
34 | forall(dtype T | coroutine_t(T)) | |
35 | void resume(T* cor); | |
36 | ||
37 | #endif //__THREADS_H__ | |
[78b3f52] | 38 | |
39 | // Local Variables: // | |
40 | // mode: c // | |
41 | // tab-width: 4 // | |
42 | // End: // |
Note: See TracBrowser
for help on using the repository browser.