Skip to content
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

TestMetrics_MeasureSince is faling on arm64 #110

Open
lucaskanashiro opened this issue Jul 27, 2020 · 1 comment
Open

TestMetrics_MeasureSince is faling on arm64 #110

lucaskanashiro opened this issue Jul 27, 2020 · 1 comment

Comments

@lucaskanashiro
Copy link

TestMetrics_MeasureSince is failing in Ubuntu Groovy 20.10 (development release) on arm64 (Go 1.14), here is the test log. I patched the test to print m (MockSink) after each call of MeasureSince or MeasureSinceWithLabels (4 calls in this test) and commented out the t.Fatalf("") when m.vals[0] > 0.1. Then I ran the test 5 times, here are the results:

Round 1:
&{{0 0} [[key]] [0.00192] [[]]}
&{{0 0} [[key]] [0.268622] [[{a b}]]}
&{{0 0} [[timer key]] [0.294562] [[]]}
&{{0 0} [[service key]] [0.307243] [[]]}

Round 2:
&{{0 0} [[key]] [0.00228] [[]]}
&{{0 0} [[key]] [0.260842] [[{a b}]]}
&{{0 0} [[timer key]] [0.299362] [[]]}
&{{0 0} [[service key]] [0.314462] [[]]}

Round 3:
&{{0 0} [[key]] [0.00192] [[]]}
&{{0 0} [[key]] [0.334702] [[{a b}]]}
&{{0 0} [[timer key]] [0.373842] [[]]}
&{{0 0} [[service key]] [0.408443] [[]]}

Round 4:
&{{0 0} [[key]] [0.00234] [[]]}
&{{0 0} [[key]] [0.220862] [[{a b}]]}
&{{0 0} [[timer key]] [0.254622] [[]]}
&{{0 0} [[service key]] [0.290202] [[]]}

Round 5:
&{{0 0} [[key]] [0.001481] [[]]}
&{{0 0} [[key]] [0.283643] [[{a b}]]}
&{{0 0} [[timer key]] [0.319363] [[]]}
&{{0 0} [[service key]] [0.332583] [[]]}

As you can see the m.vals[0] is lesser or equal to 0.1 in all rounds only in the first scenario covered by this test, all the others fail because they are greater than 0.1. I am not sure why those operations take longer in arm64 than in other architectures (I did not spend too much time investigating the root cause). As a workaround for now I plan to patch this test in the Debian package to check m.vals[0] > 0.5 instead of m.vals[0] > 0.1.

@lucaskanashiro
Copy link
Author

I forgot to mention but a similar behavior can be identified in Test_GlobalMetrics_MeasureSince, specifically in the scenario with labels which is kind of expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant