From: Martin Stromberg Message-Id: <200004271205.OAA00093@lws256.lu.erisoft.se> Subject: Re: rand() in libc To: buers AT gmx DOT de Date: Thu, 27 Apr 2000 14:05:34 +0200 (MET DST) Cc: djgpp-workers AT delorie DOT com (DJGPP-WORKERS) In-Reply-To: <200004270947.FAA27604@delorie.com> from "Dieter Buerssner" at Apr 27, 2000 12:52:02 PM X-Mailer: ELM [version 2.5 PL3] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp-workers AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk Dieter said: > I think, the only PRNG in libc, that may be changed, is rand(). The > rand48 family seems to be what I know from Cray and/or some Unix > variants. The random() seems to be BSD random. So changing (even > advancing) these may break some code. (To test a port to djgpp, you > may run a simulation and compare with the expected results.) I'm interested in whether the rand48() functions behave approximately as well as on other architectures/implementations, because I wrote them from scratch and I didn't do any extensive testing (of lack of knowledge how). In particular I wonder how the ones generating doubles (drand48(), erand48()) behave, as I improvised most on them. Right, MartinS