Bug 17146 - pre-compile scheme files
Summary: pre-compile scheme files
Status: RESOLVED FIXED
Alias: None
Product: gdb
Classification: Unclassified
Component: guile (show other bugs)
Version: HEAD
: P2 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-12 15:11 UTC by Doug Evans
Modified: 2014-07-28 01:13 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Doug Evans 2014-07-12 15:11:58 UTC
IWBN to precompile the scheme files, at least in part so that when the user starts gdb the first time s/he doesn't see the messages guile prints when compiling files.

tentative patch:
https://sourceware.org/ml/gdb-patches/2014-06/msg00784.html
Comment 1 cvs-commit@gcc.gnu.org 2014-07-27 00:06:48 UTC
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gdb and binutils".

The branch, master has been updated
       via  186fcde0c6134aed28526d925b1360db95d47171 (commit)
      from  4122867a4227d29b46377c2a44eae803a482d89f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=186fcde0c6134aed28526d925b1360db95d47171

commit 186fcde0c6134aed28526d925b1360db95d47171
Author: Doug Evans <xdje42@gmail.com>
Date:   Sat Jul 26 17:01:09 2014 -0700

    PR guile/17146 preparatory work.
    
    	* data-directory/Makefile.in (GUILE_FILES): Add support.scm.
    	* guile/lib/gdb/support.scm: New file.
    	* guile/guile.c (gdbscm_init_module_name): Change to "gdb".
    	* guile/lib/gdb.scm: Load gdb/init.scm as an include file.
    	All uses updated.
    	* guile/lib/gdb/init.scm (SCM_ARG1, SCM_ARG2): Moved to support.scm.
    	All uses updated.
    	(%assert-type): Ditto, and renamed to assert-type.
    	(%exception-print-style): Delete.
    
    	testsuite/
    	* gdb.guile/types-module.exp: Add tests for wrong type arguments.

-----------------------------------------------------------------------

Summary of changes:
 gdb/ChangeLog                               |   14 ++++++++++++++
 gdb/data-directory/Makefile.in              |    1 +
 gdb/guile/guile.c                           |    2 +-
 gdb/guile/lib/gdb.scm                       |    4 ++--
 gdb/guile/lib/gdb/boot.scm                  |    2 +-
 gdb/guile/lib/gdb/experimental.scm          |    3 +--
 gdb/guile/lib/gdb/init.scm                  |   18 +-----------------
 gdb/guile/lib/gdb/iterator.scm              |    5 +++--
 gdb/guile/lib/gdb/printing.scm              |   16 +++++++++-------
 gdb/guile/lib/gdb/{boot.scm => support.scm} |   23 +++++++++++++----------
 gdb/guile/lib/gdb/types.scm                 |   12 ++++++------
 gdb/testsuite/ChangeLog                     |    6 ++++++
 gdb/testsuite/gdb.guile/types-module.exp    |   12 ++++++++++++
 13 files changed, 70 insertions(+), 48 deletions(-)
 copy gdb/guile/lib/gdb/{boot.scm => support.scm} (60%)
Comment 2 cvs-commit@gcc.gnu.org 2014-07-27 01:18:12 UTC
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gdb and binutils".

The branch, master has been updated
       via  e76c5d173bbf7137555919dd136004a7c0118af7 (commit)
      from  186fcde0c6134aed28526d925b1360db95d47171 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=e76c5d173bbf7137555919dd136004a7c0118af7

commit e76c5d173bbf7137555919dd136004a7c0118af7
Author: Doug Evans <xdje42@gmail.com>
Date:   Sat Jul 26 18:16:27 2014 -0700

    PR guile/17146
    
    	* acinclude.m4 (GDB_GUILE_PROGRAM_NAMES): New macro.
    	(GDB_GUILD_TARGET_FLAG, GDB_TRY_GUILD): New macros.
    	* configure.ac: Try to use guild to compile an scm file, if it fails
    	then disable guile support.
    	* configure: Regenerate.
    	* data-directory/Makefile.in (GUILE_SOURCE_FILES): Renamed from
    	GUILE_FILE_LIST.
    	(GUILE_COMPILED_FILES): New variable.
    	(GUILE_FILES) Update.
    	(GUILD, GUILD_TARGET_FLAG, GUILD_COMPILE_FLAGS): New variables.
    	(stamp-guile): Compile scm files.
    	* guile/guile.c (boot_guile_support): New function.
    	(standard_throw_args_p): New function.
    	(print_standard_throw_error, print_throw_error): New functions.
    	(handle_boot_error): New function.
    	(initialize_scheme_side): Rewrite to call boot_guile_support.
    	* guile/lib/gdb/boot.scm: Update %load-compiled-path.  Load gdb.go.
    	* guile/lib/gdb/init.scm (%silence-compiler-warnings%): New function.

-----------------------------------------------------------------------

Summary of changes:
 gdb/ChangeLog                  |   23 +++++++
 gdb/acinclude.m4               |   72 +++++++++++++++++++++++
 gdb/configure                  |   64 ++++++++++++++++++++
 gdb/configure.ac               |   13 ++++
 gdb/data-directory/Makefile.in |   40 +++++++++++--
 gdb/guile/guile.c              |  124 ++++++++++++++++++++++++++++++++++------
 gdb/guile/lib/gdb/boot.scm     |   17 +++++-
 gdb/guile/lib/gdb/init.scm     |    6 ++
 8 files changed, 334 insertions(+), 25 deletions(-)
