Date: Tue, 8 Oct 1996 09:08:47 +0200 (MET DST) From: J Wunsch <j@uriah.heep.sax.de> To: freebsd-hackers@freebsd.org (FreeBSD hackers) Subject: Re: I plan to change random() for -current (was Re: rand() and random()) Message-ID: <199610080708.JAA19288@uriah.heep.sax.de> In-Reply-To: <199610072337.JAA12712@godzilla.zeta.org.au> from Bruce Evans at "Oct 8, 96 09:37:50 am"
next in thread | previous in thread | raw e-mail | index | archive | help
As Bruce Evans wrote: > >They give repeatable results, cross platform, from the desk machine to the > >supercomputer. > > Nope, they give results that vary across platforms and across time. 16-bit > systems can't even represent the values returned by BSD rand(). Systems with different values for RAND_MAX are also unlikely to give the same results. Since the standard specifies RAND_MAX, it is apparently intented that this might be an implementation-defined constant. ;-) We could even ship the (non-broken) 16-bit version with a 32-bit system, whereas RADN_MAX is as low as 32767 then. Btw., we've already bumped our libc's shared library major version number for the next release. Thus, applications that are linked against the old shared lib will continue to use the unrandom function, and only newly linked applications will suff^H^H^H^Hbenefit from the change, where the programmer could have got the time to read the documentation. ;-) p.s.: Please, folks, i don't need three copies of each article in this thread. Restrict it's scope to -hackers, and kill the Cc list next time you are sending a followup. It is always an error for people to mail something to both, -hackers and -current (*), and it is always bad behaviour to not cut down overlong Cc lists that arise out of the laziness of quick-shoot followup posters, even when they know that all the folks involved in the discussion are surely on the lists. (*) No, the common excuse: ``I wanna reach people running -current, _and_ the wider audience of -hackers.'' doesn't count: most of the subscribers of -current are also on -hackers. Those few who aren't did unsubscribe from -hackers on purpose, they simply don't care about discussions of that kind. Thus, -hackers is always the forum of choice if you can't decide between both. -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199610080708.JAA19288>