Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upBound sampler buffer, add length feedback message, fix intermittence in test #23139
Conversation
highfive
commented
Mar 30, 2019
|
Heads up! This PR modifies the following files:
|
|
@jdm I think this should fix the intermittent issue in the tests, and I hope this isn't just extra code to support the tests, since one can also imagine the extra message later becoming useful to show feedback on the sampling process in devtools and the likes, a little bit like the performance feature show below... |
1643138
to
a317e1a
|
Sending the constellation a message after every single sample for each thread seems excessive :) to fix the intermittency of the test, I think we should just check that >0 samples were taken and wait for 100ms. For the bounding, a VecDeque is a good idea, but 100 is a really small number of samples. It should be configurable via the enabling message, and we should try to bound it by time, rather than number of samoles, defaulting to 10s. |
a2afb54
to
fb8cba1
|
@jdm Ok, I've added an attempt to limit the sampling in time. Re checking the number of samples in the test, it appears to me that an issue there is that we only receive the data after having stopped the sampling, so we could do another round if not enough have been taken, and it would seem to make the test too complicated(we would also have to limit the number of tries, and decide on what to do in the unlikely case that all tries resulted in not enough frames having been sampled). I've instead increased the sleep to 100ms, which seems to reduce the chance of sampling less than 2 rounds to something close to zero(I get 8 or 9 samples taken on a few test runs locally with 100ms, as opposed to 2 or 3 with 30ms). |
fb8cba1
to
0780298
|
@bors-servo r+ |
|
|
…, r=jdm Bound sampler buffer, add length feedback message, fix intermittence in test <!-- Please describe your changes on the following line: --> --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [ ] `./mach build -d` does not report any errors - [ ] `./mach test-tidy` does not report any errors - [ ] These changes fix #23109 (GitHub issue number if applicable) <!-- Either: --> - [ ] There are tests for these changes OR - [ ] These changes do not require tests because ___ <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/23139) <!-- Reviewable:end -->
|
|

gterzian commentedMar 30, 2019
•
edited by SimonSapin
./mach build -ddoes not report any errors./mach test-tidydoes not report any errorsThis change is