mirror of
https://github.com/Mercury-Language/mercury.git
synced 2026-04-15 17:33:38 +00:00
Remove the --disable-decl-debug configuration option, and all conditional
Estimated hours taken: 0.25 Branches: main Remove the --disable-decl-debug configuration option, and all conditional compilation of the declarative debugging implementation. configure.in: Remove the configuration option. runtime/mercury_conf.h.in: Don't document the configuration macro. runtime/mercury_conf_param.h: Don't calculate the conditional compilation macro. trace/mercury_trace_declarative.c: trace/mercury_trace_declarative.h: trace/mercury_trace_internal.c: trace/mercury_trace_internal.h: Compile the declarative debugging code unconditionally.
This commit is contained in:
11
configure.in
11
configure.in
@@ -2308,17 +2308,6 @@ done
|
||||
AC_SUBST(LIBGRADES)
|
||||
AC_SUBST(LIBGRADE_OPTS)
|
||||
|
||||
#-----------------------------------------------------------------------------#
|
||||
#
|
||||
# Add an option that disables declarative debugging support in the internal
|
||||
# debugger. It is enabled by default.
|
||||
#
|
||||
AC_ARG_ENABLE(decl-debug,
|
||||
[ --disable-decl-debug disable the declarative debugger],
|
||||
mercury_cv_enable_decl_debug="$enableval",mercury_cv_enable_decl_debug=yes)
|
||||
if test "$mercury_cv_enable_decl_debug" = "no"; then
|
||||
AC_DEFINE(MR_DISABLE_DECLARATIVE_DEBUGGER)
|
||||
fi
|
||||
#-----------------------------------------------------------------------------#
|
||||
|
||||
# Determine how many of the r registers (r1, r2, ...) are real registers.
|
||||
|
||||
@@ -388,15 +388,6 @@
|
||||
*/
|
||||
#undef MR_USE_EXTERNAL_DEBUGGER
|
||||
|
||||
/*
|
||||
** MR_DISABLE_DECLARATIVE_DEBUGGER:
|
||||
** Remove declarative debugging support from the internal
|
||||
** debugger, even if it is compatible with the current grade.
|
||||
** Whether the declarative debugger can be used or not is
|
||||
** determined in runtime/mercury_conf_param.h.
|
||||
*/
|
||||
#undef MR_DISABLE_DECLARATIVE_DEBUGGER
|
||||
|
||||
/*
|
||||
** MR_NO_USE_READLINE
|
||||
** Set this if you want to prevent the debugger from using the GNU
|
||||
|
||||
@@ -558,15 +558,6 @@
|
||||
#define MR_MAY_NEED_INITIALIZATION
|
||||
#endif
|
||||
|
||||
/*
|
||||
** MR_USE_DECLARATIVE_DEBUGGER -- include support for declarative
|
||||
** debugging in the internal debugger.
|
||||
*/
|
||||
|
||||
#if defined(MR_CONSERVATIVE_GC) && !defined(MR_DISABLE_DECLARATIVE_DEBUGGER)
|
||||
#define MR_USE_DECLARATIVE_DEBUGGER
|
||||
#endif
|
||||
|
||||
/*---------------------------------------------------------------------------*/
|
||||
|
||||
/*
|
||||
|
||||
@@ -30,8 +30,6 @@
|
||||
#include "mercury_imp.h"
|
||||
#include "mercury_trace_declarative.h"
|
||||
|
||||
#ifdef MR_USE_DECLARATIVE_DEBUGGER
|
||||
|
||||
#include "mercury_trace.h"
|
||||
#include "mercury_trace_browse.h"
|
||||
#include "mercury_trace_internal.h"
|
||||
@@ -1516,5 +1514,3 @@ MR_decl_checkpoint_loc(const char *str, MR_Trace_Node node)
|
||||
}
|
||||
|
||||
#endif /* MR_DEBUG_DD_BACK_END */
|
||||
|
||||
#endif /* defined(MR_USE_DECLARATIVE_DEBUGGER) */
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
** Copyright (C) 1998-2001 The University of Melbourne.
|
||||
** Copyright (C) 1998-2002 The University of Melbourne.
|
||||
** This file may only be copied under the terms of the GNU Library General
|
||||
** Public License - see the file COPYING.LIB in the Mercury distribution.
|
||||
*/
|
||||
@@ -11,8 +11,6 @@
|
||||
#include "mercury_trace.h"
|
||||
#include "mercury_trace_internal.h"
|
||||
|
||||
#ifdef MR_USE_DECLARATIVE_DEBUGGER
|
||||
|
||||
/*
|
||||
** When in declarative debugging mode, the internal debugger calls
|
||||
** MR_trace_decl_debug for each event.
|
||||
@@ -45,5 +43,4 @@ typedef MR_Word MR_Trace_Node;
|
||||
#define MR_TRACE_STATUS_FAILED (MR_Word) 1
|
||||
#define MR_TRACE_STATUS_UNDECIDED (MR_Word) 2
|
||||
|
||||
#endif /* MR_USE_DECLARATIVE_DEBUGGER */
|
||||
#endif /* MERCURY_TRACE_DECLARATIVE_H */
|
||||
|
||||
@@ -206,12 +206,8 @@ static const char *MR_scope_report_msg[] = {
|
||||
"MDB INTERNAL ERROR: scope set to MR_SPY_LINENO",
|
||||
};
|
||||
|
||||
#ifdef MR_USE_DECLARATIVE_DEBUGGER
|
||||
|
||||
MR_Trace_Mode MR_trace_decl_mode = MR_TRACE_INTERACTIVE;
|
||||
|
||||
#endif /* MR_USE_DECLARATIVE_DEBUGGER */
|
||||
|
||||
typedef enum {
|
||||
MR_MULTIMATCH_ASK, MR_MULTIMATCH_ALL, MR_MULTIMATCH_ONE
|
||||
} MR_MultiMatch;
|
||||
@@ -447,14 +443,12 @@ static MR_Next MR_trace_cmd_quit(char **words, int word_count,
|
||||
MR_Trace_Cmd_Info *cmd, MR_Event_Info *event_info,
|
||||
MR_Event_Details *event_details, MR_Code **jumpaddr);
|
||||
|
||||
#ifdef MR_USE_DECLARATIVE_DEBUGGER
|
||||
static MR_Next MR_trace_cmd_dd(char **words, int word_count,
|
||||
MR_Trace_Cmd_Info *cmd, MR_Event_Info *event_info,
|
||||
MR_Event_Details *event_details, MR_Code **jumpaddr);
|
||||
static MR_Next MR_trace_cmd_dd_dd(char **words, int word_count,
|
||||
MR_Trace_Cmd_Info *cmd, MR_Event_Info *event_info,
|
||||
MR_Event_Details *event_details, MR_Code **jumpaddr);
|
||||
#endif /* MR_USE_DECLARATIVE_DEBUGGER */
|
||||
|
||||
static void MR_maybe_print_spy_point(int slot, const char *problem);
|
||||
static void MR_print_unsigned_var(FILE *fp, const char *var,
|
||||
@@ -555,11 +549,9 @@ MR_trace_event_internal(MR_Trace_Cmd_Info *cmd, MR_bool interactive,
|
||||
return MR_trace_event_internal_report(cmd, event_info);
|
||||
}
|
||||
|
||||
#ifdef MR_USE_DECLARATIVE_DEBUGGER
|
||||
if (MR_trace_decl_mode != MR_TRACE_INTERACTIVE) {
|
||||
return MR_trace_decl_debug(cmd, event_info);
|
||||
}
|
||||
#endif /* MR_USE_DECLARATIVE_DEBUGGER */
|
||||
|
||||
/*
|
||||
** We want to make sure that the Mercury code used to implement some
|
||||
@@ -3499,8 +3491,6 @@ MR_trace_cmd_quit(char **words, int word_count, MR_Trace_Cmd_Info *cmd,
|
||||
return KEEP_INTERACTING;
|
||||
}
|
||||
|
||||
#ifdef MR_USE_DECLARATIVE_DEBUGGER
|
||||
|
||||
static MR_Next
|
||||
MR_trace_cmd_dd(char **words, int word_count, MR_Trace_Cmd_Info *cmd,
|
||||
MR_Event_Info *event_info, MR_Event_Details *event_details,
|
||||
@@ -3559,8 +3549,6 @@ MR_trace_cmd_dd_dd(char **words, int word_count, MR_Trace_Cmd_Info *cmd,
|
||||
return KEEP_INTERACTING;
|
||||
}
|
||||
|
||||
#endif /* MR_USE_DECLARATIVE_DEBUGGER */
|
||||
|
||||
static void
|
||||
MR_maybe_print_spy_point(int slot, const char *problem)
|
||||
{
|
||||
@@ -5163,12 +5151,10 @@ static const MR_Trace_Command_Info MR_trace_command_infos[] =
|
||||
{ "misc", "quit", MR_trace_cmd_quit,
|
||||
MR_trace_quit_cmd_args, NULL},
|
||||
|
||||
#ifdef MR_USE_DECLARATIVE_DEBUGGER
|
||||
{ "dd", "dd", MR_trace_cmd_dd,
|
||||
NULL, MR_trace_null_completer},
|
||||
{ "dd", "dd_dd", MR_trace_cmd_dd_dd,
|
||||
NULL, MR_trace_filename_completer},
|
||||
#endif
|
||||
|
||||
/* End of doc/mdb_command_list. */
|
||||
{ NULL, "NUMBER", NULL,
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
#ifndef MERCURY_TRACE_INTERNAL_H
|
||||
#define MERCURY_TRACE_INTERNAL_H
|
||||
|
||||
#include "mercury_conf.h" /* for MR_USE_DECLARATIVE_DEBUGGER */
|
||||
#include "mercury_types.h" /* for MR_Code */
|
||||
#include "mercury_trace.h" /* for MR_Event_Info, etc. */
|
||||
#include "mercury_std.h" /* for MR_bool */
|
||||
@@ -15,8 +14,6 @@
|
||||
|
||||
#include <stdio.h> /* for FILE */
|
||||
|
||||
#ifdef MR_USE_DECLARATIVE_DEBUGGER
|
||||
|
||||
/*
|
||||
** The following enum gives the possible modes that the declarative
|
||||
** debugger can be in (see trace/mercury_trace_declarative.{c,h}).
|
||||
@@ -42,8 +39,6 @@ typedef enum {
|
||||
|
||||
extern MR_Trace_Mode MR_trace_decl_mode;
|
||||
|
||||
#endif /* MR_USE_DECLARATIVE_DEBUGGER */
|
||||
|
||||
extern MR_Code *MR_trace_event_internal(MR_Trace_Cmd_Info *cmd,
|
||||
MR_bool interactive, MR_Event_Info *event_info);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user