git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jeff King <peff@peff.net>
To: Jeffrey Walton <noloader@gmail.com>
Cc: Git List <git@vger.kernel.org>
Subject: Re: not ok 41 - test ident field is working
Date: Fri, 3 May 2019 16:50:52 -0400	[thread overview]
Message-ID: <20190503205052.GA17551@sigill.intra.peff.net> (raw)
In-Reply-To: <CAH8yC8kqHDDqsu++3an69Oq--hhabV8LGawD3uccykFYQDFvsw@mail.gmail.com>

On Fri, May 03, 2019 at 04:18:02PM -0400, Jeffrey Walton wrote:

> I'm catching one failed self test under a sanitizer build. It looks
> like there's some latent UB present during 'make check'

How are you providing sanitizer options? If you're just putting
-fsanitize=undefined in the compiler flags, that is known to fail. For
example, on some platforms we'll default to unaligned loads when it's
faster and well-defined on that platform.

And that's what you're seeing here:

> read-cache.c:1943:22: runtime error: load of misaligned address 0x7fba278d61ab f
> or type 'unsigned int', which requires 4 byte alignment

since this is a get_be32() call.

You can can add -DNO_UNALIGNED_LOADS to fix this. However, we have some
Makefile logic for doing this already, and:

  make SANITIZE=undefined test

should work. My normal test for memory problems is:

  make SANITIZE=address,undefined test

-Peff

      reply	other threads:[~2019-05-03 20:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-03 20:18 not ok 41 - test ident field is working Jeffrey Walton
2019-05-03 20:50 ` Jeff King [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: http://vger.kernel.org/majordomo-info.html

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

  git send-email \
    --in-reply-to=20190503205052.GA17551@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=git@vger.kernel.org \
    --cc=noloader@gmail.com \
    /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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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).