From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by sourceware.org (Postfix) with ESMTP id C23B23858416 for ; Tue, 6 Jun 2023 07:47:59 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org C23B23858416 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 8C191AB6; Tue, 6 Jun 2023 00:48:44 -0700 (PDT) Received: from localhost (e121540-lin.manchester.arm.com [10.32.110.72]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 51E693F793; Tue, 6 Jun 2023 00:47:58 -0700 (PDT) From: Richard Sandiford To: Tamar Christina Mail-Followup-To: Tamar Christina ,gcc-patches@gcc.gnu.org, nd@arm.com, richard.earnshaw@arm.com, richard.sandiford@arm.com Cc: gcc-patches@gcc.gnu.org, nd@arm.com, richard.earnshaw@arm.com Subject: Re: [PATCH v2] machine descriptor: New compact syntax for insn and insn_split in Machine Descriptions. References: Date: Tue, 06 Jun 2023 08:47:57 +0100 In-Reply-To: (Richard Sandiford's message of "Mon, 05 Jun 2023 21:35:06 +0100") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-28.1 required=5.0 tests=BAYES_00,GIT_PATCH_0,KAM_DMARC_NONE,KAM_DMARC_STATUS,KAM_LAZY_DOMAIN_SECURITY,SPF_HELO_NONE,SPF_NONE,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Richard Sandiford writes: >> diff --git a/gcc/gensupport.h b/gcc/gensupport.h >> index a1edfbd71908b6244b40f801c6c01074de56777e..7925e22ed418767576567cad583bddf83c0846b1 100644 >> --- a/gcc/gensupport.h >> +++ b/gcc/gensupport.h >> @@ -20,6 +20,7 @@ along with GCC; see the file COPYING3. If not see >> #ifndef GCC_GENSUPPORT_H >> #define GCC_GENSUPPORT_H >> >> +#include "hash-set.h" >> #include "read-md.h" >> >> struct obstack; >> @@ -218,6 +219,8 @@ struct pattern_stats >> int num_operand_vars; >> }; >> >> +extern hash_set compact_syntax; >> + >> extern void get_pattern_stats (struct pattern_stats *ranges, rtvec vec); >> extern void compute_test_codes (rtx, file_location, char *); >> extern file_location get_file_location (rtx); >> diff --git a/gcc/gensupport.cc b/gcc/gensupport.cc >> index f9efc6eb7572a44b8bb154b0b22be3815bd0d244..f1d6b512356844da5d1dadbc69e08c16ef7a3abd 100644 >> --- a/gcc/gensupport.cc >> +++ b/gcc/gensupport.cc >> @@ -27,12 +27,17 @@ >> #include "read-md.h" >> #include "gensupport.h" >> #include "vec.h" >> +#include >> +#include >> +#include Also: these need to be included via defining: #define INCLUDE_STRING #define INCLUDE_VECTOR before system.h. The ctype.h include should go away after s/isalpha/ISALPHA/. >> >> #define MAX_OPERANDS 40 >> >> static rtx operand_data[MAX_OPERANDS]; >> static rtx match_operand_entries_in_pattern[MAX_OPERANDS]; >> static char used_operands_numbers[MAX_OPERANDS]; >> +/* List of entries which are part of the new syntax. */ >> +hash_set compact_syntax; > > Might as well make this static too, like the other vars. Sorry, ignore that. I somehow glazed over the header file changes directly above... Richard