aboutsummaryrefslogtreecommitdiff
path: root/sim/m32r
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2023-12-19 20:13:22 -0500
committerMike Frysinger <vapier@gentoo.org>2023-12-21 20:16:26 -0500
commit6003fe166df2cd80030ae4a228ac105ae13f477e (patch)
tree9d50df58ef62f89ed1f1ad1b9326f10a8c07c333 /sim/m32r
parentc0e97c852595b9516d54688643c08918a446f36c (diff)
downloadgdb-6003fe166df2cd80030ae4a228ac105ae13f477e.zip
gdb-6003fe166df2cd80030ae4a228ac105ae13f477e.tar.gz
gdb-6003fe166df2cd80030ae4a228ac105ae13f477e.tar.bz2
sim: mloop: add #line pragmas everywhere
This will make compiler diagnostics much better with generated code so people can understand the original source file.
Diffstat (limited to 'sim/m32r')
-rw-r--r--sim/m32r/mloop.in4
-rw-r--r--sim/m32r/mloop2.in3
-rw-r--r--sim/m32r/mloopx.in3
3 files changed, 10 insertions, 0 deletions
diff --git a/sim/m32r/mloop.in b/sim/m32r/mloop.in
index 1d4d51b..cec2190 100644
--- a/sim/m32r/mloop.in
+++ b/sim/m32r/mloop.in
@@ -42,6 +42,7 @@ case "x$1" in
xsupport)
cat <<EOF
+#line $LINENO "$0"
#include <stdlib.h>
static INLINE const IDESC *
@@ -157,6 +158,7 @@ xinit)
xextract-simple | xextract-scache)
cat <<EOF
+#line $LINENO "$0"
{
if ((pc & 3) != 0)
{
@@ -199,6 +201,7 @@ xextract-pbb)
# SET_INSN_COUNT(n) must be called to record number of real insns.
cat <<EOF
+#line $LINENO "$0"
{
const IDESC *idesc;
int icount = 0;
@@ -302,6 +305,7 @@ xfull-exec-* | xfast-exec-*)
# vpc is the virtual program counter.
cat <<EOF
+#line $LINENO "$0"
#if (! FAST_P && WITH_SEM_SWITCH_FULL) || (FAST_P && WITH_SEM_SWITCH_FAST)
#define DEFINE_SWITCH
#include "sem-switch.c"
diff --git a/sim/m32r/mloop2.in b/sim/m32r/mloop2.in
index e7982fc..462c8be 100644
--- a/sim/m32r/mloop2.in
+++ b/sim/m32r/mloop2.in
@@ -41,6 +41,7 @@ case "x$1" in
xsupport)
cat <<EOF
+#line $LINENO "$0"
/* Emit insns to write back the results of insns executed in parallel.
SC points to a sufficient number of scache entries for the writeback
@@ -206,6 +207,7 @@ xextract-pbb)
# SET_INSN_COUNT(n) must be called to record number of real insns.
cat <<EOF
+#line $LINENO "$0"
{
const IDESC *idesc;
int icount = 0;
@@ -517,6 +519,7 @@ xfull-exec-pbb)
# vpc is the virtual program counter.
cat <<EOF
+#line $LINENO "$0"
#define DEFINE_SWITCH
#include "sem2-switch.c"
EOF
diff --git a/sim/m32r/mloopx.in b/sim/m32r/mloopx.in
index e601dca..a7371ed 100644
--- a/sim/m32r/mloopx.in
+++ b/sim/m32r/mloopx.in
@@ -41,6 +41,7 @@ case "x$1" in
xsupport)
cat <<EOF
+#line $LINENO "$0"
/* Emit insns to write back the results of insns executed in parallel.
SC points to a sufficient number of scache entries for the writeback
@@ -206,6 +207,7 @@ xextract-pbb)
# SET_INSN_COUNT(n) must be called to record number of real insns.
cat <<EOF
+#line $LINENO "$0"
{
const IDESC *idesc;
int icount = 0;
@@ -517,6 +519,7 @@ xfull-exec-pbb)
# vpc is the virtual program counter.
cat <<EOF
+#line $LINENO "$0"
#define DEFINE_SWITCH
#include "semx-switch.c"
EOF