Ignore:
Timestamp:
Dec 11, 2020, 11:26:18 AM (3 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
4af1021
Parents:
98168b9 (diff), e4b6b7d3 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/concurrency/io/setup.cfa

    r98168b9 r73a3be5  
    1717#define _GNU_SOURCE         /* See feature_test_macros(7) */
    1818
     19#if defined(__CFA_DEBUG__)
     20        // #define __CFA_DEBUG_PRINT_IO__
     21        // #define __CFA_DEBUG_PRINT_IO_CORE__
     22#endif
     23
    1924#include "io/types.hfa"
    2025#include "kernel.hfa"
     
    111116
    112117        void __kernel_io_startup(void) {
    113                 __cfaabi_dbg_print_safe( "Kernel : Creating EPOLL instance\n" );
     118                __cfadbg_print_safe(io_core, "Kernel : Creating EPOLL instance\n" );
    114119
    115120                iopoll.epollfd = epoll_create1(0);
     
    118123                }
    119124
    120                 __cfaabi_dbg_print_safe( "Kernel : Starting io poller thread\n" );
     125                __cfadbg_print_safe(io_core, "Kernel : Starting io poller thread\n" );
    121126
    122127                iopoll.run = true;
     
    132137                // Wait for the io poller thread to finish
    133138
    134                 pthread_join( iopoll.thrd, 0p );
    135                 free( iopoll.stack );
     139                __destroy_pthread( iopoll.thrd, iopoll.stack, 0p );
    136140
    137141                int ret = close(iopoll.epollfd);
     
    142146                // Io polling is now fully stopped
    143147
    144                 __cfaabi_dbg_print_safe( "Kernel : IO poller stopped\n" );
     148                __cfadbg_print_safe(io_core, "Kernel : IO poller stopped\n" );
    145149        }
    146150
     
    150154                id.id = doregister(&id);
    151155                __cfaabi_tls.this_proc_id = &id;
    152                 __cfaabi_dbg_print_safe( "Kernel : IO poller thread starting\n" );
     156                __cfadbg_print_safe(io_core, "Kernel : IO poller thread starting\n" );
    153157
    154158                // Block signals to control when they arrive
     
    185189                }
    186190
    187                 __cfaabi_dbg_print_safe( "Kernel : IO poller thread stopping\n" );
     191                __cfadbg_print_safe(io_core, "Kernel : IO poller thread stopping\n" );
    188192                unregister(&id);
    189193                return 0p;
Note: See TracChangeset for help on using the changeset viewer.