diff options
author | Alan Hayward <alan.hayward@arm.com> | 2019-07-19 15:01:11 +0100 |
---|---|---|
committer | Alan Hayward <alan.hayward@arm.com> | 2019-07-19 15:01:11 +0100 |
commit | f29ec966436f98e761f7a2a7183ad8ebab68c2ea (patch) | |
tree | 90b0a56047a91f0a50e378c2c21db2f33f8c3aa6 /gdb/arch/aarch32.c | |
parent | d105cce5dd8d6a5218b044fc161ce89c6b245432 (diff) | |
download | gdb-f29ec966436f98e761f7a2a7183ad8ebab68c2ea.zip gdb-f29ec966436f98e761f7a2a7183ad8ebab68c2ea.tar.gz gdb-f29ec966436f98e761f7a2a7183ad8ebab68c2ea.tar.bz2 |
Arm: Use feature target descriptions
In arm arm_create_target_description and
aarch32_create_target_description create feature based target descriptions
instead of returning the old style descriptions.
Ensure the descriptions are created in exactly the same way as the old xml
files.
Remove the old initialize calls.
gdb/ChangeLog:
* arch/aarch32.c (aarch32_create_target_description): Create
target descriptions using features.
* arch/arm.c (arm_create_target_description)
(arm_create_mprofile_target_description): Likewise.
* arm-tdep.c (_initialize_arm_tdep): Remove tdesc init calls.
Diffstat (limited to 'gdb/arch/aarch32.c')
-rw-r--r-- | gdb/arch/aarch32.c | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/gdb/arch/aarch32.c b/gdb/arch/aarch32.c index 14d6987..1e21d5a 100644 --- a/gdb/arch/aarch32.c +++ b/gdb/arch/aarch32.c @@ -18,12 +18,26 @@ #include "gdbsupport/common-defs.h" #include "aarch32.h" -extern struct target_desc *tdesc_arm_with_neon; +#include "../features/arm/arm-core.c" +#include "../features/arm/arm-vfpv3.c" /* See aarch32.h. */ target_desc * aarch32_create_target_description () { - return tdesc_arm_with_neon; + target_desc *tdesc = allocate_target_description (); + +#ifndef IN_PROCESS_AGENT + set_tdesc_architecture (tdesc, "arm"); +#endif + + long regnum = 0; + + regnum = create_feature_arm_arm_core (tdesc, regnum); + /* Create a vfpv3 feature, then a blank NEON feature. */ + regnum = create_feature_arm_arm_vfpv3 (tdesc, regnum); + tdesc_create_feature (tdesc, "org.gnu.gdb.arm.neon"); + + return tdesc; } |