From nobody Tue Apr 15 03:10:46 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1544759233239410.0960166239515; Thu, 13 Dec 2018 19:47:13 -0800 (PST) Received: from localhost ([::1]:59207 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gXeRU-00056E-7t for importer@patchew.org; Thu, 13 Dec 2018 22:47:12 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59036) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gXe1E-0006Iu-Cn for qemu-devel@nongnu.org; Thu, 13 Dec 2018 22:20:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gXe1D-0007mB-BR for qemu-devel@nongnu.org; Thu, 13 Dec 2018 22:20:04 -0500 Received: from mail-oi1-x234.google.com ([2607:f8b0:4864:20::234]:40818) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gXe1D-0007ko-4U for qemu-devel@nongnu.org; Thu, 13 Dec 2018 22:20:03 -0500 Received: by mail-oi1-x234.google.com with SMTP id t204so3458047oie.7 for ; Thu, 13 Dec 2018 19:20:03 -0800 (PST) Received: from cloudburst.twiddle.net ([187.217.227.243]) by smtp.gmail.com with ESMTPSA id g138sm2367537oib.26.2018.12.13.19.20.01 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 13 Dec 2018 19:20:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=HOR5xbwz9EmkIQh396vVWN9pPwvDwijcaDuswD3C1fw=; b=EMDnI1jZ0d8jqxIWCW7HGi6cPoYL8hCm7of6wJJueuAWBm+GcrWMXe65MfS+6fQ4De bKwkMUlqF2l0wGvfnW2zbOxTSqxAMLq6g/UAjw8WlDUbhFCJJHA8OFAEV4PvdaSTEPFf bdVy/3ejpG+Q8eQZWIA6tlHb9Cw8aZRHJfXfs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=HOR5xbwz9EmkIQh396vVWN9pPwvDwijcaDuswD3C1fw=; b=XWXQnfqtjF1sKz9dP+OttyxzajRscLnEIpkQ1XlcOVDVhZ7MphzJ0kJr85YKQMJd7L 4BjzxuJp2H1m33AmC15wYcorhIyxeT5nwH1etCyidNAC1fm+Jz45xBX0Pd2Fa8cY8ghB Ds6nQw6kpH7S6MlnqoYk23TDkcDC6qvePDw/11K6iQfFftRCMSG3B5xVZZeNl7FeQBgh VVjIyTErZoueDCxbWUpiefo4v3dqBTxF7ZALRH0xFO9UH6hP+L9XTssxFXccWZOfX46R 1JfPddy21ztU/eTXUXFet2+NJN6JrluABjzPpd2tDj/4X0vDoXlr7x1EsCE0vVlNuILK r3Jw== X-Gm-Message-State: AA+aEWZDnCYOEEVkpZyw/JwzICJEcebN2ULL4KoFMbuIJIjD9cDQq2oN mV78YL7K9Q5T+40oMg5xw5HfTxct9ckv/w== X-Google-Smtp-Source: AFSGD/XDBmHHMtH7CPc+ImAUkS2dgllSWD8Zkjn/uPPAJOfmlbL0qmek4Qk912QroEPp7GDgLMPQCg== X-Received: by 2002:aca:ce86:: with SMTP id e128mr836161oig.247.1544757602230; Thu, 13 Dec 2018 19:20:02 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Date: Thu, 13 Dec 2018 21:19:23 -0600 Message-Id: <20181214031923.29527-34-richard.henderson@linaro.org> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20181214031923.29527-1-richard.henderson@linaro.org> References: <20181214031923.29527-1-richard.henderson@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::234 Subject: [Qemu-devel] [PULL 32/32] xxhash: match output against the original xxhash32 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: peter.maydell@linaro.org, "Emilio G. Cota" Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) From: "Emilio G. Cota" Change the order in which we extract a/b and c/d to match the output of the upstream xxhash32. Tested with: https://github.com/cota/xxhash/tree/qemu Reviewed-by: Alex Benn=C3=A9e Tested-by: Alex Benn=C3=A9e Signed-off-by: Emilio G. Cota Signed-off-by: Richard Henderson --- include/qemu/xxhash.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/qemu/xxhash.h b/include/qemu/xxhash.h index fe35dde328..076f1f6054 100644 --- a/include/qemu/xxhash.h +++ b/include/qemu/xxhash.h @@ -55,10 +55,10 @@ qemu_xxhash7(uint64_t ab, uint64_t cd, uint32_t e, uint= 32_t f, uint32_t g) uint32_t v2 =3D QEMU_XXHASH_SEED + PRIME32_2; uint32_t v3 =3D QEMU_XXHASH_SEED + 0; uint32_t v4 =3D QEMU_XXHASH_SEED - PRIME32_1; - uint32_t a =3D ab >> 32; - uint32_t b =3D ab; - uint32_t c =3D cd >> 32; - uint32_t d =3D cd; + uint32_t a =3D ab; + uint32_t b =3D ab >> 32; + uint32_t c =3D cd; + uint32_t d =3D cd >> 32; uint32_t h32; =20 v1 +=3D a * PRIME32_2; --=20 2.17.2