From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18590 invoked by alias); 16 Feb 2015 17:13:18 -0000 Mailing-List: contact libffi-discuss-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libffi-discuss-owner@sourceware.org Received: (qmail 18581 invoked by uid 89); 16 Feb 2015 17:13:17 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Mon, 16 Feb 2015 17:13:16 +0000 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t1GHD8xt017313 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 16 Feb 2015 12:13:08 -0500 Received: from anchor.twiddle.net (vpn-232-213.phx2.redhat.com [10.3.232.213]) by int-mx13.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t1GHD769031298; Mon, 16 Feb 2015 12:13:07 -0500 Message-ID: <54E22522.40909@redhat.com> Date: Mon, 16 Feb 2015 17:13:00 -0000 From: Richard Henderson User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: "John E. Malmberg" , libffi-discuss@sourceware.org Subject: Re: Trying to port libffi to OpenVMS. References: <54DE0378.8040609@qsl.net> <54DE0D25.8020300@redhat.com> <54DE8D61.803@qsl.net> In-Reply-To: <54DE8D61.803@qsl.net> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-IsSubscribed: yes X-SW-Source: 2015/txt/msg00038.txt.bz2 On 02/13/2015 03:48 PM, John E. Malmberg wrote: > On 2/13/2015 8:41 AM, Richard Henderson wrote: >> On 02/13/2015 06:00 AM, John E. Malmberg wrote: >>> I was able to apply Philippe Vouters patches for Libffi 3.0.9 to libffi 3.1 and >>> get the code building. I was unable to get the tests to run under GNV though. >> >> I've never seen those patches but... > > Not sure if I got them via E-mail from someone else, or from his site. His site > is not responding at this time. > > The readme says that they include HP-UX/ia64 and VMS/Alpha and VMS/ia64. What > I have appears to be bunch of concatenated unified diffs. I can gzip it and > forward it to anyone that is interested, uncompressed it is 126 KB. Sure. > I think VMS and Tru64 share a calling standard on Alpha, but I am not sure. Definitely not. > VMS on Itanium uses ELF binaries and calling standard with a few extensions to > ELF. The calling standard is different enough that you'll definitely need changes to the C code, and at least a small change to the assembly to set up the r25 "argument information" register. > In any case, on VMS, the "int lib$callg(void **args, int (*func)())" hides all > that though. I'd be very surprised if this actually passes the testsuite, as you're not giving lib$callg any information about the types of the arguments. This is probably one of those things that worked find on VAX, but only works on Alpha and IA-64 for integer arguments, and a limited number of them at that. > The use of the lib$callg() routine means I should not need any assembly > language code at all. Probably almost the same source for all three current > VMS harware platforms. I'm sure you're going to have to write assembly, at least for Alpha. r~