aboutsummaryrefslogtreecommitdiff
path: root/sim/ppc/std-config.h
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2021-06-15 22:37:38 -0400
committerMike Frysinger <vapier@gentoo.org>2021-06-19 22:41:05 -0400
commit54c47dfb68a5e2cfde5fec7224b0f92b12edc42c (patch)
treee447e1560ec9ace125b4e26dbe16efbd638d9ca8 /sim/ppc/std-config.h
parent36842f65be97ba702ef574af6290bd327df64886 (diff)
downloadgdb-54c47dfb68a5e2cfde5fec7224b0f92b12edc42c.zip
gdb-54c47dfb68a5e2cfde5fec7224b0f92b12edc42c.tar.gz
gdb-54c47dfb68a5e2cfde5fec7224b0f92b12edc42c.tar.bz2
sim: ppc: rename inline defines to match common code
Use the same basic names as the common sim inline logic so we can merge the two. We don't do that here, just prepare for it. The common code seems to be based on the ppc version but with slightly different names as it was cleaned up & generalized. I *think* these concepts are the same, so binding them together is OK, but maybe I'm misreading them. If so, can always tweak them later. REVEAL_MODULE -> H_REVEALS_MODULE INLINE_MODULE -> C_REVEALS_MODULE
Diffstat (limited to 'sim/ppc/std-config.h')
-rw-r--r--sim/ppc/std-config.h33
1 files changed, 16 insertions, 17 deletions
diff --git a/sim/ppc/std-config.h b/sim/ppc/std-config.h
index 7b8f911..75aaa58 100644
--- a/sim/ppc/std-config.h
+++ b/sim/ppc/std-config.h
@@ -309,7 +309,7 @@ extern int current_stdio;
the module is included into a file being compiled, calls to
its funtions can be eliminated. 2 implies 1.
- PSIM_INLINE_LOCALS:
+ INLINE_LOCALS:
Make internal (static) functions within the module `inline'.
@@ -317,7 +317,7 @@ extern int current_stdio;
INCLUDE_MODULE == (REVEAL_MODULE | INLINE_MODULE)
- ALL_INLINE == (REVEAL_MODULE | INLINE_MODULE | PSIM_INLINE_LOCALS)
+ ALL_C_INLINE == (REVEAL_MODULE | INLINE_MODULE | INLINE_LOCALS)
In addition to this, modules have been put into two categories.
@@ -415,11 +415,10 @@ extern int current_stdio;
*/
-#define REVEAL_MODULE 1
-#define INLINE_MODULE 2
+#include "../common/sim-inline.h"
+#define REVEAL_MODULE H_REVEALS_MODULE
+#define INLINE_MODULE C_REVEALS_MODULE
#define INCLUDE_MODULE (INLINE_MODULE | REVEAL_MODULE)
-#define PSIM_INLINE_LOCALS 4
-#define ALL_INLINE 7
/* Your compilers inline reserved word */
@@ -441,7 +440,7 @@ extern int current_stdio;
/* Default macro to simplify control several of key the inlines */
#ifndef DEFAULT_INLINE
-#define DEFAULT_INLINE PSIM_INLINE_LOCALS
+#define DEFAULT_INLINE INLINE_LOCALS
#endif
/* Code that converts between hosts and target byte order. Used on
@@ -450,21 +449,21 @@ extern int current_stdio;
can inline for all callers */
#ifndef SIM_ENDIAN_INLINE
-#define SIM_ENDIAN_INLINE (DEFAULT_INLINE ? ALL_INLINE : 0)
+#define SIM_ENDIAN_INLINE (DEFAULT_INLINE ? ALL_C_INLINE : 0)
#endif
/* Low level bit manipulation routines. This module can inline for all
callers */
#ifndef BITS_INLINE
-#define BITS_INLINE (DEFAULT_INLINE ? ALL_INLINE : 0)
+#define BITS_INLINE (DEFAULT_INLINE ? ALL_C_INLINE : 0)
#endif
/* Code that gives access to various CPU internals such as registers.
Used every time an instruction is executed */
#ifndef CPU_INLINE
-#define CPU_INLINE (DEFAULT_INLINE ? ALL_INLINE : 0)
+#define CPU_INLINE (DEFAULT_INLINE ? ALL_C_INLINE : 0)
#endif
/* Code that translates between an effective and real address. Used
@@ -485,14 +484,14 @@ extern int current_stdio;
Called once per instruction cycle */
#ifndef EVENTS_INLINE
-#define EVENTS_INLINE (DEFAULT_INLINE ? ALL_INLINE : 0)
+#define EVENTS_INLINE (DEFAULT_INLINE ? ALL_C_INLINE : 0)
#endif
/* Code monotoring the processors performance. It counts events on
every instruction cycle */
#ifndef MON_INLINE
-#define MON_INLINE (DEFAULT_INLINE ? ALL_INLINE : 0)
+#define MON_INLINE (DEFAULT_INLINE ? ALL_C_INLINE : 0)
#endif
/* Code called on the rare occasions that an interrupt occures. */
@@ -515,7 +514,7 @@ extern int current_stdio;
a jump table. */
#ifndef DEVICE_INLINE
-#define DEVICE_INLINE (DEFAULT_INLINE ? PSIM_INLINE_LOCALS : 0)
+#define DEVICE_INLINE (DEFAULT_INLINE ? INLINE_LOCALS : 0)
#endif
/* Code called used while the device tree is being built.
@@ -523,7 +522,7 @@ extern int current_stdio;
Inlining this is of no benefit */
#ifndef TREE_INLINE
-#define TREE_INLINE (DEFAULT_INLINE ? PSIM_INLINE_LOCALS : 0)
+#define TREE_INLINE (DEFAULT_INLINE ? INLINE_LOCALS : 0)
#endif
/* Code called whenever information on a Special Purpose Register is
@@ -563,7 +562,7 @@ extern int current_stdio;
code is reduced. */
#ifndef SUPPORT_INLINE
-#define SUPPORT_INLINE PSIM_INLINE_LOCALS
+#define SUPPORT_INLINE INLINE_LOCALS
#endif
/* Model specific code used in simulating functional units. Note, it actaully
@@ -588,13 +587,13 @@ extern int current_stdio;
into this file */
#ifndef IDECOCE_INLINE
-#define IDECODE_INLINE PSIM_INLINE_LOCALS
+#define IDECODE_INLINE INLINE_LOCALS
#endif
/* psim, isn't actually inlined */
#ifndef PSIM_INLINE
-#define PSIM_INLINE PSIM_INLINE_LOCALS
+#define PSIM_INLINE INLINE_LOCALS
#endif
/* Code to emulate os or rom compatibility. This code is called via a