emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 72067661 1/3: Remove --enablechecking=conslist conf


From: Paul Eggert
Subject: [Emacs-diffs] master 72067661 1/3: Remove --enablechecking=conslist configure option
Date: Mon, 22 Apr 2019 02:16:54 -0400 (EDT)

branch: master
commit 72067661fef9cb9e1a746a7a825053c8204c7a38
Author: Paul Eggert <address@hidden>
Commit: Paul Eggert <address@hidden>

    Remove --enablechecking=conslist configure option
    
    * configure.ac: Remove the option.
    * configure.ac (ac_gc_check_cons_list, GC_CHECK_CONS_LIST):
    * src/alloc.c (check_cons_list) [GC_CHECK_CONS_LIST]:
    * src/lisp.h (lisp_h_check_cons_list, check_cons_list):
    Remove.  All uses removed.
    * etc/NEWS: Mention this.
---
 configure.ac |  9 +--------
 etc/NEWS     |  5 +++++
 src/alloc.c  | 16 ----------------
 src/eval.c   |  9 ---------
 src/lisp.h   | 11 -----------
 5 files changed, 6 insertions(+), 44 deletions(-)

diff --git a/configure.ac b/configure.ac
index b4a9b30..dd88380 100644
--- a/configure.ac
+++ b/configure.ac
@@ -545,7 +545,7 @@ AC_ARG_ENABLE(checking,
                 enable only specific categories of checks.
                 Categories are: all,yes,no.
                 Flags are: stringbytes, stringoverrun, stringfreelist,
-                structs, xmallocoverrun, conslist, glyphs])],
+                structs, xmallocoverrun, glyphs])],
 [ac_checking_flags="${enableval}"],[])
 IFS="${IFS=    }"; ac_save_IFS="$IFS"; IFS="$IFS,"
 CHECK_STRUCTS=false
@@ -560,7 +560,6 @@ do
                        ac_gc_check_string_overrun= ;
                        ac_gc_check_string_free_list= ;
                        ac_xmalloc_overrun= ;
-                       ac_gc_check_cons_list= ;
                        ac_glyphs_debug= ;;
        all)            ac_enable_checking=1 ;
                        CHECK_STRUCTS=true
@@ -568,7 +567,6 @@ do
                        ac_gc_check_string_overrun=1 ;
                        ac_gc_check_string_free_list=1 ;
                        ac_xmalloc_overrun=1 ;
-                       ac_gc_check_cons_list=1 ;
                        ac_glyphs_debug=1 ;;
        # these enable particular checks
        stringbytes)    ac_gc_check_stringbytes=1 ;;
@@ -576,7 +574,6 @@ do
        stringfreelist) ac_gc_check_string_free_list=1 ;;
        structs)        CHECK_STRUCTS=true ;;
        xmallocoverrun) ac_xmalloc_overrun=1 ;;
-       conslist)       ac_gc_check_cons_list=1 ;;
        glyphs)         ac_glyphs_debug=1 ;;
        *)      AC_MSG_ERROR(unknown check category $check) ;;
        esac
@@ -614,10 +611,6 @@ if test x$ac_xmalloc_overrun != x ; then
   AC_DEFINE(XMALLOC_OVERRUN_CHECK, 1,
 [Define this to check for malloc buffer overrun.])
 fi
-if test x$ac_gc_check_cons_list != x ; then
-  AC_DEFINE(GC_CHECK_CONS_LIST, 1,
-[Define this to check for errors in cons list.])
-fi
 if test x$ac_glyphs_debug != x ; then
   AC_DEFINE(GLYPH_DEBUG, 1,
 [Define this to enable glyphs debugging code.])
diff --git a/etc/NEWS b/etc/NEWS
index 4d76143..f991dba 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -89,6 +89,11 @@ Options" in the Emacs manual for more information.
 check that the portable dumper code has been updated to match the last
 change to one of the data structures that it relies on.
 
++++
+** The configure option '--enable-checking=conslist' has been withdrawn.
+It made Emacs irredeemably slow, and is no longer useful with modern
+debugging tools.
+
 ---
 ** Emacs now requires GTK 2.24 and GTK 3.10 for the GTK 2 and GTK 3
 builds respectively.
diff --git a/src/alloc.c b/src/alloc.c
index 186a4c6..d279b6f 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -2801,18 +2801,6 @@ DEFUN ("cons", Fcons, Scons, 2, 2, 0,
   return val;
 }
 
-#ifdef GC_CHECK_CONS_LIST
-/* Get an error now if there's any junk in the cons free list.  */
-void
-check_cons_list (void)
-{
-  struct Lisp_Cons *tail = cons_free_list;
-
-  while (tail)
-    tail = tail->u.s.u.chain;
-}
-#endif
-
 /* Make a list of 1, 2, 3, 4 or 5 specified objects.  */
 
 Lisp_Object
