From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1534) id 9AD1238560B9; Wed, 18 Oct 2023 10:24:18 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 9AD1238560B9 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1697624658; bh=4740lWl6CDyYB1IvMURxuihRMg9JXlL7t1C11+HRlWo=; h=From:To:Subject:Date:From; b=kiEFy8+V1UDQpjWLEvQvgF3Su2TESv9OgHWWzYCjzVxtAaoE2d+TkDj5JfWQR5I8m 3oA5PkO5Aa17KMX+9K7L9r3PpSWqnDpQTSz4ANwdFmIJ5YP6YhF9/88f30pp3bMFyD mS+sAybpyFkwjfllty+jfOP+C/hzQ7A2FMgMLeOk= MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Tobias Burnus To: gcc-cvs@gcc.gnu.org Subject: [gcc r14-4718] nvptx: Use fatal_error when -march= is missing not an assert [PR111093] X-Act-Checkin: gcc X-Git-Author: Tobias Burnus X-Git-Refname: refs/heads/master X-Git-Oldrev: a4184c8a65a00eaf8a8d7f92fb8ad2f8621b39e2 X-Git-Newrev: d3961765b506f75233e6ea144a80930629c3426b Message-Id: <20231018102418.9AD1238560B9@sourceware.org> Date: Wed, 18 Oct 2023 10:24:18 +0000 (GMT) List-Id: https://gcc.gnu.org/g:d3961765b506f75233e6ea144a80930629c3426b commit r14-4718-gd3961765b506f75233e6ea144a80930629c3426b Author: Tobias Burnus Date: Wed Oct 18 12:23:38 2023 +0200 nvptx: Use fatal_error when -march= is missing not an assert [PR111093] gcc/ChangeLog: PR target/111093 * config/nvptx/nvptx.cc (nvptx_option_override): Issue fatal error instead of an assert ICE when no -march= has been specified. Diff: --- gcc/config/nvptx/nvptx.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gcc/config/nvptx/nvptx.cc b/gcc/config/nvptx/nvptx.cc index edef39fb5e1e..634c31673be9 100644 --- a/gcc/config/nvptx/nvptx.cc +++ b/gcc/config/nvptx/nvptx.cc @@ -335,8 +335,9 @@ nvptx_option_override (void) init_machine_status = nvptx_init_machine_status; /* Via nvptx 'OPTION_DEFAULT_SPECS', '-misa' always appears on the command - line. */ - gcc_checking_assert (OPTION_SET_P (ptx_isa_option)); + line; but handle the case that the compiler is not run via the driver. */ + if (!OPTION_SET_P (ptx_isa_option)) + fatal_error (UNKNOWN_LOCATION, "%<-march=%> must be specified"); handle_ptx_version_option ();