git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "Øyvind A. Holm" <sunny@sunbase.org>
To: "René Scharfe" <rene.scharfe@lsrfire.ath.cx>
Cc: Junio C Hamano <gitster@pobox.com>,
	git@vger.kernel.org, Thomas Rast <trast@student.ethz.ch>
Subject: Re: [PATCH 3/3] xdiff: import new 32-bit version of count_masked_bytes()
Date: Fri, 25 May 2012 17:18:00 +0200	[thread overview]
Message-ID: <CAA787rkRZudv96wJ4WPFWt7k0Y628dvhxrPes1g6rbw8C_Kiog@mail.gmail.com> (raw)
In-Reply-To: <4FBBF8E9.7020103@lsrfire.ath.cx>

On 22 May 2012 22:36, René Scharfe <rene.scharfe@lsrfire.ath.cx> wrote:
> Import the latest 32-bit implementation of count_masked_bytes() from
> Linux (arch/x86/include/asm/word-at-a-time.h).  It's shorter and avoids
> overflows and negative numbers.
>
> This fixes test failures on 32-bit, where negative partial results had
> been shifted right using the "wrong" method (logical shift right instead
> of arithmetic short right).  The compiler is free to chose the method,
> so it was only wrong in the sense that it didn't work as intended by us.
>
> Reported-by: Øyvind A. Holm <sunny@sunbase.org>
> Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
> ---
> Does this fix all the warnings, and do the tests pass?  I can only
> reproduce the "shifting to far to the right" warning..

Hi, I finally got around to test this, and it compiles flawlessly with
your three patches. No warnings, and the test suite seems to run
without errors.

Nice work, sir.

Cheers,
Øyvind

      reply	other threads:[~2012-05-25 15:18 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-16 23:31 tr/xdiff-fast-hash generates warnings and breaks tests Øyvind A. Holm
2012-05-17  7:11 ` René Scharfe
2012-05-17  9:33   ` Øyvind A. Holm
2012-05-17 16:23   ` Junio C Hamano
2012-05-17 18:40     ` René Scharfe
2012-05-19 14:17       ` Øyvind A. Holm
2012-05-22 20:36         ` [PATCH 1/3] xdiff: avoid compiler warnings with XDL_FAST_HASH on 32-bit machines René Scharfe
2012-05-22 20:36         ` [PATCH 2/3] xdiff: avoid more " René Scharfe
2012-05-23  8:30           ` Thomas Rast
2012-05-22 20:36         ` [PATCH 3/3] xdiff: import new 32-bit version of count_masked_bytes() René Scharfe
2012-05-25 15:18           ` Øyvind A. Holm [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=CAA787rkRZudv96wJ4WPFWt7k0Y628dvhxrPes1g6rbw8C_Kiog@mail.gmail.com \
    --to=sunny@sunbase.org \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=rene.scharfe@lsrfire.ath.cx \
    --cc=trast@student.ethz.ch \
    /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).