public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Richard Sandiford <richard.sandiford@arm.com>
To: Tamar Christina <tamar.christina@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.
Date: Tue, 06 Jun 2023 08:47:57 +0100	[thread overview]
Message-ID: <mptilc1rpzm.fsf@arm.com> (raw)
In-Reply-To: <mptpm69sl51.fsf@arm.com> (Richard Sandiford's message of "Mon, 05 Jun 2023 21:35:06 +0100")

Richard Sandiford <richard.sandiford@arm.com> 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<rtx> 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 <string>
>> +#include <vector>
>> +#include <ctype.h>

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<rtx> 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

  reply	other threads:[~2023-06-06  7:47 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-18 16:30 [PATCH] RFC: " Tamar Christina
2023-04-21 17:18 ` Richard Sandiford
2023-04-24  8:33   ` Richard Sandiford
2023-05-16 13:56     ` Richard Earnshaw (lists)
2023-04-24  9:05   ` Tamar Christina
2023-04-24  9:37     ` Richard Sandiford
2023-06-05 13:51 ` [PATCH v2] machine descriptor: " Tamar Christina
2023-06-05 20:35 ` Richard Sandiford
2023-06-06  7:47   ` Richard Sandiford [this message]
2023-06-06 12:00   ` Tamar Christina
2023-06-06 12:49     ` Richard Sandiford
2023-06-06 16:13       ` Richard Earnshaw (lists)
2023-06-08  9:58         ` Tamar Christina
2023-06-08 10:12           ` Andreas Schwab
2023-06-08 10:29             ` Richard Earnshaw (lists)
2023-06-08 10:33               ` Richard Earnshaw (lists)
2023-06-08 14:24           ` Richard Sandiford
2023-06-08 16:49           ` Mikael Morin
2023-06-13 15:26             ` Tamar Christina
2023-06-14 19:41               ` Richard Sandiford
2023-06-15  6:24                 ` Richard Sandiford

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=mptilc1rpzm.fsf@arm.com \
    --to=richard.sandiford@arm.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=nd@arm.com \
    --cc=richard.earnshaw@arm.com \
    --cc=tamar.christina@arm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).