[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/realgud-lldb 8873745 07/56: Correct location tracking;
From: |
Rocky Bernstein |
Subject: |
[elpa] externals/realgud-lldb 8873745 07/56: Correct location tracking; use native lldb commands |
Date: |
Thu, 23 May 2019 02:11:36 -0400 (EDT) |
branch: externals/realgud-lldb
commit 8873745bf552a3ed0b0f60eac7a76cd1297c3f22
Author: rocky <address@hidden>
Commit: rocky <address@hidden>
Correct location tracking; use native lldb commands
---
lldb/init.el | 54 +++++++++++++++++++++++++++++++++++-------------------
lldb/track-mode.el | 3 ++-
2 files changed, 37 insertions(+), 20 deletions(-)
diff --git a/lldb/init.el b/lldb/init.el
index e894bbd..c50bc5f 100644
--- a/lldb/init.el
+++ b/lldb/init.el
@@ -32,21 +32,37 @@ realgud-loc-pat struct")
(defconst realgud:lldb-frame-file-regexp
(format "\\(.+\\):%s" realgud:regexp-captured-num))
+(defconst realgud:lldb-frame-start-regexp
+ "\\(?:^\\|\n\\)")
+
+(defconst realgud:lldb-frame-num-regexp
+ (format "#%s " realgud:regexp-captured-num))
+
;; Regular expression that describes a lldb location generally shown
;; before a command prompt. NOTE: we assume annotate 1!
;; For example:
-;; /src/build/ruby-2.1.5/main.c:24:454:beg:0x55555557659f
+;; * thread #1: tid = 12866, 0x00000000004004b4 hello`main(argc=1,
argv=0x00007fffffffd668) + 4 at hello.c:5, name = 'hello', stop reason =
breakpoint 1.1
+;; (setf (gethash "loc" realgud:lldb-pat-hash)
+;; (make-realgud-loc-pat
+;; :regexp (format "^\\* thread #%s: .+ at %s, "
+;; realgud:regexp-captured-num
realgud:lldb-frame-file-regexp)
+;; :file-group 2
+;; :line-group 3))
(setf (gethash "loc" realgud:lldb-pat-hash)
(make-realgud-loc-pat
- :regexp (format "^%s:%s:beg:0x\\([0-9a-f]+\\)"
- realgud:lldb-frame-file-regexp
realgud:regexp-captured-num)
- :file-group 1
- :line-group 2
- :char-offset-group 3))
+ :regexp (concat "^" realgud:lldb-frame-start-regexp
+ realgud:lldb-frame-num-regexp
+ "\\(?:.\\|\\(?:[\n] \\)\\)+[ ]+at "
+ realgud:lldb-frame-file-regexp
+ )
+ :num 1
+ :file-group 2
+ :line-group 3)
+ )
;; Regular expression that describes a lldb prompt
;; For example:
-;; (gdb)
+;; (lldb)
(setf (gethash "prompt" realgud:lldb-pat-hash)
(make-realgud-loc-pat
:regexp "^(lldb) "
@@ -54,20 +70,14 @@ realgud-loc-pat struct")
;; Regular expression that describes a "breakpoint set" line
;; For example:
-;; Breakpoint 1, main (argc=1, argv=0x7fffffffdbd8) at main.c:24
+;; Breakpoint 1: where = hello`main + 4 at hello.c:5, address =
0x00000000004004b4
(setf (gethash "brkpt-set" realgud:lldb-pat-hash)
(make-realgud-loc-pat
- :regexp (format "^Breakpoint %s at 0x\\([0-9a-f]*\\): file \\(.+\\),
line %s.\n"
+ :regexp (format "^Breakpoint %s: .* at \\(.+\\):%s, "
realgud:regexp-captured-num realgud:regexp-captured-num)
:num 1
- :file-group 3
- :line-group 4))
-
-(defconst realgud:lldb-frame-start-regexp
- "\\(?:^\\|\n\\)")
-
-(defconst realgud:lldb-frame-num-regexp
- (format "#%s " realgud:regexp-captured-num))
+ :file-group 2
+ :line-group 3))
;; Regular expression that describes a lldb "backtrace" command line.
;; For example:
@@ -107,17 +117,23 @@ realgud-loc-pat struct")
(setf (gethash "lldb" realgud-pat-hash) realgud:lldb-pat-hash)
+;; Prefix used in variable names (e.g. short-key-mode-map) for
+;; this debugger
+(setf (gethash "lldb" realgud:variable-basename-hash) "realgud:lldb")
+
(defvar realgud:lldb-command-hash (make-hash-table :test 'equal)
"Hash key is command name like 'continue' and the value is
the lldb command to use, like 'process continue'")
(setf (gethash "break" realgud:lldb-command-hash) "b %l")
-(setf (gethash "clear" realgud:lldb-command-hash) "clear %l")
+(setf (gethash "delete" realgud:lldb-command-hash) "break delete %p")
+(setf (gethash "clear" realgud:lldb-command-hash) "break clear %X:%l")
(setf (gethash "continue" realgud:lldb-command-hash) "process continue")
(setf (gethash "eval" realgud:lldb-command-hash) "print %s")
+(setf (gethash "finish" realgud:lldb-command-hash) "thread step out")
(setf (gethash "quit" realgud:lldb-command-hash) "quit")
(setf (gethash "run" realgud:lldb-command-hash) "run")
-(setf (gethash "step" realgud:lldb-command-hash) "thread step --count %p")
+(setf (gethash "step" realgud:lldb-command-hash) "thread step-in --count
%p")
(setf (gethash "lldb" realgud-command-hash) realgud:lldb-command-hash)
(setf (gethash "lldb" realgud-pat-hash) realgud:lldb-pat-hash)
diff --git a/lldb/track-mode.el b/lldb/track-mode.el
index 0730a42..050804b 100644
--- a/lldb/track-mode.el
+++ b/lldb/track-mode.el
@@ -1,4 +1,5 @@
;; Copyright (C) 2016 Rocky Bernstein
+;;; track-mode.el ---
;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
@@ -57,7 +58,7 @@ Key bindings:
(realgud:lldb-track-mode-hook)
(realgud:track-mode-enable))
(progn
- (setq realgud-track-mode nil)
+ (setq realgud::lldb-track-mode nil)
))
)
- [elpa] branch externals/realgud-lldb created (now d784d9c), Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 6426b24 05/56: Note that this isn't finished., Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 938fc3c 02/56: Minor fixes, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 28d43e6 03/56: From the outside I think you just require "realgud", Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 90d5673 04/56: All external realgud-... refrences removed as well as load-relative when that's no longer needed, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb e0a2361 08/56: go over command args, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 8873745 07/56: Correct location tracking; use native lldb commands,
Rocky Bernstein <=
- [elpa] externals/realgud-lldb 232841a 12/56: Set top frame number, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 805ef5b 11/56: More lldb loc hacking, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 477fa68 13/56: Markdown INSTALL. Remove require 'cl, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb bc90a4f 30/56: Correct "make install", Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb d1ad104 32/56: remake doc comment correction, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 6025a38 14/56: Some small typos/omissions, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb c8f80dd 15/56: Add check-short filter, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 0f00728 18/56: Merge branch 'master' of github.com:realgud/realgud-lldb, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb 25fa790 36/56: Add until command, Rocky Bernstein, 2019/05/23
- [elpa] externals/realgud-lldb ad6f3a3 21/56: Con't need cl-lib (yet)., Rocky Bernstein, 2019/05/23