| ... | @@ -418,8 +418,8 @@ test "Futex - Signal" { | ... | @@ -418,8 +418,8 @@ test "Futex - Signal" { |
| 418 | fn runThread(rx: *Self, tx: *Self) void { | 418 | fn runThread(rx: *Self, tx: *Self) void { |
| 419 | var iterations: u32 = start_value; | 419 | var iterations: u32 = start_value; |
| 420 | while (iterations < 10) : (iterations += 1) { | 420 | while (iterations < 10) : (iterations += 1) { |
| 421 | self.rx.recv(iterations); | 421 | rx.recv(iterations); |
| 422 | self.tx.send(iterations); | 422 | tx.send(iterations); |
| 423 | } | 423 | } |
| 424 | } | 424 | } |
| 425 | | 425 | |
| ... | @@ -528,11 +528,11 @@ test "Futex - Chain" { | ... | @@ -528,11 +528,11 @@ test "Futex - Chain" { |
| 528 | const Self = @This(); | 528 | const Self = @This(); |
| 529 | | 529 | |
| 530 | fn runThread(self: *Self, index: usize) void { | 530 | fn runThread(self: *Self, index: usize) void { |
| 531 | const this_signal = &chain.self.threads[chain.index].signal; | 531 | const this_signal = &self.threads[index].signal; |
| 532 | | 532 | |
| 533 | var next_signal = &chain.self.completed; | 533 | var next_signal = &self.completed; |
| 534 | if (chain.index + 1 < chain.self.threads.len) { | 534 | if (index + 1 < self.threads.len) { |
| 535 | next_signal = &chain.self.threads[chain.index + 1].signal; | 535 | next_signal = &self.threads[index + 1].signal; |
| 536 | } | 536 | } |
| 537 | | 537 | |
| 538 | this_signal.wait(); | 538 | this_signal.wait(); |