Re: [PATCH 1/2][ARM] Record FPU features as a bit-set
On Mon, Aug 10, 2015 at 11:28:06AM +0100, Matthew Wahab wrote: Ping. Updated patch attached. Also, retested the series for arm-none-linux-gnueabihf with native bootstrap and make check. On 22/06/15 16:16, Matthew Wahab wrote: Hello, The ARM backend records FPU features as booleans, one for each feature. This means that adding support for a new feature involves updating every entry in the list of FPU descriptions in arm-fpus.def. This patch series changes the representation of FPU features to use a simple bit-set and flags, as is done elsewhere. This patch adds the new FPU feature representation, with feature sets represented as unsigned longs. Tested the series for arm-none-linux-gnueabihf with check-gcc Ok for trunk? Matthew This is OK, thanks Ramana gcc/ 2015-06-22 Matthew Wahab matthew.wa...@arm.com * config/arm/arm.h (arm_fpu_fset): New. (ARM_FPU_FSET_HAS): New. (FPU_FL_NONE): New. (FPU_FL_NEON): New. (FPU_FL_FP16): New. (FPU_FL_CRYPTO): New. From 571416d9e7bc9cb6c16008486faf357873270991 Mon Sep 17 00:00:00 2001 From: Matthew Wahab matthew.wa...@arm.com Date: Thu, 23 Jul 2015 12:44:51 +0100 Subject: [PATCH 1/2] Add fpu feature set definitions. Change-Id: I9f0fcc9627e3c435cbbc9056b9244781b438447e --- gcc/config/arm/arm.h | 13 + 1 file changed, 13 insertions(+) diff --git a/gcc/config/arm/arm.h b/gcc/config/arm/arm.h index bb64be0..f49eb48 100644 --- a/gcc/config/arm/arm.h +++ b/gcc/config/arm/arm.h @@ -318,6 +318,19 @@ extern void (*arm_lang_output_object_attributes_hook)(void); {mode, %{!marm:%{!mthumb:-m%(VALUE)}}}, \ {tls, %{!mtls-dialect=*:-mtls-dialect=%(VALUE)}}, +/* FPU feature sets. */ + +typedef unsigned long arm_fpu_feature_set; + +/* Test for an FPU feature. */ +#define ARM_FPU_FSET_HAS(S,F) (((S) (F)) == (F)) + +/* FPU Features. */ +#define FPU_FL_NONE (0) +#define FPU_FL_NEON (1 0)/* NEON instructions. */ +#define FPU_FL_FP16 (1 1)/* Half-precision. */ +#define FPU_FL_CRYPTO(1 2)/* Crypto extensions. */ + /* Which floating point model to use. */ enum arm_fp_model { -- 1.9.1
Re: [PATCH 1/2][ARM] Record FPU features as a bit-set
Ping. Updated patch attached. Also, retested the series for arm-none-linux-gnueabihf with native bootstrap and make check. On 22/06/15 16:16, Matthew Wahab wrote: Hello, The ARM backend records FPU features as booleans, one for each feature. This means that adding support for a new feature involves updating every entry in the list of FPU descriptions in arm-fpus.def. This patch series changes the representation of FPU features to use a simple bit-set and flags, as is done elsewhere. This patch adds the new FPU feature representation, with feature sets represented as unsigned longs. Tested the series for arm-none-linux-gnueabihf with check-gcc Ok for trunk? Matthew gcc/ 2015-06-22 Matthew Wahab matthew.wa...@arm.com * config/arm/arm.h (arm_fpu_fset): New. (ARM_FPU_FSET_HAS): New. (FPU_FL_NONE): New. (FPU_FL_NEON): New. (FPU_FL_FP16): New. (FPU_FL_CRYPTO): New. From 571416d9e7bc9cb6c16008486faf357873270991 Mon Sep 17 00:00:00 2001 From: Matthew Wahab matthew.wa...@arm.com Date: Thu, 23 Jul 2015 12:44:51 +0100 Subject: [PATCH 1/2] Add fpu feature set definitions. Change-Id: I9f0fcc9627e3c435cbbc9056b9244781b438447e --- gcc/config/arm/arm.h | 13 + 1 file changed, 13 insertions(+) diff --git a/gcc/config/arm/arm.h b/gcc/config/arm/arm.h index bb64be0..f49eb48 100644 --- a/gcc/config/arm/arm.h +++ b/gcc/config/arm/arm.h @@ -318,6 +318,19 @@ extern void (*arm_lang_output_object_attributes_hook)(void); {mode, %{!marm:%{!mthumb:-m%(VALUE)}}}, \ {tls, %{!mtls-dialect=*:-mtls-dialect=%(VALUE)}}, +/* FPU feature sets. */ + +typedef unsigned long arm_fpu_feature_set; + +/* Test for an FPU feature. */ +#define ARM_FPU_FSET_HAS(S,F) (((S) (F)) == (F)) + +/* FPU Features. */ +#define FPU_FL_NONE (0) +#define FPU_FL_NEON (1 0) /* NEON instructions. */ +#define FPU_FL_FP16 (1 1) /* Half-precision. */ +#define FPU_FL_CRYPTO (1 2) /* Crypto extensions. */ + /* Which floating point model to use. */ enum arm_fp_model { -- 1.9.1
Re: [PATCH 1/2][ARM] Record FPU features as a bit-set
Hi Matthew, On 10/08/15 11:28, Matthew Wahab wrote: Ping. Updated patch attached. Also, retested the series for arm-none-linux-gnueabihf with native bootstrap and make check. On 22/06/15 16:16, Matthew Wahab wrote: Hello, The ARM backend records FPU features as booleans, one for each feature. This means that adding support for a new feature involves updating every entry in the list of FPU descriptions in arm-fpus.def. This patch series changes the representation of FPU features to use a simple bit-set and flags, as is done elsewhere. This patch adds the new FPU feature representation, with feature sets represented as unsigned longs. Tested the series for arm-none-linux-gnueabihf with check-gcc Ok for trunk? Matthew gcc/ 2015-06-22 Matthew Wahab matthew.wa...@arm.com * config/arm/arm.h (arm_fpu_fset): New. (ARM_FPU_FSET_HAS): New. (FPU_FL_NONE): New. (FPU_FL_NEON): New. (FPU_FL_FP16): New. (FPU_FL_CRYPTO): New. This is ok. Thanks, Kyrill
[PATCH 1/2][ARM] Record FPU features as a bit-set
Hello, The ARM backend records FPU features as booleans, one for each feature. This means that adding support for a new feature involves updating every entry in the list of FPU descriptions in arm-fpus.def. This patch series changes the representation of FPU features to use a simple bit-set and flags, as is done elsewhere. This patch adds the new FPU feature representation, with feature sets represented as unsigned longs. Tested the series for arm-none-linux-gnueabihf with check-gcc Ok for trunk? Matthew gcc/ 2015-06-22 Matthew Wahab matthew.wa...@arm.com * config/arm/arm.h (arm_fpu_fset): New. (ARM_FPU_FSET_HAS): New. (FPU_FL_NONE): New. (FPU_FL_NEON): New. (FPU_FL_FP16): New. (FPU_FL_CRYPTO): New. From 0ae697751afd9420ece15432e4892a60574b1d56 Mon Sep 17 00:00:00 2001 From: Matthew Wahab matthew.wa...@arm.com Date: Wed, 10 Jun 2015 09:57:55 +0100 Subject: [PATCH 1/2] Add fpu feature set definitions. Change-Id: I9614d12b19f068ae2e0cebc1a6c3903972c73d6a --- gcc/config/arm/arm.h | 13 + 1 file changed, 13 insertions(+) diff --git a/gcc/config/arm/arm.h b/gcc/config/arm/arm.h index 373dc85..eadbcec 100644 --- a/gcc/config/arm/arm.h +++ b/gcc/config/arm/arm.h @@ -318,6 +318,19 @@ extern void (*arm_lang_output_object_attributes_hook)(void); {mode, %{!marm:%{!mthumb:-m%(VALUE)}}}, \ {tls, %{!mtls-dialect=*:-mtls-dialect=%(VALUE)}}, +/* FPU feature sets. */ + +typedef unsigned long arm_fpu_fset; + +/* Test for an FPU feature. */ +#define ARM_FPU_FSET_HAS(S,F) (((S) (F)) == F) + +/* FPU Features. */ +#define FPU_FL_NONE (0) +#define FPU_FL_NEON (1 0) /* NEON instructions. */ +#define FPU_FL_FP16 (1 1) /* Half-precision. */ +#define FPU_FL_CRYPTO (1 2) /* Crypto extensions. */ + /* Which floating point model to use. */ enum arm_fp_model { -- 1.9.1