Ignore:
Timestamp:
Jan 7, 2025, 3:22:19 PM (9 months ago)
Author:
Michael Brooks <mlbrooks@…>
Branches:
master
Children:
190a833
Parents:
70670e7
Message:

Fix many test-suite- and libcfa-caused unused variable warnings.

In scope are easy fixes among tests whose sole warnings were unused variable. Reduces the wflags lax list by 40%.

Location:
tests/concurrency/unified_locking
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • tests/concurrency/unified_locking/locks.cfa

    r70670e7 r10b5970  
    2323thread T_C_M_WS1 {};
    2424
    25 void main( T_C_M_WS1 & this ) {
     25void main( T_C_M_WS1 & ) {
    2626        for (unsigned int i = 0; i < num_times; i++) {
    2727                lock(m);
     
    3737thread T_C_M_WB1 {};
    3838
    39 void main( T_C_M_WB1 & this ) {
     39void main( T_C_M_WB1 & ) {
    4040        for (unsigned int i = 0; i < num_times; i++) {
    4141                lock(m);
     
    5151thread T_C_S_WS1 {};
    5252
    53 void main( T_C_S_WS1 & this ) {
     53void main( T_C_S_WS1 & ) {
    5454        for (unsigned int i = 0; i < num_times; i++) {
    5555                lock(s);
     
    6565thread T_C_S_WB1 {};
    6666
    67 void main( T_C_S_WB1 & this ) {
     67void main( T_C_S_WB1 & ) {
    6868        for (unsigned int i = 0; i < num_times; i++) {
    6969                lock(s);
     
    7979thread T_C_L_WS1 {};
    8080
    81 void main( T_C_L_WS1 & this ) {
     81void main( T_C_L_WS1 & ) {
    8282        for (unsigned int i = 0; i < num_times; i++) {
    8383                lock(l);
     
    9393thread T_C_L_WB1 {};
    9494
    95 void main( T_C_L_WB1 & this ) {
     95void main( T_C_L_WB1 & ) {
    9696        for (unsigned int i = 0; i < num_times; i++) {
    9797                lock(l);
     
    107107thread T_F_C_F_WS1 {};
    108108
    109 void main( T_F_C_F_WS1 & this ) {
     109void main( T_F_C_F_WS1 & ) {
    110110        for (unsigned int i = 0; i < num_times; i++) {
    111111                lock(f);
     
    121121thread T_C_O_WS1 {};
    122122
    123 void main( T_C_O_WS1 & this ) {
     123void main( T_C_O_WS1 & ) {
    124124        for (unsigned int i = 0; i < num_times; i++) {
    125125                lock(o);
     
    135135thread T_C_O_WB1 {};
    136136
    137 void main( T_C_O_WB1 & this ) {
     137void main( T_C_O_WB1 & ) {
    138138        for (unsigned int i = 0; i < num_times; i++) {
    139139                lock(o);
     
    149149thread T_C_M_WS2 {};
    150150
    151 void main( T_C_M_WS2 & this ) {
     151void main( T_C_M_WS2 & ) {
    152152        for (unsigned int i = 0; i < num_times; i++) {
    153153                lock(m);
     
    167167thread T_C_O_WS2 {};
    168168
    169 void main( T_C_O_WS2 & this ) {
     169void main( T_C_O_WS2 & ) {
    170170        for (unsigned int i = 0; i < num_times; i++) {
    171171                lock(o);
     
    185185thread T_C_NLW {};
    186186
    187 void main( T_C_NLW & this ) {
     187void main( T_C_NLW & ) {
    188188        for (unsigned int i = 0; i < num_times; i++) {
    189189                wait(c_o);
     
    193193thread T_C_NLS {};
    194194
    195 void main( T_C_NLS & this ) {
     195void main( T_C_NLS & ) {
    196196        for (unsigned int i = 0; i < num_times; i++) {
    197197                while (empty(c_o)) { }
     
    202202thread T_C_S_WNF {};
    203203
    204 void main( T_C_S_WNF & this ) {
     204void main( T_C_S_WNF & ) {
    205205        for (unsigned int i = 0; i < num_times; i++) {
    206206                lock(s);
     
    219219thread T_C_NLWD {};
    220220
    221 void main( T_C_NLWD & this ) {
     221void main( T_C_NLWD & ) {
    222222        done = false;
    223223        for (unsigned int i = 0; i < num_times/5; i++) {
     
    230230thread T_C_WDS {};
    231231
    232 void main( T_C_WDS & this ) {
     232void main( T_C_WDS & ) {
    233233        for (unsigned int i = 0; i < num_times; i++) {
    234234                while (empty(c_s) && !done) { }
     
    241241thread T_C_LWD {};
    242242
    243 void main( T_C_LWD & this ) {
     243void main( T_C_LWD & ) {
    244244        done = false;
    245245        for (unsigned int i = 0; i < num_times/5; i++) {
     
    254254thread T_C_LWDS {};
    255255
    256 void main( T_C_LWDS & this ) {
     256void main( T_C_LWDS & ) {
    257257        for (unsigned int i = 0; i < num_times; i++) {
    258258                while (empty(c_s) && !done) { }
  • tests/concurrency/unified_locking/pthread_locks.cfa

    r70670e7 r10b5970  
    1818thread Wait_Signal_1 {};
    1919
    20 void main( Wait_Signal_1 & this ) {
     20void main( Wait_Signal_1 & ) {
    2121        for (unsigned int i = 0; i < num_times; i++) {
    2222                lock(l);
     
    3232thread Wait_3_Signal_3 {};
    3333
    34 void main( Wait_3_Signal_3 & this ) {
     34void main( Wait_3_Signal_3 & ) {
    3535        for (unsigned int i = 0; i < num_times; i++) {
    3636                lock(l);
     
    4848thread Rec_Lock_Wait_Signal_1 {};
    4949
    50 void main( Rec_Lock_Wait_Signal_1 & this ) {
     50void main( Rec_Lock_Wait_Signal_1 & ) {
    5151        for (unsigned int i = 0; i < num_times; i++) {
    5252                lock(l);
     
    6666thread Wait_Time_Signal_1 {};
    6767
    68 void main( Wait_Time_Signal_1 & this ) {
     68void main( Wait_Time_Signal_1 & ) {
    6969        for (unsigned int i = 0; i < num_times; i++) {
    7070                lock(l);
     
    7474                        timespec waitTime{0,1};
    7575                        bool woken = wait(c,l, t + waitTime);
     76                        (void) woken;
    7677                }else{
    7778                        notify_one(c);
Note: See TracChangeset for help on using the changeset viewer.