From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (qmail 9451 invoked from network); 24 Oct 1999 15:06:11 -0000 Received: from mail.redhat.com (199.183.24.239) by lists.redhat.com with SMTP; 24 Oct 1999 15:06:11 -0000 Received: from voicenet.com (mail12.voicenet.com [207.103.0.6]) by mail.redhat.com (8.8.7/8.8.7) with SMTP id LAA29653 for ; Sun, 24 Oct 1999 11:06:10 -0400 Received: (qmail 23677 invoked from network); 24 Oct 1999 15:06:08 -0000 Received: from dialpool0342-pri.voicenet.com (HELO voicenet.com) (209.71.85.170) by mail12.voicenet.com with SMTP; 24 Oct 1999 15:06:08 -0000 Sender: gat@mail.redhat.com Message-ID: <38131FDD.C888DB8@voicenet.com> Date: Sun, 24 Oct 1999 11:03:57 -0400 From: Uncle George Organization: Big-Endian X-Mailer: Mozilla 4.07 [en] (X11; I; Linux 2.0.36 i686) MIME-Version: 1.0 To: axp-list@redhat.com, Dan Morrill Subject: Re: Function parameter weirdness References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Dear flummoxed: What u have caught, as it has caught many of the unwary, is the methods of maddness employed in passing parameters via register on the 64bit alpha. What u see in your int compare is only what u believe is happening. In reality there is a long compare happening ( there is no int compare as part of the hardware instruction set ). At the time of compare, the subroutine presumes that the Hi-Order Word ( 32bit ) is properly sign extended ( +=0fill, -= 0xffffffff filled ) BEFOR-HAND . So if u look at the register ( with gdb ) u will see ur 9600 in the right half, but something else in the left half - junk. One might presume that since the variable is 32 bits, that only the right half will be used - BUT THIS AINT JUST SO. this is especially so in compares. This sorta makes the case for getting ur parameter casts properly done. And I'm sure there is gonna be a question of the JNI for java/alpha. The JNI for JDK1.2 got a whole lot better at figuring out what to do with parameters & return values. But then that is what SUN designed into their assembler/JNI interface, and I had little choice but to follow. The JNI interface for jdk118 was a lot simpler, more stupid, and not at all intelligent about what gets put in the unused bits of the register.. :-\ Shazzbott, where's an orkin when u need one. .Dan Morrill wrote: > > > Okay, here's a weird one for the gurii. I am attempting to get the JavaComm > package working with UG's JDK 1.1.8. The JavaCOMM API requires that you have > a native JNI driver for your platform; the one for Linux is called > RXTX (at http://www.frii.com/~jarvi/rxtx/ ). > > > Anyone have any ideas? This has got me mightily flummoxed. > > My machine is an SX164; kernel 2.2.12. More info available upon request. > >