Received: by mail.netbsd.org (Postfix, from userid 605) id BC54A84F23; Sun, 29 May 2022 10:36:21 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id EBE8E84EE8 for ; Sun, 29 May 2022 10:36:20 +0000 (UTC) X-Virus-Scanned: amavisd-new at netbsd.org Received: from mail.netbsd.org ([127.0.0.1]) by localhost (mail.netbsd.org [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id ha-wKvsY9-Iy for ; Sun, 29 May 2022 10:36:20 +0000 (UTC) Received: from cvs.NetBSD.org (ivanova.NetBSD.org [IPv6:2001:470:a085:999:28c:faff:fe03:5984]) by mail.netbsd.org (Postfix) with ESMTP id 7F12384D53 for ; Sun, 29 May 2022 10:36:20 +0000 (UTC) Received: by cvs.NetBSD.org (Postfix, from userid 500) id 7CEF5F984; Sun, 29 May 2022 10:37:21 +0000 (UTC) Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" MIME-Version: 1.0 Date: Sun, 29 May 2022 10:37:21 +0000 From: "Roland Illig" Subject: CVS commit: src/games/gomoku To: source-changes@NetBSD.org X-Mailer: log_accum Message-Id: <20220529103721.7CEF5F984@cvs.NetBSD.org> Sender: source-changes-owner@NetBSD.org List-Id: Precedence: bulk Reply-To: source-changes-d@NetBSD.org Mail-Reply-To: "Roland Illig" Mail-Followup-To: source-changes-d@NetBSD.org List-Unsubscribe: Module Name: src Committed By: rillig Date: Sun May 29 10:37:21 UTC 2022 Modified Files: src/games/gomoku: bdinit.c gomoku.h main.c makemove.c pickmove.c Log Message: gomoku: turn spotstr.s_frame into a frame index Most calculations are done on the frame index, not the pointer. This avoids dealing with ptrdiff_t conversion to int. Changing the type of s_frame changes the size of struct spotstr, it is now 56 bytes on LP64 and 48 bytes on ILP32, neither of which is a power of two. Remove the dummy padding since compilers no longer generate division instructions for divisions by small integer constants, so that optimization is no longer necessary. No functional change. To generate a diff of this commit: cvs rdiff -u -r1.29 -r1.30 src/games/gomoku/bdinit.c cvs rdiff -u -r1.48 -r1.49 src/games/gomoku/gomoku.h cvs rdiff -u -r1.68 -r1.69 src/games/gomoku/main.c cvs rdiff -u -r1.35 -r1.36 src/games/gomoku/makemove.c cvs rdiff -u -r1.52 -r1.53 src/games/gomoku/pickmove.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.