This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[PATCH] aarch64: make the type of reg_entry::type aarch64_reg_type
- From: tbsaunde+binutils at tbsaunde dot org
- To: binutils at sourceware dot org
- Cc: Trevor Saunders <tbsaunde+binutils at tbsaunde dot org>
- Date: Thu, 23 Jun 2016 08:50:39 -0400
- Subject: [PATCH] aarch64: make the type of reg_entry::type aarch64_reg_type
- Authentication-results: sourceware.org; auth=none
From: Trevor Saunders <tbsaunde+binutils@tbsaunde.org>
Hi,
This should make it a little clearer what the field holds.
built and tested aarch64-elf without failures, ok?
Trev
gas/ChangeLog:
2016-06-23 Trevor Saunders <tbsaunde+binutils@tbsaunde.org>
* config/tc-aarch64.c: Make the type of reg_entry::type
aarch_reg_type.
---
gas/config/tc-aarch64.c | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/gas/config/tc-aarch64.c b/gas/config/tc-aarch64.c
index 4dac753..bbac93e 100644
--- a/gas/config/tc-aarch64.c
+++ b/gas/config/tc-aarch64.c
@@ -247,15 +247,6 @@ struct reloc_entry
bfd_reloc_code_real_type reloc;
};
-/* Structure for a hash table entry for a register. */
-typedef struct
-{
- const char *name;
- unsigned char number;
- unsigned char type;
- unsigned char builtin;
-} reg_entry;
-
/* Macros to define the register types and masks for the purpose
of parsing. */
@@ -301,7 +292,7 @@ typedef struct
#define MULTI_REG_TYPE(T,V) BASIC_REG_TYPE(T)
/* Register type enumerators. */
-typedef enum
+typedef enum aarch64_reg_type_
{
/* A list of REG_TYPE_*. */
AARCH64_REG_TYPES
@@ -314,6 +305,15 @@ typedef enum
#undef MULTI_REG_TYPE
#define MULTI_REG_TYPE(T,V) V,
+/* Structure for a hash table entry for a register. */
+typedef struct
+{
+ const char *name;
+ unsigned char number;
+ ENUM_BITFIELD (aarch64_reg_type_) type : 8;
+ unsigned char builtin;
+} reg_entry;
+
/* Values indexed by aarch64_reg_type to assist the type checking. */
static const unsigned reg_type_masks[] =
{
--
2.8.1