aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/test/driver_SUITE.erl
diff options
context:
space:
mode:
authorSverker Eriksson <[email protected]>2017-12-12 21:58:25 +0100
committerSverker Eriksson <[email protected]>2017-12-12 21:58:25 +0100
commita72a33e51218b1584f87629a9725665c22f9eb09 (patch)
tree553295ed42a5275b0907c04f454798f385877435 /erts/emulator/test/driver_SUITE.erl
parent003e5450924c4d8202e2013cac41eff58fa90584 (diff)
downloadotp-a72a33e51218b1584f87629a9725665c22f9eb09.tar.gz
otp-a72a33e51218b1584f87629a9725665c22f9eb09.tar.bz2
otp-a72a33e51218b1584f87629a9725665c22f9eb09.zip
erts: Trim driver_SUITE:smp_select for slow valgrind
Symptom: "Closing pipe in state Waiting. Event lost?" Snake oil: Do erlang:yield() instead of busy spinning in "Waiting" state.
Diffstat (limited to 'erts/emulator/test/driver_SUITE.erl')
-rw-r--r--erts/emulator/test/driver_SUITE.erl5
1 files changed, 4 insertions, 1 deletions
diff --git a/erts/emulator/test/driver_SUITE.erl b/erts/emulator/test/driver_SUITE.erl
index 6810729285..c31ceb4d4b 100644
--- a/erts/emulator/test/driver_SUITE.erl
+++ b/erts/emulator/test/driver_SUITE.erl
@@ -1673,7 +1673,10 @@ smp_select0(Config) ->
smp_select_loop(_, 0) ->
ok;
smp_select_loop(Port, N) ->
- "ok" = erlang:port_control(Port, ?CHKIO_SMP_SELECT, []),
+ case erlang:port_control(Port, ?CHKIO_SMP_SELECT, []) of
+ "yield" -> erlang:yield();
+ "ok" -> ok
+ end,
receive
stop ->
io:format("Worker ~p stopped with ~p laps left\n",[self(), N]),