From nobody Fri Jul 8 19:53:32 2022 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 5AA68180F2B3; Fri, 8 Jul 2022 19:53:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4LfkVN1zTzz3W5H; Fri, 8 Jul 2022 19:53:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1657310012; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=97WSMtMojhaHYubprwD8LBtDdy4ArnIgdfAOVMbbzeg=; b=Y72EpG8sUhaaMONl/GYEsJjgI1PoJtpxz7CeEeew2zCKMHNaq6ltFzdAIx4JK6XJ9rgu3w pY5GVySnFmxlh8P9ycmm2Or3f6nwX278wtOpRYrhhwpZBxYJqrxlA1aIYIeq6Bs57AS9fL wjM0LNwS/d3E92pigPJdr73pTEx4y5m25GV/bgijaSPc71cGyUPtMfgRBMrNxvgORC99qH xp8zvGk+50tYN6H4uKSfgKVSoy1Oa4grCZCeJeWiKXoa6BNBJ8hzWE19ww6gMgRTTSUrIE LwNuv2kxXinYKTAzzlYCf3cvByErvki3GkznjF0qx6AFtry8xlUr4n2CbG5SZw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4LfkVN11GDzJy1; Fri, 8 Jul 2022 19:53:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 268JrWBm045241; Fri, 8 Jul 2022 19:53:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 268JrWPF045240; Fri, 8 Jul 2022 19:53:32 GMT (envelope-from git) Date: Fri, 8 Jul 2022 19:53:32 GMT Message-Id: <202207081953.268JrWPF045240@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Dmitri Goutnik Subject: git: 69d8cd0cd0f3 - main - lang/go{-devel,118}: Add GOAMD64 knobs List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dmgk X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 69d8cd0cd0f31aa9578ce0fd795374308730ea81 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1657310012; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=97WSMtMojhaHYubprwD8LBtDdy4ArnIgdfAOVMbbzeg=; b=cEHiSlhf4VS5YzSFQRwp6xpaXwNEyFrhn9CKb73VI+reYiQGLq9blYQrA0ObJmbfvh2LAe evy26me4sbBLkm3J5g+lmpqwU+JrD+UehAn0+X4jEIklFvNhdkEbjCpJi+LkFowoKYZysw TF6kySR9WXuy8Y9DCH6eByGAt2ExDmPZNu7+tMN1xrKmFILcZ36p3/fPavYOwXeVT9ixud QjIKRfjxSXWomM80YOTmY/Oxqb+2kdo5e+2jn/uPFNA5/TYiPurmtvL94LDO/ADoo8OBDB rlX0SfyKvYB7sKzJqpfEDvsbqRynxbSY2X0r+F1rhrmaN+deCRxKUfM4oZU5DQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1657310012; a=rsa-sha256; cv=none; b=PtxfakQ8hYR9QV8HyPKZqtOZZu+gwXbQdMSRTfw9JKi/JkloSNADkQ79+vXKuU/0JSZ9el Lyv93YMF6qTY8u96ExMXCYD/16hDZX+bXV0zIZ/wimQjmna7yWahdJIC/u8OmAtPp7ap++ deBoCuuU8/F/mn/fJsZORFI3Gbth8X3GLx2IewSkaXJiiesukn2qtblh1w1dekDDM/yZjB uQh/Ft5CeR5uMz+jHaHPhDf/N+nL1gYI4fofB62zIVIAIX0hRz0VAW5AxnHFHeLgmudhxL o8b1CA9LZd+Q61BtZE9IlIFKggxTXurFThswg0T9dqIK2uWFBIn/RkAghV+fWA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by dmgk: URL: https://cgit.FreeBSD.org/ports/commit/?id=69d8cd0cd0f31aa9578ce0fd795374308730ea81 commit 69d8cd0cd0f31aa9578ce0fd795374308730ea81 Author: Dmitri Goutnik AuthorDate: 2022-07-08 19:38:47 +0000 Commit: Dmitri Goutnik CommitDate: 2022-07-08 19:53:00 +0000 lang/go{-devel,118}: Add GOAMD64 knobs Add amd64 microarchitecture level knobs for the Go compiler. Note that this will affect only the compiler itself, port users will still need to set GOAMD64 in the environment to adjust the microarchitecture of the compiled code [1, 2]. Set default to the baseline level for the maximum backward compatibility. GOAMD64=v1 (default): The baseline. Exclusively generates instructions that all 64-bit x86 processors can execute. GOAMD64=v2: all v1 instructions, plus CMPXCHG16B, LAHF, SAHF, POPCNT, SSE3, SSE4.1, SSE4.2, SSSE3. GOAMD64=v3: all v2 instructions, plus AVX, AVX2, BMI1, BMI2, F16C, FMA, LZCNT, MOVBE, OSXSAVE. GOAMD64=v4: all v3 instructions, plus AVX512F, AVX512BW, AVX512CD, AVX512DQ, AVX512VL. [1] https://github.com/golang/go/wiki/MinimumRequirements#microarchitecture-support [2] https://tip.golang.org/doc/go1.18#amd64 --- lang/go-devel/Makefile | 17 ++++++++++++++++- lang/go118/Makefile | 2 +- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/lang/go-devel/Makefile b/lang/go-devel/Makefile index 90b0e076ff1d..17d0f59e4c55 100644 --- a/lang/go-devel/Makefile +++ b/lang/go-devel/Makefile @@ -2,7 +2,7 @@ PORTNAME= go DISTVERSION?= g20220706 -PORTREVISION?= 0 +PORTREVISION?= 1 CATEGORIES= lang MASTER_SITES?= https://github.com/dmgk/go-bootstrap/releases/download/${BOOTSTRAP_TAG}/:bootstrap \ LOCAL/dmgk:bootstrap @@ -48,8 +48,21 @@ SHEBANG_GLOB= *.bash *.pl *.sh EXTRACT_CMD= ${SETENV} LC_ALL=en_US.UTF-8 ${TAR} OPTIONS_DEFINE_i386= SOFTFLOAT +OPTIONS_DEFAULT_amd64= V1 +OPTIONS_SINGLE= ${OPTIONS_SINGLE_${ARCH}} +OPTIONS_SINGLE_amd64= GOAMD64 +OPTIONS_SINGLE_GOAMD64= V1 V2 V3 V4 + SOFTFLOAT_DESC= Use soft float on non-SSE2 processors (Pentium 4 and older) SOFTFLOAT_VARS= GO386=softfloat +V1_DESC= Use baseline x86-64 instruction set +V1_VARS= GOAMD64=v1 +V2_DESC= V1 instructions plus CMPXCHG16B, LAHF, SAHF, POPCNT, SSE* +V2_VARS= GOAMD64=v2 +V3_DESC= V2 instructions plus AVX*, BMI*, F16C, FMA, LZCNT, MOVBE, OSXSAVE +V3_VARS= GOAMD64=v3 +V4_DESC= V3 instructions plus AVX512* +V4_VARS= GOAMD64=v4 BOOTSTRAP_TAG= go1.17.9 GO_SUFFIX= ${PKGNAMESUFFIX} @@ -86,6 +99,7 @@ do-build: GOARCH=${GOARCH_${ARCH}} \ GO386=${GO386} \ GOARM=${GOARM_${ARCH}} \ + GOAMD64=${GOAMD64} \ CC=${CC} \ ${SH} make.bash -v @@ -109,6 +123,7 @@ do-test: GOARCH=${GOARCH_${ARCH}} \ GO386=${GO386} \ GOARM=${GOARM_${ARCH}} \ + GOAMD64=${GOAMD64} \ CC=${CC} \ ${SH} run.bash -no-rebuild diff --git a/lang/go118/Makefile b/lang/go118/Makefile index 0d25c03786f1..34d23cfd78c5 100644 --- a/lang/go118/Makefile +++ b/lang/go118/Makefile @@ -2,7 +2,7 @@ DISTVERSION= 1.18.3 # Always set PORTREVISION explicitly as otherwise they are inherited from lang/go-devel -PORTREVISION= 0 +PORTREVISION= 1 MASTER_SITES= https://golang.org/dl/ \ https://github.com/dmgk/go-bootstrap/releases/download/${BOOTSTRAP_TAG}/:bootstrap \ LOCAL/dmgk:bootstrap