aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorJohn Gilmore <gnu@cygnus>1991-09-13 07:22:50 +0000
committerJohn Gilmore <gnu@cygnus>1991-09-13 07:22:50 +0000
commit841c051c44d5423640f593615404820013750402 (patch)
treea8546ad4e6230281c17353116ec9f042c2ecd2f6 /gdb
parent* exec.c (exec_command): If NEED_TEXT_START_END, define the (diff)
downloadbinutils-gdb-841c051c44d5423640f593615404820013750402.tar.gz
binutils-gdb-841c051c44d5423640f593615404820013750402.tar.bz2
binutils-gdb-841c051c44d5423640f593615404820013750402.zip
* inferior.h: Eliminate CANNOT_EXECUTE_STACK in favor of
defining CALL_DUMMY_LOCATION as BEFORE_TEXT_END. This is because machines that do this will also have to know to set NEED_TEXT_START_END. Besides, it was a redundant way to say the same thing. * tm-29k.h, tm-convex.h, tm-np1.h: Eliminate CANNOT_EXECUTE_STACK, define CALL_DUMMY_LOCATION and NEED_TEXT_START_END.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/inferior.h4
-rw-r--r--gdb/tm-29k.h16
-rw-r--r--gdb/tm-convex.h10
-rw-r--r--gdb/tm-np1.h3
4 files changed, 20 insertions, 13 deletions
diff --git a/gdb/inferior.h b/gdb/inferior.h
index 151c2c2b25c..eed848ceffa 100644
--- a/gdb/inferior.h
+++ b/gdb/inferior.h
@@ -187,11 +187,7 @@ int attach_flag;
#define AFTER_TEXT_END 3
#if !defined (CALL_DUMMY_LOCATION)
-#if defined (CANNOT_EXECUTE_STACK)
-#define CALL_DUMMY_LOCATION BEFORE_TEXT_END
-#else /* Can execute stack. */
#define CALL_DUMMY_LOCATION ON_STACK
-#endif /* Can execute stack. */
#endif /* No CALL_DUMMY_LOCATION. */
/* Are we in a call dummy? The code below which allows DECR_PC_AFTER_BREAK
diff --git a/gdb/tm-29k.h b/gdb/tm-29k.h
index fceeb88c420..5330a23d0a2 100644
--- a/gdb/tm-29k.h
+++ b/gdb/tm-29k.h
@@ -344,10 +344,10 @@ CORE_ADDR skip_prologue ();
macros, it doesn't really matter exactly how we
do it. However, note that FRAME_FP is used in two ways in GDB:
(1) as a "magic cookie" which uniquely identifies frames (even over
- calls to the inferior), (2) (in PC_IN_CALL_DUMMY [!CANNOT_EXECUTE_STACK])
+ calls to the inferior), (2) (in PC_IN_CALL_DUMMY [ON_STACK])
as the value of SP_REGNUM before the dummy frame was pushed. These
- two meanings would be incompatible for the 29k if we didn't define
- CANNOT_EXECUTE_STACK (but we do, so don't worry about it).
+ two meanings would be incompatible for the 29k if we defined
+ CALL_DUMMY_LOCATION == ON_STACK (but we don't, so don't worry about it).
Also note that "lr1" below, while called a frame pointer
in the user's guide, has only one function: To determine whether
registers need to be filled in the function epilogue.
@@ -645,12 +645,18 @@ extern void pop_frame ();
STUFF_I16((char *)dummyname + CONST_INSN + 4, fun >> 16);\
}
-/* At least our 29k board has separate data & instruction memories and can't
- execute the data memory. Also, there should be space after text_end;
+/* 29k architecture has separate data & instruction memories -- wired to
+ different pins on the chip -- and can't execute the data memory.
+ Also, there should be space after text_end;
we won't get a SIGSEGV or scribble on data space. */
#define CALL_DUMMY_LOCATION AFTER_TEXT_END
+/* Because of this, we need (as a kludge) to know the addresses of the
+ text section. */
+
+#define NEED_TEXT_START_END
+
/* How to translate register numbers in the .stab's into gdb's internal register
numbers. We don't translate them, but we warn if an invalid register
number is seen. Note that FIXME, we use the value "sym" as an implicit
diff --git a/gdb/tm-convex.h b/gdb/tm-convex.h
index 405dc800ce5..be981b7aa91 100644
--- a/gdb/tm-convex.h
+++ b/gdb/tm-convex.h
@@ -302,9 +302,6 @@ extern struct value *value_of_trapped_internalvar ();
/* Pcc occaisionally puts an SO where there should be an SOL. */
#define PCC_SOL_BROKEN
-
-/* Cannot execute with pc on the stack. */
-#define CANNOT_EXECUTE_STACK
/* Describe the pointer in each stack frame to the previous stack frame
(its caller). */
@@ -330,6 +327,11 @@ extern struct value *value_of_trapped_internalvar ();
/* Define other aspects of the stack frame. */
+/* We need the boundaries of the text in the exec file, as a kludge,
+ for FRAMELESS_FUNCTION_INVOCATION and CALL_DUMMY_LOCATION. */
+
+#define NEED_TEXT_START_END
+
/* A macro that tells us whether the function invocation represented
by FI does not have a frame on the stack associated with it. If it
does not, FRAMELESS is set to 1, else 0.
@@ -451,6 +453,8 @@ extern struct value *value_of_trapped_internalvar ();
/* Things needed for making the inferior call functions. */
+#define CALL_DUMMY_LOCATION BEFORE_TEXT_END
+
/* Push an empty stack frame, to record the current PC, etc. */
#define PUSH_DUMMY_FRAME \
diff --git a/gdb/tm-np1.h b/gdb/tm-np1.h
index 39ff57d9902..78aebb006ac 100644
--- a/gdb/tm-np1.h
+++ b/gdb/tm-np1.h
@@ -387,7 +387,8 @@ extern struct type *builtin_type_np1_vector;
/* Things needed for making the inferior call functions. */
-#define CANNOT_EXECUTE_STACK
+#define CALL_DUMMY_LOCATION BEFORE_TEXT_END
+#define NEED_TEXT_START_END
/* Push an empty stack frame, to record the current PC, etc. */