aboutsummaryrefslogtreecommitdiff
path: root/sim/bfin
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2021-05-02 00:07:21 -0400
committerMike Frysinger <vapier@gentoo.org>2021-05-02 10:58:20 -0400
commitf0c4dc40b2e16a876b5b61986de5014a78f76a5c (patch)
tree081740977f36d35892d79c180e792104293acfe8 /sim/bfin
parentd89a87ba3c100bdbe82c7bd98ad7b8a2435e002f (diff)
downloadfsf-binutils-gdb-f0c4dc40b2e16a876b5b61986de5014a78f76a5c.zip
fsf-binutils-gdb-f0c4dc40b2e16a876b5b61986de5014a78f76a5c.tar.gz
fsf-binutils-gdb-f0c4dc40b2e16a876b5b61986de5014a78f76a5c.tar.bz2
sim: replace custom attributes with ansidecl.h
A lot of this code predates the common attributes. We had already started migrating over piece by piece, so just do a pass across all the attributes and replace most of them.
Diffstat (limited to 'sim/bfin')
-rw-r--r--sim/bfin/ChangeLog8
-rw-r--r--sim/bfin/bfin-sim.c9
2 files changed, 13 insertions, 4 deletions
diff --git a/sim/bfin/ChangeLog b/sim/bfin/ChangeLog
index 4fe2a9d..98d8e66 100644
--- a/sim/bfin/ChangeLog
+++ b/sim/bfin/ChangeLog
@@ -1,3 +1,11 @@
+2021-05-02 Mike Frysinger <vapier@gentoo.org>
+
+ * bfin-sim.c: Include ansidecl.h.
+ (illegal_instruction): Change __attribute__((noreturn)) to
+ ATTRIBUTE_NORETURN.
+ (illegal_instruction_combination, illegal_instruction_or_combination,
+ unhandled_instruction): Likewise.
+
2021-05-01 Mike Frysinger <vapier@gentoo.org>
* dv-bfin_mmu.c (bfin_mmu_options): Mark static.
diff --git a/sim/bfin/bfin-sim.c b/sim/bfin/bfin-sim.c
index 674ae87..33bbc6e 100644
--- a/sim/bfin/bfin-sim.c
+++ b/sim/bfin/bfin-sim.c
@@ -25,6 +25,7 @@
#include <string.h>
#include <inttypes.h>
+#include "ansidecl.h"
#include "opcode/bfin.h"
#include "sim-main.h"
#include "dv-bfin_cec.h"
@@ -35,7 +36,7 @@
#define SIGNEXTEND(v, n) \
(((bs32)(v) << (HOST_LONG_WORD_SIZE - (n))) >> (HOST_LONG_WORD_SIZE - (n)))
-static __attribute__ ((noreturn)) void
+static ATTRIBUTE_NORETURN void
illegal_instruction (SIM_CPU *cpu)
{
TRACE_INSN (cpu, "ILLEGAL INSTRUCTION");
@@ -43,7 +44,7 @@ illegal_instruction (SIM_CPU *cpu)
cec_exception (cpu, VEC_UNDEF_I);
}
-static __attribute__ ((noreturn)) void
+static ATTRIBUTE_NORETURN void
illegal_instruction_combination (SIM_CPU *cpu)
{
TRACE_INSN (cpu, "ILLEGAL INSTRUCTION COMBINATION");
@@ -51,7 +52,7 @@ illegal_instruction_combination (SIM_CPU *cpu)
cec_exception (cpu, VEC_ILGAL_I);
}
-static __attribute__ ((noreturn)) void
+static ATTRIBUTE_NORETURN void
illegal_instruction_or_combination (SIM_CPU *cpu)
{
if (PARALLEL_GROUP != BFIN_PARALLEL_NONE)
@@ -60,7 +61,7 @@ illegal_instruction_or_combination (SIM_CPU *cpu)
illegal_instruction (cpu);
}
-static __attribute__ ((noreturn)) void
+static ATTRIBUTE_NORETURN void
unhandled_instruction (SIM_CPU *cpu, const char *insn)
{
SIM_DESC sd = CPU_STATE (cpu);