Changeset a55472cc


Ignore:
Timestamp:
Oct 11, 2022, 1:14:04 PM (18 months ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, ast-experimental, master
Children:
1e30df7, 3fcb5921, 4f102fa
Parents:
a46f7b6
Message:

Removed use of single_sem in io since oneshot is sufficient and used more consistently

Location:
libcfa/src/concurrency
Files:
2 edited

Legend:

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

    ra46f7b6 ra55472cc  
    551551                enqueue(this.pending, (__outstanding_io&)pa);
    552552
    553                 wait( pa.sem );
     553                wait( pa.waitctx );
    554554
    555555                return pa.ctx;
     
    578578                                pa.ctx = ctx;
    579579
    580                                 post( pa.sem );
     580                                post( pa.waitctx );
    581581                        }
    582582
     
    613613                }
    614614
    615                 wait( ei.sem );
     615                wait( ei.waitctx );
    616616
    617617                __cfadbg_print_safe(io, "Kernel I/O : %u submitted from arbiter\n", have);
     
    631631                                        __submit_only(&ctx, ei.idxs, ei.have);
    632632
    633                                         post( ei.sem );
     633                                        post( ei.waitctx );
    634634                                }
    635635
  • libcfa/src/concurrency/io/types.hfa

    ra46f7b6 ra55472cc  
    107107        struct __outstanding_io {
    108108                inline Colable;
    109                 single_sem sem;
     109                oneshot waitctx;
    110110        };
    111111        static inline __outstanding_io *& Next( __outstanding_io * n ) { return (__outstanding_io *)Next( (Colable *)n ); }
Note: See TracChangeset for help on using the changeset viewer.