From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id z9xMN4BgKWVVyCwAWB0awg (envelope-from ) for ; Fri, 13 Oct 2023 11:21:36 -0400 Authentication-Results: simark.ca; dkim=pass (2048-bit key; unprotected) header.d=gnu.org header.i=@gnu.org header.a=rsa-sha256 header.s=fencepost-gnu-org header.b=WasFGp4X; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id D41DB1E0C1; Fri, 13 Oct 2023 11:21:36 -0400 (EDT) Received: from server2.sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 8FE441E00F for ; Fri, 13 Oct 2023 11:21:34 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id CF02C385773A for ; Fri, 13 Oct 2023 15:21:33 +0000 (GMT) Received: from eggs.gnu.org (eggs.gnu.org [IPv6:2001:470:142:3::10]) by sourceware.org (Postfix) with ESMTPS id CC9143858D1E for ; Fri, 13 Oct 2023 15:21:13 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org CC9143858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gnu.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gnu.org Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qrJyQ-0000xK-K9; Fri, 13 Oct 2023 11:21:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=EbPTpx/ERpVV0k3E/tnK7urqejnRz5FX+taZQg8/Rqw=; b=WasFGp4XiFJR vBPnB0avSr1X36e5zG7O90MaiNk9t4jPvmcZDQhqATvcy+z1pvDPTFHVL9UWwx41k3llEOMtDM/OH /0oY5y30MbpLZWPp4wiiWKoFXWlacSML7zYC96F6FPAgYLmi9Mh8II1PrrK9+RAKNBr2WONtvRK2E 8ueXIySlb5KjDt/w4oYgEt6wq1VnKQVe3rHyrnAkq+rIOrzozJGlWx4flXfCQCK+KYjKXUwclrSi8 q7rdXcldEkBFb15cWHRZZBdLBNR4DXNEcQWrZNAdgEQOdGBIE7SktxVd1CZTx6iKu39gUn/gpu5uo xQZ75U8ekZFXZrHJiCnhYQ==; Date: Fri, 13 Oct 2023 18:21:08 +0300 Message-Id: <8334yetuor.fsf@gnu.org> From: Eli Zaretskii To: Lancelot Six Cc: gdb-patches@sourceware.org In-Reply-To: <20231013144418.3180617-3-lancelot.six@amd.com> (message from Lancelot Six on Fri, 13 Oct 2023 14:44:09 +0000) Subject: Re: [PATCH 02/11] gdb/gdbsupport/gdbserver: Require c++17 References: <20231013144418.3180617-1-lancelot.six@amd.com> <20231013144418.3180617-3-lancelot.six@amd.com> X-Spam-Status: No, score=-5.2 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_NUMSUBJECT, KAM_SHORT, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org > From: Lancelot Six > CC: Lancelot Six > Date: Fri, 13 Oct 2023 14:44:09 +0000 > > This patch proposes to require a C++17 compiler to build gdb / > gdbsupport / gdbserver. Before this patch, GDB required a C++11 > compiler. > > The general policy regarding bumping C++ language requirement in GDB (as > stated in [1]) is: > > Our general policy is to wait until the oldest compiler that > supports C++NN is at least 3 years old. > > Rationale: We want to ensure reasonably widespread compiler > availability, to lower barrier of entry to GDB contributions, and to > make it easy for users to easily build new GDB on currently > supported stable distributions themselves. 3 years should be > sufficient for latest stable releases of distributions to include a > compiler for the standard, and/or for new compilers to appear as > easily installable optional packages. Requiring everyone to build a > compiler first before building GDB, which would happen if we > required a too-new compiler, would cause too much inconvenience. > > See the policy proposal and discussion > [here](https://sourceware.org/ml/gdb-patches/2016-10/msg00616.html). > > The first GCC release which with full C++17 support is GCC-9[2], > released in 2019[3], which is over 4 years ago. Clang has had C++17 > support since Clang-5[4] released in 2018[5]. > > A discussions with many distros showed that a C++17-able compiler is > always available, meaning that this no hard requirement preventing us to > require it going forward. > > [1] https://sourceware.org/gdb/wiki/Internals%20GDB-C-Coding-Standards#When_is_GDB_going_to_start_requiring_C.2B-.2B-NN_.3F > [2] https://gcc.gnu.org/projects/cxx-status.html#cxx17 > [3] https://gcc.gnu.org/gcc-9/ > [4] https://clang.llvm.org/cxx_status.html > [5] https://releases.llvm.org/ > > Change-Id: Id596f5db17ea346e8a978668825787b3a9a443fd > --- > gdb/NEWS | 3 + > gdb/config.in | 4 +- > gdb/configure | 1970 ++++++++++++++++++++++++++++++++++----- > gdb/configure.ac | 4 +- > gdbserver/config.in | 4 +- > gdbserver/configure | 1970 ++++++++++++++++++++++++++++++++++----- > gdbserver/configure.ac | 4 +- > gdbsupport/Makefile.in | 2 +- > gdbsupport/config.in | 4 +- > gdbsupport/configure | 1970 ++++++++++++++++++++++++++++++++++----- > gdbsupport/configure.ac | 4 +- > 11 files changed, 5212 insertions(+), 727 deletions(-) > > diff --git a/gdb/NEWS b/gdb/NEWS > index 81264c0cfb3..8ab2e4c593a 100644 > --- a/gdb/NEWS > +++ b/gdb/NEWS > @@ -3,6 +3,9 @@ > > *** Changes since GDB 14 > > +* Building GDB and GDBserver now requires a C++17 compiler. > + For example, GCC 9 or later. > + > * GDB index now contains information about the main function. This speeds up > startup when it is being used for some large binaries. The NEWS part is okay, thanks. Reviewed-By: Eli Zaretskii