@@ -6003,8 +5991,6 @@ garbage_collect_1 (struct gcstat *gcst)
   /* Record this function, so it appears on the profiler's backtraces.  */
   record_in_backtrace (QAutomatic_GC, 0, 0);
 
-  check_cons_list ();
-
   /* Don't keep undo information around forever.
      Do this early on, so it is no problem if the user quits.  */
   FOR_EACH_BUFFER (nextb)
@@ -6124,8 +6110,6 @@ garbage_collect_1 (struct gcstat *gcst)
 
   unmark_main_thread ();
 
-  check_cons_list ();
-
   gc_in_progress = 0;
 
   unblock_input ();
diff --git a/src/eval.c b/src/eval.c
index a636f6c..4693767 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -2210,8 +2210,6 @@ eval_sub (Lisp_Object form)
       Lisp_Object args_left = original_args;
       ptrdiff_t numargs = list_length (args_left);
 
-      check_cons_list ();
-
       if (numargs < XSUBR (fun)->min_args
          || (XSUBR (fun)->max_args >= 0
              && XSUBR (fun)->max_args < numargs))
@@ -2240,7 +2238,6 @@ eval_sub (Lisp_Object form)
 
          val = XSUBR (fun)->function.aMANY (argnum, vals);
 
-         check_cons_list ();
          lisp_eval_depth--;
          /* Do the debug-on-exit now, while VALS still exists.  */
          if (backtrace_debug_on_exit (specpdl + count))
@@ -2346,7 +2343,6 @@ eval_sub (Lisp_Object form)
       else
        xsignal1 (Qinvalid_function, original_fun);
     }
-  check_cons_list ();
 
   lisp_eval_depth--;
   if (backtrace_debug_on_exit (specpdl + count))
@@ -2786,8 +2782,6 @@ usage: (funcall FUNCTION &rest ARGUMENTS)  */)
   if (debug_on_next_call)
     do_debug_on_call (Qlambda, count);
 
-  check_cons_list ();
-
   original_fun = args[0];
 
  retry:
@@ -2817,13 +2811,11 @@ usage: (funcall FUNCTION &rest ARGUMENTS)  */)
       else if (EQ (funcar, Qautoload))
        {
          Fautoload_do_load (fun, original_fun, Qnil);
-         check_cons_list ();
          goto retry;
        }
       else
        xsignal1 (Qinvalid_function, original_fun);
     }
-  check_cons_list ();
   lisp_eval_depth--;
   if (backtrace_debug_on_exit (specpdl + count))
     val = call_debugger (list2 (Qexit, val));
@@ -2935,7 +2927,6 @@ apply_lambda (Lisp_Object fun, Lisp_Object args, 
ptrdiff_t count)
   set_backtrace_args (specpdl + count, arg_vector, numargs);
   tem = funcall_lambda (fun, numargs, arg_vector);
 
-  check_cons_list ();
   lisp_eval_depth--;
   /* Do the debug-on-exit now, while arg_vector still exists.  */
   if (backtrace_debug_on_exit (specpdl + count))
diff --git a/src/lisp.h b/src/lisp.h
index 2d250fc..d803f16 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -413,9 +413,6 @@ typedef EMACS_INT Lisp_Word;
 #define lisp_h_XCONS(a) \
    (eassert (CONSP (a)), XUNTAG (a, Lisp_Cons, struct Lisp_Cons))
 #define lisp_h_XHASH(a) XUFIXNUM (a)
-#ifndef GC_CHECK_CONS_LIST
-# define lisp_h_check_cons_list() ((void) 0)
-#endif
 #if USE_LSB_TAG
 # define lisp_h_make_fixnum(n) \
     XIL ((EMACS_INT) (((EMACS_UINT) (n) << INTTYPEBITS) + Lisp_Int0))
@@ -459,9 +456,6 @@ typedef EMACS_INT Lisp_Word;
 # define XCDR(c) lisp_h_XCDR (c)
 # define XCONS(a) lisp_h_XCONS (a)
 # define XHASH(a) lisp_h_XHASH (a)
-# ifndef GC_CHECK_CONS_LIST
-#  define check_cons_list() lisp_h_check_cons_list ()
-# endif
 # if USE_LSB_TAG
 #  define make_fixnum(n) lisp_h_make_fixnum (n)
 #  define XFIXNAT(a) lisp_h_XFIXNAT (a)
@@ -3965,11 +3959,6 @@ extern void init_alloc (void);
 extern void syms_of_alloc (void);
 extern struct buffer * allocate_buffer (void);
 extern int valid_lisp_object_p (Lisp_Object);
-#ifdef GC_CHECK_CONS_LIST
-extern void check_cons_list (void);
-#else
-INLINE void (check_cons_list) (void) { lisp_h_check_cons_list (); }
-#endif
 
 /* Defined in gmalloc.c.  */
 #if !defined DOUG_LEA_MALLOC && !defined HYBRID_MALLOC && !defined 
SYSTEM_MALLOC



reply via email to

[Prev in Thread] Current Thread [Next in Thread]