[PATCH] libstdc++: Introduce scale factor in 30_threads/future/members/poll.cc [PR98678]
Rainer Orth
ro@CeBiTec.Uni-Bielefeld.DE
Mon Jun 10 11:54:15 GMT 2024
30_threads/future/members/poll.cc consistently FAILs on Solaris/x86
(both 32 and 64-bit):
FAIL: 30_threads/future/members/poll.cc -std=gnu++17 execution test
/vol/gcc/src/hg/master/local/libstdc++-v3/testsuite/30_threads/future/members/poll.cc:95: int main(): Assertion 'wait_until_sys_min < (ready * 100)' failed.
wait_for(0s): 11892ns for 200 calls, avg 59.46ns per call
wait_until(system_clock minimum): 1304458ns for 200 calls, avg 6522.29ns per call
wait_until(steady_clock minimum): 1403221ns for 200 calls, avg 7016.1ns per call
wait_until(system_clock epoch): 3343806ns for 200 calls, avg 16719ns per call
wait_until(steady_clock epoch: 2959581ns for 200 calls, avg 14797.9ns per call
wait_for when ready: 10969ns for 200 calls, avg 54.845ns per call
As reported in the PR, across a considerable range of CPUs the test
doesn't complete in the expected time. Therefore, this patch introduces
a Solaris/x86 specific scale factor to allow for that.
There's no such issue on Solaris/SPARC, though.
Tested on i386-pc-solaris2.11 and sparc-sun-solaris2.11.
Ok for trunk?
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
2024-06-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
libstdc++-v3:
PR libstdc++/98678
* testsuite/30_threads/future/members/poll.cc (main): Introduce
scale factor.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: sol2-libstdc++-poll-scale.patch
Type: text/x-patch
Size: 1473 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/libstdc++/attachments/20240610/7ed77e35/attachment.bin>
More information about the Libstdc++
mailing list