Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/libcfa/concurrency/thread

    rd67cdb7 r83a071f9  
     1//                              -*- Mode: CFA -*-
    12//
    23// Cforall Version 1.0.0 Copyright (C) 2016 University of Waterloo
     
    910// Author           : Thierry Delisle
    1011// Created On       : Tue Jan 17 12:27:26 2017
    11 // Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sat Jul 22 09:59:40 2017
    13 // Update Count     : 3
     12// Last Modified By : Thierry Delisle
     13// Last Modified On : --
     14// Update Count     : 0
    1415//
    1516
    16 #pragma once
     17#ifndef THREADS_H
     18#define THREADS_H
    1719
    18 #include <assert.h>
     20#include "assert"
    1921#include "invoke.h"
    2022
     
    3638forall( dtype T | is_thread(T) )
    3739static inline coroutine_desc* get_coroutine(T & this) {
    38         return &get_thread(this)->self_cor;
     40        return &get_thread(this)->cor;
    3941}
    4042
    4143forall( dtype T | is_thread(T) )
    4244static inline monitor_desc* get_monitor(T & this) {
    43         return &get_thread(this)->self_mon;
     45        return &get_thread(this)->mon;
    4446}
    4547
    4648static inline coroutine_desc* get_coroutine(thread_desc * this) {
    47         return &this->self_cor;
     49        return &this->cor;
    4850}
    4951
    5052static inline monitor_desc* get_monitor(thread_desc * this) {
    51         return &this->self_mon;
     53        return &this->mon;
    5254}
    5355
    54 extern thread_local thread_desc * volatile this_thread;
     56extern volatile thread_local thread_desc * this_thread;
    5557
    5658forall( dtype T | is_thread(T) )
     
    8284void yield( unsigned times );
    8385
     86#endif //THREADS_H
     87
    8488// Local Variables: //
    8589// mode: c //
Note: See TracChangeset for help on using the changeset viewer.