public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: John Kohl <jtk@rational.com>
To: linux-ia64@vger.kernel.org
Subject: [Linux-ia64] ABI change in gcc for ia64?
Date: Thu, 21 Dec 2000 13:34:39 +0000	[thread overview]
Message-ID: <marc-linux-ia64-105590678205872@msgid-missing> (raw)

[-- Attachment #1: Type: text/plain, Size: 462 bytes --]

Was there an ABI change for gcc for ia64 between 
"old":	    gcc version 2.9-ia64-000216-final
"new":	    gcc version 2.96-ia64-000717 snap 001117

We are seeing interoperation failures between code compiled with these
two versions, related to structure passing (thankfully, user-space only
for now).

I've got a test case which shows this:

caller (tv1.c)	    callee (blah.c)	result
old		    old	   		OK
old		    new			BAD
new		    old			BAD
new		    new			OK


[-- Attachment #2: ~/src/tv-test/tv1.c --]
[-- Type: text/plain, Size: 425 bytes --]

#include <sys/types.h>
#include <sys/socket.h>
#include <sys/time.h>

extern void blah(
    struct sockaddr_in *__raddr,
    u_long __program,
    u_long __version,
    struct timeval __wait_resend,
    int *__sockp
);

char carray[] = "Hi there.\n";

main()
{
    struct timeval tv;
    char *cp = carray;
    int i = 37;

    tv.tv_sec = 1;
    tv.tv_usec = 2;

    blah(NULL, 32, 33, tv, &i);
}


[-- Attachment #3: ~/src/tv-test/blah.c --]
[-- Type: text/plain, Size: 610 bytes --]

#include <sys/types.h>
#include <sys/socket.h>
#include <sys/time.h>

extern void
blah(
    struct sockaddr_in *__raddr,
    u_long __program,
    u_long __version,
    struct timeval __wait_resend,
    int *__sockp
);

extern void
blah(
    struct sockaddr_in *__raddr,
    u_long __program,
    u_long __version,
    struct timeval tv,
    int *ip
)
{
    printf("raddr = %p\n", __raddr);
    printf("prog = %d\nvers = %d\n", __program, __version);
    printf("tv.tv_sec = %d\ntv.tv_usec = %d\nip = %p\n",
           tv.tv_sec, tv.tv_usec, ip);
    printf("int = %d\n", *ip);
}


                 reply	other threads:[~2000-12-21 13:34 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=marc-linux-ia64-105590678205872@msgid-missing \
    --to=jtk@rational.com \
    --cc=linux-ia64@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox