Changeset b39e961b


Ignore:
Timestamp:
Mar 21, 2022, 1:40:24 PM (2 years ago)
Author:
caparsons <caparson@…>
Branches:
ADT, ast-experimental, enum, master, pthread-emulation, qualifiedEnum
Children:
dbe2533
Parents:
41d3c8d
Message:

fixed stats.hfa include and added monitor to polymorphic test

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/concurrent/mutexstmt/locks.cfa

    r41d3c8d rb39e961b  
    11#include <mutex_stmt.hfa>
    22#include <locks.hfa>
    3 #include <stats.hfa>
    43
    54const unsigned int num_times = 10000;
     
    7675owner_lock l3;
    7776
     77monitor monitor_t {};
     78
     79monitor_t l4;
     80
    7881thread T_Multi_Poly {};
    7982
     
    8184        for (unsigned int i = 0; i < num_times; i++) {
    8285                refTest( l1 );
    83                 mutex ( l1 ) {
     86                mutex ( l1, l4 ) {
    8487                        assert(!insideFlag);
    8588                        insideFlag = true;
     
    9396                        insideFlag = false;
    9497                }
    95                 mutex ( l3, l1 ) {
     98                mutex ( l3, l1, l4 ) {
    9699                        assert(!insideFlag);
    97100                        insideFlag = true;
     
    99102                        insideFlag = false;
    100103                }
    101                 mutex ( l1, l2 ) {
     104                mutex ( l1, l2, l4 ) {
    102105                        assert(!insideFlag);
    103106                        insideFlag = true;
Note: See TracChangeset for help on using the changeset viewer.