cerl: insert-string

Monk Boy boyofmonk@REDACTED
Fri Oct 25 07:50:17 CEST 2019


It works with change insert-string to insert


My emacs:
memacs@REDACTED:~/workspace/github/otp$ emacs --version
GNU Emacs 26.1
Copyright (C) 2018 Free Software Foundation, Inc.
GNU Emacs comes with ABSOLUTELY NO WARRANTY.
You may redistribute copies of GNU Emacs
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING.


https://github.com/emacs-mirror/emacs/blob/d0e2a341dd9a9a365fd311748df024ecb25b70ec/etc/NEWS.22#L4039

Monk Boy <boyofmonk@REDACTED> 于2019年10月24日周四 下午7:23写道:

> Hi all:
>     I have used cerl to debug beam(./bin/cerl -gdb), Run the debug
> compiled emulator in emacs and gdb.  When I input
>
> ```
>
> For help, type "help".
> Type "apropos word" to search for commands related to "word"...
> Reading symbols from beam.smp...
> (gdb) r
> Starting program:
> /home/memacs/workspace/github/otp/bin/x86_64-unknown-linux-gnu/beam.smp
> [Thread debugging using libthread_db enabled]
> Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
> [New Thread 0x7fffb5e7f700 (LWP 8112)]
> [New Thread 0x7fffb40bf700 (LWP 8113)]
> [New Thread 0x7fffb5ef2700 (LWP 8114)]
> [Detaching after fork from child process 8115]
> [New Thread 0x7fffb36bf700 (LWP 8116)]
> [New Thread 0x7fffb35bc700 (LWP 8117)]
> [New Thread 0x7fffb34b9700 (LWP 8118)]
> [New Thread 0x7fffb317f700 (LWP 8119)]
> [New Thread 0x7fffb307c700 (LWP 8120)]
> [New Thread 0x7fffb2f79700 (LWP 8121)]
> [New Thread 0x7fffb2e76700 (LWP 8122)]
> [New Thread 0x7fffb2d73700 (LWP 8123)]
> [New Thread 0x7fffb2c70700 (LWP 8124)]
> [New Thread 0x7fffb2c1d700 (LWP 8125)]
> [New Thread 0x7fffb2bca700 (LWP 8126)]
> [New Thread 0x7fffb2b77700 (LWP 8127)]
> [New Thread 0x7fffb2b24700 (LWP 8128)]
> [New Thread 0x7fffb2ad1700 (LWP 8129)]
> [New Thread 0x7fffb2a7e700 (LWP 8130)]
> [New Thread 0x7fffb2a2b700 (LWP 8131)]
> [New Thread 0x7fffb29d8700 (LWP 8132)]
> [New Thread 0x7fffb2985700 (LWP 8133)]
> [New Thread 0x7fffb2932700 (LWP 8134)]
> [New Thread 0x7fffb28df700 (LWP 8135)]
> [New Thread 0x7fffb288c700 (LWP 8136)]
> [New Thread 0x7fffb2839700 (LWP 8137)]
> [New Thread 0x7fffb27e6700 (LWP 8138)]
> [New Thread 0x7fffb2793700 (LWP 8139)]
> [New Thread 0x7fffb2740700 (LWP 8140)]
> [New Thread 0x7fffb26ed700 (LWP 8141)]
> [New Thread 0x7fffb269a700 (LWP 8142)]
> [New Thread 0x7fffb2647700 (LWP 8143)]
>
> Thread 11 "7_scheduler" received signal SIG35, Real-time event 35.
> [Switching to Thread 0x7fffb2e76700 (LWP 8122)]
> 0x00007ffff7d14e3f in epoll_wait (epfd=8, events=events@REDACTED=0x7fffb72c8b60,
> maxevents=maxevents@REDACTED=512, timeout=timeout@REDACTED=-1) at
> ../sysdeps/unix/sysv/linux/epoll_wait.c:30
> 30 ../sysdeps/unix/sysv/linux/epoll_wait.c: 没有那个文件或目录.
> (gdb)
> ```
>
> I got:
> ```
> {"init terminating in do_boot",no_or_multiple_root_variables}
> init terminating in do_boot (no_or_multiple_root_variables)
>
> Crash dump is being written to: erl_crash.dump...
> ```
>
>
> I must input:
> (gdb) r -- -root /home/memacs/workspace/github/otp -progname
> /home/memacs/workspace/github/otp/bin/cerl -- -home /home/memacs --
> Starting program:
> /home/memacs/workspace/github/otp/bin/x86_64-unknown-linux-gnu/beam.smp --
> -root /home/memacs/workspace/github/otp -progname
> /home/memacs/workspace/github/otp/bin/cerl -- -home /home/memacs --
> [Thread debugging using libthread_db enabled]
> Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
> [New Thread 0x7fffb5e7f700 (LWP 8508)]
> [New Thread 0x7fffb40bf700 (LWP 8509)]
> [New Thread 0x7fffb5ef2700 (LWP 8510)]
> [Detaching after fork from child process 8511]
> [New Thread 0x7fffb36bf700 (LWP 8512)]
> [New Thread 0x7fffb35bc700 (LWP 8513)]
> [New Thread 0x7fffb34b9700 (LWP 8514)]
> [New Thread 0x7fffb31b6700 (LWP 8515)]
> [New Thread 0x7fffb33b6700 (LWP 8516)]
> [New Thread 0x7fffb2e7f700 (LWP 8517)]
> [New Thread 0x7fffb2d7c700 (LWP 8518)]
> [New Thread 0x7fffb2c79700 (LWP 8519)]
> [New Thread 0x7fffb32b3700 (LWP 8520)]
> [New Thread 0x7fffb3260700 (LWP 8521)]
> [New Thread 0x7fffb320d700 (LWP 8522)]
> [New Thread 0x7fffb2b76700 (LWP 8523)]
> [New Thread 0x7fffb2b23700 (LWP 8524)]
> [New Thread 0x7fffb2ad0700 (LWP 8525)]
> [New Thread 0x7fffb2a7d700 (LWP 8526)]
> [New Thread 0x7fffb2a2a700 (LWP 8527)]
> [New Thread 0x7fffb29d7700 (LWP 8528)]
> [New Thread 0x7fffb2984700 (LWP 8529)]
> [New Thread 0x7fffb2931700 (LWP 8530)]
> [New Thread 0x7fffb28de700 (LWP 8531)]
> [New Thread 0x7fffb288b700 (LWP 8532)]
> [New Thread 0x7fffb2838700 (LWP 8533)]
> [New Thread 0x7fffb27e5700 (LWP 8534)]
> [New Thread 0x7fffb2792700 (LWP 8535)]
> [New Thread 0x7fffb273f700 (LWP 8536)]
> [New Thread 0x7fffb26ec700 (LWP 8537)]
> [New Thread 0x7fffb2699700 (LWP 8538)]
> [New Thread 0x7fffb2646700 (LWP 8539)]
> ```
>
> Last I find the cerl script
> ```
> gdbcmd="(insert-string \"set args $beam_args\") \
>                     (comint-send-input)"
> ```
>
> But emacs has not the function (insert-string xxx)
>   (C-h f)
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20191025/1d224a69/attachment.htm>


More information about the erlang-questions mailing list