From owner-freebsd-arch Tue Feb 27 10:30:53 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mail.rpi.edu (mail.rpi.edu [128.113.100.7]) by hub.freebsd.org (Postfix) with ESMTP id 2BD9637B71A; Tue, 27 Feb 2001 10:30:50 -0800 (PST) (envelope-from drosih@rpi.edu) Received: from [128.113.24.47] (gilead.acs.rpi.edu [128.113.24.47]) by mail.rpi.edu (8.9.3/8.9.3) with ESMTP id NAA60644; Tue, 27 Feb 2001 13:30:48 -0500 Mime-Version: 1.0 X-Sender: drosih@mail.rpi.edu Message-Id: In-Reply-To: <20010226231515.B94159@citusc17.usc.edu> References: <20010226202701.A13175@hub.freebsd.org> <200102270622.XAA13867@usr05.primenet.com> <20010226231515.B94159@citusc17.usc.edu> Date: Tue, 27 Feb 2001 13:30:46 -0500 To: Kris Kennaway , Terry Lambert From: Garance A Drosihn Subject: Re: rand(3) (was Re: cvs commit: ports/astro/xglobe/files patch-random) Cc: "Jacques A. Vidrine" , arch@FreeBSD.ORG Content-Type: text/plain; charset="us-ascii" ; format="flowed" Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG At 11:15 PM -0800 2/26/01, Kris Kennaway wrote: >There are really only two possibilities for addressing this: > >1) Change rand() to work better > >and/or > >2) Make rand() yell louder when people use it or 3) Assume the world will survive if we leave things the way they have been for the past eight years. No change necessary. >Some people are opposed to both solutions (mainly you for 1). It is not necessarily clear that -arch is a "statistically valid sampling" of people who use rand(). >Okay, now I'm annoyed. I just looked at glibc, and it already does >what is being discussed here, namely aliasing rand() to random() >(which appears to be the same algorithm we use for random()). Good, now we're all annoyed. Here is a routine which EXPLICITLY says "Hey, this is a routine which really sucks at generating random numbers", and people complain when they use it and get sucky random numbers. >There goes your "pseudo-standardization" argument out the window, >which means you obviously hadn't checked your facts and were just >describing the state of your internal fantasy universe. Thanks >for wasting everyone's time with this silly thread. I am aware of other people who live in the same fantasy universe, so I think this thread is spiraling downwards. A few of those people even ran tests to see if rand() produced the same results across the platforms they cared about, and once that was proven, they just assumed that would remain true (most of them are doing comparisons across time, though, not across platforms. Still, "across time" tends to become "across platforms", as hardware changes around here). It *is* interesting to find out that glibc does use the same algorithm as random(). Glibc hasn't been used much among the people I'm thinking of, but it's certainly getting used more as linux makes inroads on campus. Now I am also wondering if rand() still produces similar results across the other unix platforms we have on campus. I have not responded on this thread before now, because I really thought it was a silly thing for people to get worked up about and that it would die down and we'd get back to trivial issues, like SMPng or something. However, this thread now seems to be descending into inflammatory rubbish, and if we're all going to go up on flames on such a silly topic, then I think I'll be standing on Terry's side of the barbecue. Even if Terry didn't check glibc (that bastion of UNIX standardization) to prove his position, his position *is* one that others *have* had, and he isn't just bringing it up to annoy you folks. So maybe calm down a little bit. The checking of glibc was a good idea, and maybe we could do a bit more checking to see what other platforms are doing. We may very well find out that we're the odd one out because we HAVEN'T changed rand to = random, in which case we'll have a very good case to make the same change. But then we can do it based on facts, instead of getting upset and claiming people live in fantasy universes. As I said before, I don't really care which way it goes, but it is pretty silly that we can't figure out a calmer way to resolve this thread, instead of just ranting back and forth about it. -- Garance Alistair Drosehn = gad@eclipse.acs.rpi.edu Senior Systems Programmer or gad@freebsd.org Rensselaer Polytechnic Institute or drosih@rpi.edu To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message