unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: Andy Wingo <wingo@pobox.com>
To: mhw@netris.org
Cc: 20567@debbugs.gnu.org, "Schaefer, Frank" <frank.schaefer@tekcomms.com>
Subject: bug#20567: guile 2.0.11 - test failures on mips64 big-endian with n32 ABI
Date: Fri, 24 Jun 2016 07:17:50 +0200	[thread overview]
Message-ID: <87k2hfjhc1.fsf@pobox.com> (raw)
In-Reply-To: <14E7D810D073F84195C3EE3EBF1E9C35746EB81C@US-PLNO-EXM01-P.global.tektronix.net> (Frank Schaefer's message of "Wed, 13 May 2015 18:31:12 +0000")

Mark does this ring a bell to you?  I know you have a mip64 n32 machine
that you use sometimes.

Andy

On Wed 13 May 2015 20:31, "Schaefer, Frank" <frank.schaefer@tekcomms.com> writes:

> I've encountered two test failures with guile 2.0.11 on mips64
> big-endian, whenever I build with -mabi=n32 (these test failures do
> not occur with -mabi=64).  At least one of them I have resolved with
> the attached patch.
>
> First testcase failure: test-ffi (fixed by my patch).  The guile code
> apparently assumes that sizeof(ffi_arg)<=sizeof(void **).  This is a
> faulty assumption; it holds on *most* platforms, but with the mips64
> n32 ABI, sizeof(void **)==4, and sizeof(ffi_arg)==8.  So every foreign
> function that returns a pointer is liable to corrupt data, and anyone
> retrieving the return value as a simple void * is only going to get
> sign-extension garbage on big-endian (usually NULL).
>
> Second testcase failure: check-guile fails due to 'ERROR:
> foreign.test: procedure->pointer: qsort - arguments:
> ((null-pointer-error "pointer->bytevector" "null pointer dereference"
> () ()))'.  I strongly suspect it's related to the ffi_arg issue
> mentioned above, but I'm still peeling away macro ugliness to track it
> down.  If anyone wants to pitch in with additional guidance or
> patchwork, I'd be happy to listen and test.
>
> (The patch applies against 2.0.11 release or against current HEAD,
> where it also fixes the new testcases for test-foreign-object-scm and
> test-foreign-object-c.  HEAD also fails the test-out-of-memory case,
> though, which precludes further unit tests.)





      reply	other threads:[~2016-06-24  5:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-13 18:31 bug#20567: guile 2.0.11 - test failures on mips64 big-endian with n32 ABI Schaefer, Frank
2016-06-24  5:17 ` Andy Wingo [this message]

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

  List information: https://www.gnu.org/software/guile/

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

  git send-email \
    --in-reply-to=87k2hfjhc1.fsf@pobox.com \
    --to=wingo@pobox.com \
    --cc=20567@debbugs.gnu.org \
    --cc=frank.schaefer@tekcomms.com \
    --cc=mhw@netris.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).