Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
From: lovell@sdr.slb.com (John Lovell)
Subject: Re: HELP!! : Unaligned access error on DEC
Date: Tue, 9 Nov 1993 23:06:32 GMT	[thread overview]
Message-ID: <CG8yux.Lsx@sdr.slb.com> (raw)
In-Reply-To: 2boime$fs4@skates.gsfc.nasa.gov

In article fs4@skates.gsfc.nasa.gov, oneel@athena.gsfc.nasa.gov (Bruce O'Neel) writes:
>
>We have code in both fortran and C, and when we call a c routine from
>fortran we get exactly this message.  I figured it was a pointer
>alignment problem (since we pass pointers to the C routine, fortran
>remember?) but is there a way to solve this?
>
>Thanks for any and all help!
>
>bruce
>

Calling C from FORTRAN and vice versa should not necessarily cause you problems on the Alpha. One possibility could be that you are mixing floating point
and double precision addresses. Recall that with ANSI C, given

void test(x)
float x;
{
}

then x must be aligned on a double word boundary but with

void test(float x)
{
}

then x can be aligned on a single word boundary. (To my mind this is a screw-up
with ANSI C, but that's a different issue...)

Regards,

John Lovell, Schlumberger-Doll, Ridgefield, CT 06877
lovell@sdr.slb.com, 203-431-5560








      reply	other threads:[~1993-11-09 23:06 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1993-11-08 12:50 HELP!! : Unaligned access error on DEC Alpha, $OS == osf1 Joseph Jacob
1993-11-08 15:32 ` John T. Kohl
1993-11-08 20:22   ` John T. Kohl
1993-11-09 12:29     ` acssysdsc
1993-11-09 20:26       ` Karen Kolling
1993-11-09 20:45         ` Karen Kolling
1993-11-10 15:06       ` Ken Cowan
1993-11-09  4:26 ` Karen Kolling
1993-11-09 17:06   ` Bruce O'Neel
1993-11-09 23:06     ` John Lovell [this message]
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox