[Git][cmucl/cmucl][master] 2 commits: Fix #192: Print radix marker in disassemblies; adjust note column
Raymond Toy (@rtoy)
gitlab at common-lisp.net
Sat Apr 29 03:56:10 UTC 2023
Raymond Toy pushed to branch master at cmucl / cmucl
Commits:
784a143b by Raymond Toy at 2023-04-29T03:54:43+00:00
Fix #192: Print radix marker in disassemblies; adjust note column
- - - - -
ce57a9f2 by Raymond Toy at 2023-04-29T03:55:21+00:00
Merge branch 'issue-192-disassemble-prints-radix-marker' into 'master'
Fix #192: Print radix marker in disassemblies; adjust note column
Closes #192
See merge request cmucl/cmucl!143
- - - - -
4 changed files:
- src/code/exports.lisp
- src/code/misc.lisp
- src/compiler/disassem.lisp
- src/i18n/locale/cmucl.pot
Changes:
=====================================
src/code/exports.lisp
=====================================
@@ -1365,7 +1365,9 @@
(:export "*NOTE-COLUMN*" "*OPCODE-COLUMN-WIDTH*" "ADD-COMMENT-HOOK"
"ADD-HOOK" "ADD-NOTE-HOOK" "ARG-VALUE" "CREATE-DSTATE"
"DISASSEM-STATE" "DISASSEMBLE" "DISASSEMBLE-CODE-COMPONENT"
- "DISASSEMBLE-FUNCTION" "DISASSEMBLE-MEMORY" "DISASSEMBLE-SEGMENT"
+ "DISASSEMBLE-FUNCTION" "DISASSEMBLE-MEMORY"
+ "*DISASSEMBLE-PRINT-RADIX*"
+ "DISASSEMBLE-SEGMENT"
"DISASSEMBLE-SEGMENTS" "DSTATE-CODE" "DSTATE-CURPOS"
"DSTATE-GET-PROP" "DSTATE-NEXTPOS" "DSTATE-SEGMENT-LENGTH"
"DSTATE-SEGMENT-SAP" "DSTATE-SEGMENT-START" "FIELD-TYPE"
=====================================
src/code/misc.lisp
=====================================
@@ -181,5 +181,7 @@
"Disassemble the machine code associated with OBJECT, which can be a
function, a lambda expression, or a symbol with a function definition. If
it is not already compiled, the compiler is called to produce something to
- disassemble."
+ disassemble.
+
+ Also see disassem:disassemble for finer control of disassembly."
(disassem:disassemble object))
=====================================
src/compiler/disassem.lisp
=====================================
@@ -102,7 +102,9 @@
"The width of the column in which instruction-names are printed.
NIL means use the default. A value of zero gives the effect of not
aligning the arguments at all.")
-(defvar *note-column* 45
+(defvar *note-column*
+ #-x86 45
+ #+x86 55
"The column in which end-of-line comments for notes are started.")
(defconstant default-opcode-column-width 6)
@@ -3316,12 +3318,16 @@
:format-control (intl:gettext "Can't make a compiled function from ~S")
:format-arguments (list name)))))
+(defvar *disassemble-print-radix*
+ t
+ "Default value for :radix argument for disassem:disassemble")
+
(defun disassemble (object &key (stream *standard-output*)
(use-labels t)
(backend c:*native-backend*)
(base 16)
(case :downcase)
- (radix *print-radix*))
+ (radix *disassemble-print-radix*))
"Disassemble the machine code associated with OBJECT, which can be a
function, a lambda expression, or a symbol with a function definition. If
it is not already compiled, the compiler is called to produce something to
@@ -3336,7 +3342,7 @@
:Radix
The disassembler uses the specified base, case, and radix when
printing the disassembled code. The default values are 16,
- :downcase, and *print-radix*, respectively."
+ :downcase, and *disassemble-print-radix*, respectively."
(declare (type (or function symbol cons) object)
(type (or (member t) stream) stream)
(type (member t nil) use-labels)
=====================================
src/i18n/locale/cmucl.pot
=====================================
@@ -5694,7 +5694,9 @@ msgid ""
"If\n"
" it is not already compiled, the compiler is called to produce something "
"to\n"
-" disassemble."
+" disassemble.\n"
+"\n"
+" Also see disassem:disassemble for finer control of disassembly."
msgstr ""
#: src/code/misc-doc.lisp
@@ -17387,6 +17389,10 @@ msgstr ""
msgid "Can't make a compiled function from ~S"
msgstr ""
+#: src/compiler/disassem.lisp
+msgid "Default value for :radix argument for disassem:disassemble"
+msgstr ""
+
#: src/compiler/disassem.lisp
msgid ""
"Disassemble the machine code associated with OBJECT, which can be a\n"
@@ -17405,7 +17411,7 @@ msgid ""
" :Radix\n"
" The disassembler uses the specified base, case, and radix when\n"
" printing the disassembled code. The default values are 16,\n"
-" :downcase, and *print-radix*, respectively."
+" :downcase, and *disassemble-print-radix*, respectively."
msgstr ""
#: src/compiler/disassem.lisp
View it on GitLab: https://gitlab.common-lisp.net/cmucl/cmucl/-/compare/8826d962b0a76b7b0d1cfd50d1849fddf97f096d...ce57a9f24af8e81244dbaae1172f330b013e4bd2
--
View it on GitLab: https://gitlab.common-lisp.net/cmucl/cmucl/-/compare/8826d962b0a76b7b0d1cfd50d1849fddf97f096d...ce57a9f24af8e81244dbaae1172f330b013e4bd2
You're receiving this email because of your account on gitlab.common-lisp.net.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/cmucl-cvs/attachments/20230429/6ac5703b/attachment-0001.html>
More information about the cmucl-cvs
mailing list