@@ -1123,13 +1123,13 @@ static void* update_ports_from_staa_offsets(void* args) {
11231123 // we require a minimum wait time here. Note that zero-valued STAAs are
11241124 // included, and STA might be zero or very small.
11251125 // In this case, this thread will fail to ever release the environment mutex.
1126- // This causes chaos. The MIN_SLEEP_DURATION is the smallest amount of time
1126+ // This causes chaos. The lf_min_sleep_duration is the smallest amount of time
11271127 // that wait_until will actually wait. Note that this strategy does not
11281128 // block progress of any execution that is actually processing events.
11291129 // It only slightly delays the decision that an event is absent, and only
11301130 // if the STAA and STA are extremely small.
1131- if (wait_time < 5 * MIN_SLEEP_DURATION ) {
1132- wait_until_time += 5 * MIN_SLEEP_DURATION ;
1131+ if (wait_time < 5 * lf_min_sleep_duration ) {
1132+ wait_until_time += 5 * lf_min_sleep_duration ;
11331133 }
11341134 while (a_port_is_unknown (staa_elem )) {
11351135 LF_PRINT_DEBUG ("**** (update thread) waiting until: " PRINTF_TIME , wait_until_time - lf_time_start ());
@@ -1197,7 +1197,7 @@ static void* update_ports_from_staa_offsets(void* args) {
11971197 // The wait is necessary to prevent a busy wait, which will only occur if port
11981198 // status are always known inside the while loop
11991199 // Be sure to use wait_until() instead of sleep() because sleep() will not release the mutex.
1200- instant_t wait_until_time = lf_time_add (env -> current_tag .time , 2 * MIN_SLEEP_DURATION );
1200+ instant_t wait_until_time = lf_time_add (env -> current_tag .time , 2 * lf_min_sleep_duration );
12011201 wait_until (wait_until_time , & lf_port_status_changed );
12021202
12031203 continue ;
0 commit comments