[Bug c++/41019] Variate_generator with mt19937 and normal_distribution produces wrong sequence for "-O3".
m_albert137 at yahoo dot com
gcc-bugzilla@gcc.gnu.org
Sun Aug 9 21:02:00 GMT 2009
------- Comment #1 from m_albert137 at yahoo dot com 2009-08-09 21:02 -------
Created an attachment (id=18332)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=18332&action=view)
Example code
When compiled below -O3 (e.g., -O2), this code gives:
0 -0.29321891723895837645
1 0.25316081895796688217
2 -0.057085487765685671846
with -O3:
0 0.31678484080597951733
1 0.27675012391718101235
2 0.14034606328371523887
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41019
More information about the Gcc-bugs
mailing list