Comment 3 cvs-commit@gcc.gnu.org 2014-07-27 04:00:06 UTC
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gdb and binutils".

The branch, gdb-7.8-branch has been updated
       via  4024328eedf500adc8508e75d2013d3973e6fb3c (commit)
      from  8550a71c58606a473ab74f4cd3d05c1d3406612c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=4024328eedf500adc8508e75d2013d3973e6fb3c

commit 4024328eedf500adc8508e75d2013d3973e6fb3c
Author: Doug Evans <xdje42@gmail.com>
Date:   Sat Jul 26 20:57:47 2014 -0700

    PR guile/17146 preparatory work.
    
    	* data-directory/Makefile.in (GUILE_FILES): Add support.scm.
    	* guile/lib/gdb/support.scm: New file.
    	* guile/guile.c (gdbscm_init_module_name): Change to "gdb".
    	* guile/lib/gdb.scm: Load gdb/init.scm as an include file.
    	All uses updated.
    	* guile/lib/gdb/init.scm (SCM_ARG1, SCM_ARG2): Moved to support.scm.
    	All uses updated.
    	(%assert-type): Ditto, and renamed to assert-type.
    	(%exception-print-style): Delete.
    
    	testsuite/
    	* gdb.guile/types-module.exp: Add tests for wrong type arguments.

-----------------------------------------------------------------------

Summary of changes:
 gdb/ChangeLog                               |   14 ++++++++++++++
 gdb/data-directory/Makefile.in              |    1 +
 gdb/guile/guile.c                           |    2 +-
 gdb/guile/lib/gdb.scm                       |    4 ++--
 gdb/guile/lib/gdb/boot.scm                  |    2 +-
 gdb/guile/lib/gdb/experimental.scm          |    3 +--
 gdb/guile/lib/gdb/init.scm                  |   18 +-----------------
 gdb/guile/lib/gdb/iterator.scm              |    5 +++--
 gdb/guile/lib/gdb/printing.scm              |   16 +++++++++-------
 gdb/guile/lib/gdb/{boot.scm => support.scm} |   23 +++++++++++++----------
 gdb/guile/lib/gdb/types.scm                 |   12 ++++++------
 gdb/testsuite/ChangeLog                     |    6 ++++++
 gdb/testsuite/gdb.guile/types-module.exp    |   12 ++++++++++++
 13 files changed, 70 insertions(+), 48 deletions(-)
 copy gdb/guile/lib/gdb/{boot.scm => support.scm} (60%)
Comment 4 cvs-commit@gcc.gnu.org 2014-07-27 04:04:37 UTC
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gdb and binutils".

The branch, gdb-7.8-branch has been updated
       via  2dfee787ef47fbf3b100b2dc961edf6ae172422d (commit)
      from  4024328eedf500adc8508e75d2013d3973e6fb3c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=2dfee787ef47fbf3b100b2dc961edf6ae172422d

commit 2dfee787ef47fbf3b100b2dc961edf6ae172422d
Author: Doug Evans <xdje42@gmail.com>
Date:   Sat Jul 26 21:02:39 2014 -0700

    PR guile/17146
    
    	* acinclude.m4 (GDB_GUILE_PROGRAM_NAMES): New macro.
    	(GDB_GUILD_TARGET_FLAG, GDB_TRY_GUILD): New macros.
    	* configure.ac: Try to use guild to compile an scm file, if it fails
    	then disable guile support.
    	* configure: Regenerate.
    	* data-directory/Makefile.in (GUILE_SOURCE_FILES): Renamed from
    	GUILE_FILE_LIST.
    	(GUILE_COMPILED_FILES): New variable.
    	(GUILE_FILES) Update.
    	(GUILD, GUILD_TARGET_FLAG, GUILD_COMPILE_FLAGS): New variables.
    	(stamp-guile): Compile scm files.
    	* guile/guile.c (boot_guile_support): New function.
    	(standard_throw_args_p): New function.
    	(print_standard_throw_error, print_throw_error): New functions.
    	(handle_boot_error): New function.
    	(initialize_scheme_side): Rewrite to call boot_guile_support.
    	* guile/lib/gdb/boot.scm: Update %load-compiled-path.  Load gdb.go.
    	* guile/lib/gdb/init.scm (%silence-compiler-warnings%): New function.

-----------------------------------------------------------------------

Summary of changes:
 gdb/ChangeLog                  |   23 +++++++
 gdb/acinclude.m4               |   72 +++++++++++++++++++++++
 gdb/configure                  |   64 ++++++++++++++++++++
 gdb/configure.ac               |   13 ++++
 gdb/data-directory/Makefile.in |   40 +++++++++++--
 gdb/guile/guile.c              |  124 ++++++++++++++++++++++++++++++++++------
 gdb/guile/lib/gdb/boot.scm     |   17 +++++-
 gdb/guile/lib/gdb/init.scm     |    6 ++
 8 files changed, 334 insertions(+), 25 deletions(-)
Comment 5 Doug Evans 2014-07-28 01:13:25 UTC
patch applied