-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Static scheduler #241
base: main
Are you sure you want to change the base?
Static scheduler #241
Changes from 88 commits
7de874e
48d5bbf
0a76f87
66b22cc
2015f09
05622fd
4616369
f3e3ba0
5d79291
bf504df
bfe021d
3e4bd00
995a014
edcae4f
a6e08b3
42cad35
e497088
6aab8ed
d2f5c9a
176b74a
f2cc481
321e17c
aafa8c7
402d1da
fbdb4ac
e606e51
f669991
26bb4af
26439fc
e7eac8a
2387ae6
0ffbcc4
fc5fb2b
185a0ae
2d3c89c
ccedcab
890c54e
7bea24f
740d5cc
ac59cfa
838ad16
031412e
e9edc18
d3d39e9
bb5ae6d
4d32a5c
90e8c8b
e49225a
d4a1127
ce03252
8971b1f
3e498c8
ce9d422
0f30f05
2512f0c
4118922
31428ab
2fe28a6
7fd9ba0
ebbdb7c
ccf50e5
cac23fb
a47356b
261cb8b
55bb599
57fffe1
3dbb4a1
2d27f14
3635412
40b45dd
4c57e17
e27fcd9
f783227
e89f09a
ca533a9
ec0f645
d4af904
732b13a
4ad2cdf
05fcd4c
0969328
884386e
bd0b5a2
c7b7285
0e1e61b
3a37b15
2e0f2ff
b230663
cd5a633
44313a2
5f1c224
11dc8de
7ab1111
6188090
4c8f3fd
d76e82e
08e2506
5874882
700835b
998f555
e8975a9
51e63f6
1082131
1837c6c
75df70f
9b4b818
e8f0d54
6538c34
c63e804
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
@@ -66,7 +66,9 @@ void lf_set_present(lf_port_base_t* port) { | |||||||||
int wait_until(environment_t* env, instant_t wakeup_time) { | ||||||||||
if (!fast) { | ||||||||||
LF_PRINT_LOG("Waiting for elapsed logical time " PRINTF_TIME ".", wakeup_time - start_time); | ||||||||||
return lf_clock_interruptable_sleep_until_locked(env, wakeup_time); | ||||||||||
// return lf_clock_interruptable_sleep_until_locked(env, wakeup_time); | ||||||||||
while (lf_time_physical() < wakeup_time); | ||||||||||
return 0; | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Avoid using a busy-wait loop. The busy-wait loop in the - while (lf_time_physical() < wakeup_time);
+ return lf_clock_interruptable_sleep_until_locked(env, wakeup_time); Committable suggestion
Suggested change
|
||||||||||
} | ||||||||||
return 0; | ||||||||||
} | ||||||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider renaming
_lf_get_token
to_lf_get_new_token
and clarify the function's logic.The comments suggest that the function name
_lf_get_token
is a misnomer and should be renamed to_lf_get_new_token
. Additionally, the logic of calling_lf_free_token_value
or_lf_done_using
should be clarified.Would you like assistance in refactoring the function name and clarifying the logic?