Skip to content

poll and epoll: wait for timeout even with no fd's#1697

Merged
sporksmith merged 1 commit intoshadow:mainfrom
sporksmith:b1549
Oct 1, 2021
Merged

poll and epoll: wait for timeout even with no fd's#1697
sporksmith merged 1 commit intoshadow:mainfrom
sporksmith:b1549

Conversation

@sporksmith
Copy link
Copy Markdown
Contributor

@sporksmith sporksmith commented Oct 1, 2021

In particular, curl uses poll with nfds=0 but a non-zero timeout to wait in what would otherwise be a busy-loop that doesn't advance time.

Progress on #1549

@github-actions github-actions bot added Component: Main Composing the core Shadow executable Component: Testing Unit and integration tests and frameworks labels Oct 1, 2021
@codecov
Copy link
Copy Markdown

codecov bot commented Oct 1, 2021

Codecov Report

Merging #1697 (6b886bf) into main (9b0e7e9) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #1697   +/-   ##
=======================================
  Coverage   56.25%   56.25%           
=======================================
  Files         140      140           
  Lines       18567    18564    -3     
  Branches     4477     4476    -1     
=======================================
- Hits        10444    10443    -1     
+ Misses       5403     5402    -1     
+ Partials     2720     2719    -1     
Flag Coverage Δ
tests 56.25% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/main/host/syscall/poll.c 81.08% <100.00%> (-0.50%) ⬇️
src/main/host/status_listener.c 68.00% <0.00%> (-2.00%) ⬇️
src/main/host/syscall/unistd.c 56.87% <0.00%> (-0.63%) ⬇️
src/main/host/descriptor/socket.c 65.67% <0.00%> (-0.38%) ⬇️
src/main/host/descriptor/file.c 29.16% <0.00%> (-0.19%) ⬇️
src/main/host/syscall/socket.c 78.63% <0.00%> (-0.15%) ⬇️
src/main/host/process.c 68.95% <0.00%> (+0.40%) ⬆️
src/main/host/descriptor/descriptor.c 73.93% <0.00%> (+0.60%) ⬆️
src/main/host/descriptor/epoll.c 75.80% <0.00%> (+0.64%) ⬆️
src/main/host/syscall/mman.c 65.90% <0.00%> (+0.75%) ⬆️
... and 1 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9b0e7e9...6b886bf. Read the comment docs.

@sporksmith sporksmith merged commit 154a11d into shadow:main Oct 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Component: Main Composing the core Shadow executable Component: Testing Unit and integration tests and frameworks

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants