Hi,

Text says it all.  OK for web pages?

Best regards

        Thomas

Mention issues with integer owerflow for random number generators.

This mentions the issues with integer overflow and how to work
around them.
diff --git a/htdocs/gcc-13/porting_to.html b/htdocs/gcc-13/porting_to.html
index 0ee58802..7d733b16 100644
--- a/htdocs/gcc-13/porting_to.html
+++ b/htdocs/gcc-13/porting_to.html
@@ -203,11 +203,20 @@ class Alloc
 <p>
 Since C++20, there is no <code>rebind</code> member in
 <code>std::allocator</code>, so deriving your own allocator types from
-<code>std::allocator</code> is simpler and doesn't require the derived
+<code>std::allocator</code> is simpler and does not require the derived
 allocator to provide its own <code>rebind</code>.
 For compatibility with previous C++ standards, the member should still be
 provided. The converting constructor is still required even in C++20.
 </p>
 
+<h2 id="fortran">Fortran language issues</h2>
+<h3 id="overflow">Behavior on integer overflow</h3>
+<p> GCC 13 includes new optimizations which expose reliance on
+  non-standard behavior for integer overflow, which was often used
+  for linear congruential pseudo-random number generators in old
+  programs.  It is recommended to use the intrinsic
+  subroutine <code>RANDOM_NUMBER</code> for random number generators
+  or, if the old behavior is desired, to use the <code>-fwrapv</code>
+  option.  Note that this option can impact performance.
 </body>
 </html>

Reply via email to