You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Architectures-In-Guile.html 12KB

преди 3 години
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <html>
  3. <!-- Copyright (C) 1988-2020 Free Software Foundation, Inc.
  4. Permission is granted to copy, distribute and/or modify this document
  5. under the terms of the GNU Free Documentation License, Version 1.3 or
  6. any later version published by the Free Software Foundation; with the
  7. Invariant Sections being "Free Software" and "Free Software Needs
  8. Free Documentation", with the Front-Cover Texts being "A GNU Manual,"
  9. and with the Back-Cover Texts as in (a) below.
  10. (a) The FSF's Back-Cover Text is: "You are free to copy and modify
  11. this GNU Manual. Buying copies from GNU Press supports the FSF in
  12. developing GNU and promoting software freedom." -->
  13. <!-- Created by GNU Texinfo 6.5, http://www.gnu.org/software/texinfo/ -->
  14. <head>
  15. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  16. <title>Architectures In Guile (Debugging with GDB)</title>
  17. <meta name="description" content="Architectures In Guile (Debugging with GDB)">
  18. <meta name="keywords" content="Architectures In Guile (Debugging with GDB)">
  19. <meta name="resource-type" content="document">
  20. <meta name="distribution" content="global">
  21. <meta name="Generator" content="makeinfo">
  22. <link href="index.html#Top" rel="start" title="Top">
  23. <link href="Concept-Index.html#Concept-Index" rel="index" title="Concept Index">
  24. <link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
  25. <link href="Guile-API.html#Guile-API" rel="up" title="Guile API">
  26. <link href="Disassembly-In-Guile.html#Disassembly-In-Guile" rel="next" title="Disassembly In Guile">
  27. <link href="Lazy-Strings-In-Guile.html#Lazy-Strings-In-Guile" rel="prev" title="Lazy Strings In Guile">
  28. <style type="text/css">
  29. <!--
  30. a.summary-letter {text-decoration: none}
  31. blockquote.indentedblock {margin-right: 0em}
  32. blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
  33. blockquote.smallquotation {font-size: smaller}
  34. div.display {margin-left: 3.2em}
  35. div.example {margin-left: 3.2em}
  36. div.lisp {margin-left: 3.2em}
  37. div.smalldisplay {margin-left: 3.2em}
  38. div.smallexample {margin-left: 3.2em}
  39. div.smalllisp {margin-left: 3.2em}
  40. kbd {font-style: oblique}
  41. pre.display {font-family: inherit}
  42. pre.format {font-family: inherit}
  43. pre.menu-comment {font-family: serif}
  44. pre.menu-preformatted {font-family: serif}
  45. pre.smalldisplay {font-family: inherit; font-size: smaller}
  46. pre.smallexample {font-size: smaller}
  47. pre.smallformat {font-family: inherit; font-size: smaller}
  48. pre.smalllisp {font-size: smaller}
  49. span.nolinebreak {white-space: nowrap}
  50. span.roman {font-family: initial; font-weight: normal}
  51. span.sansserif {font-family: sans-serif; font-weight: normal}
  52. ul.no-bullet {list-style: none}
  53. -->
  54. </style>
  55. </head>
  56. <body lang="en">
  57. <a name="Architectures-In-Guile"></a>
  58. <div class="header">
  59. <p>
  60. Next: <a href="Disassembly-In-Guile.html#Disassembly-In-Guile" accesskey="n" rel="next">Disassembly In Guile</a>, Previous: <a href="Lazy-Strings-In-Guile.html#Lazy-Strings-In-Guile" accesskey="p" rel="prev">Lazy Strings In Guile</a>, Up: <a href="Guile-API.html#Guile-API" accesskey="u" rel="up">Guile API</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Concept-Index.html#Concept-Index" title="Index" rel="index">Index</a>]</p>
  61. </div>
  62. <hr>
  63. <a name="Guile-representation-of-architectures"></a>
  64. <h4 class="subsubsection">23.3.3.21 Guile representation of architectures</h4>
  65. <a name="index-guile-architectures"></a>
  66. <a name="index-_003cgdb_003aarch_003e"></a>
  67. <p><small>GDB</small> uses architecture specific parameters and artifacts in a
  68. number of its various computations. An architecture is represented
  69. by an instance of the <code>&lt;gdb:arch&gt;</code> class.
  70. </p>
  71. <p>The following architecture-related procedures are provided by the
  72. <code>(gdb)</code> module:
  73. </p>
  74. <dl>
  75. <dt><a name="index-arch_003f"></a>Scheme Procedure: <strong>arch?</strong> <em>object</em></dt>
  76. <dd><p>Return <code>#t</code> if <var>object</var> is an object of type <code>&lt;gdb:arch&gt;</code>.
  77. Otherwise return <code>#f</code>.
  78. </p></dd></dl>
  79. <dl>
  80. <dt><a name="index-current_002darch"></a>Scheme Procedure: <strong>current-arch</strong></dt>
  81. <dd><p>Return the current architecture as a <code>&lt;gdb:arch&gt;</code> object.
  82. </p></dd></dl>
  83. <dl>
  84. <dt><a name="index-arch_002dname"></a>Scheme Procedure: <strong>arch-name</strong> <em>arch</em></dt>
  85. <dd><p>Return the name (string value) of <code>&lt;gdb:arch&gt;</code> <var>arch</var>.
  86. </p></dd></dl>
  87. <dl>
  88. <dt><a name="index-arch_002dcharset"></a>Scheme Procedure: <strong>arch-charset</strong> <em>arch</em></dt>
  89. <dd><p>Return name of target character set of <code>&lt;gdb:arch&gt;</code> <var>arch</var>.
  90. </p></dd></dl>
  91. <dl>
  92. <dt><a name="index-arch_002dwide_002dcharset"></a>Scheme Procedure: <strong>arch-wide-charset</strong></dt>
  93. <dd><p>Return name of target wide character set of <code>&lt;gdb:arch&gt;</code> <var>arch</var>.
  94. </p></dd></dl>
  95. <p>Each architecture provides a set of predefined types, obtained by
  96. the following functions.
  97. </p>
  98. <dl>
  99. <dt><a name="index-arch_002dvoid_002dtype"></a>Scheme Procedure: <strong>arch-void-type</strong> <em>arch</em></dt>
  100. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>void</code> type
  101. of architecture <var>arch</var>.
  102. </p></dd></dl>
  103. <dl>
  104. <dt><a name="index-arch_002dchar_002dtype"></a>Scheme Procedure: <strong>arch-char-type</strong> <em>arch</em></dt>
  105. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>char</code> type
  106. of architecture <var>arch</var>.
  107. </p></dd></dl>
  108. <dl>
  109. <dt><a name="index-arch_002dshort_002dtype"></a>Scheme Procedure: <strong>arch-short-type</strong> <em>arch</em></dt>
  110. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>short</code> type
  111. of architecture <var>arch</var>.
  112. </p></dd></dl>
  113. <dl>
  114. <dt><a name="index-arch_002dint_002dtype"></a>Scheme Procedure: <strong>arch-int-type</strong> <em>arch</em></dt>
  115. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>int</code> type
  116. of architecture <var>arch</var>.
  117. </p></dd></dl>
  118. <dl>
  119. <dt><a name="index-arch_002dlong_002dtype"></a>Scheme Procedure: <strong>arch-long-type</strong> <em>arch</em></dt>
  120. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>long</code> type
  121. of architecture <var>arch</var>.
  122. </p></dd></dl>
  123. <dl>
  124. <dt><a name="index-arch_002dschar_002dtype"></a>Scheme Procedure: <strong>arch-schar-type</strong> <em>arch</em></dt>
  125. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>signed char</code> type
  126. of architecture <var>arch</var>.
  127. </p></dd></dl>
  128. <dl>
  129. <dt><a name="index-arch_002duchar_002dtype"></a>Scheme Procedure: <strong>arch-uchar-type</strong> <em>arch</em></dt>
  130. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>unsigned char</code> type
  131. of architecture <var>arch</var>.
  132. </p></dd></dl>
  133. <dl>
  134. <dt><a name="index-arch_002dushort_002dtype"></a>Scheme Procedure: <strong>arch-ushort-type</strong> <em>arch</em></dt>
  135. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>unsigned short</code> type
  136. of architecture <var>arch</var>.
  137. </p></dd></dl>
  138. <dl>
  139. <dt><a name="index-arch_002duint_002dtype"></a>Scheme Procedure: <strong>arch-uint-type</strong> <em>arch</em></dt>
  140. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>unsigned int</code> type
  141. of architecture <var>arch</var>.
  142. </p></dd></dl>
  143. <dl>
  144. <dt><a name="index-arch_002dulong_002dtype"></a>Scheme Procedure: <strong>arch-ulong-type</strong> <em>arch</em></dt>
  145. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>unsigned long</code> type
  146. of architecture <var>arch</var>.
  147. </p></dd></dl>
  148. <dl>
  149. <dt><a name="index-arch_002dfloat_002dtype"></a>Scheme Procedure: <strong>arch-float-type</strong> <em>arch</em></dt>
  150. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>float</code> type
  151. of architecture <var>arch</var>.
  152. </p></dd></dl>
  153. <dl>
  154. <dt><a name="index-arch_002ddouble_002dtype"></a>Scheme Procedure: <strong>arch-double-type</strong> <em>arch</em></dt>
  155. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>double</code> type
  156. of architecture <var>arch</var>.
  157. </p></dd></dl>
  158. <dl>
  159. <dt><a name="index-arch_002dlongdouble_002dtype"></a>Scheme Procedure: <strong>arch-longdouble-type</strong> <em>arch</em></dt>
  160. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>long double</code> type
  161. of architecture <var>arch</var>.
  162. </p></dd></dl>
  163. <dl>
  164. <dt><a name="index-arch_002dbool_002dtype"></a>Scheme Procedure: <strong>arch-bool-type</strong> <em>arch</em></dt>
  165. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>bool</code> type
  166. of architecture <var>arch</var>.
  167. </p></dd></dl>
  168. <dl>
  169. <dt><a name="index-arch_002dlonglong_002dtype"></a>Scheme Procedure: <strong>arch-longlong-type</strong> <em>arch</em></dt>
  170. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>long long</code> type
  171. of architecture <var>arch</var>.
  172. </p></dd></dl>
  173. <dl>
  174. <dt><a name="index-arch_002dulonglong_002dtype"></a>Scheme Procedure: <strong>arch-ulonglong-type</strong> <em>arch</em></dt>
  175. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>unsigned long long</code> type
  176. of architecture <var>arch</var>.
  177. </p></dd></dl>
  178. <dl>
  179. <dt><a name="index-arch_002dint8_002dtype"></a>Scheme Procedure: <strong>arch-int8-type</strong> <em>arch</em></dt>
  180. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>int8</code> type
  181. of architecture <var>arch</var>.
  182. </p></dd></dl>
  183. <dl>
  184. <dt><a name="index-arch_002duint8_002dtype"></a>Scheme Procedure: <strong>arch-uint8-type</strong> <em>arch</em></dt>
  185. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>uint8</code> type
  186. of architecture <var>arch</var>.
  187. </p></dd></dl>
  188. <dl>
  189. <dt><a name="index-arch_002dint16_002dtype"></a>Scheme Procedure: <strong>arch-int16-type</strong> <em>arch</em></dt>
  190. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>int16</code> type
  191. of architecture <var>arch</var>.
  192. </p></dd></dl>
  193. <dl>
  194. <dt><a name="index-arch_002duint16_002dtype"></a>Scheme Procedure: <strong>arch-uint16-type</strong> <em>arch</em></dt>
  195. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>uint16</code> type
  196. of architecture <var>arch</var>.
  197. </p></dd></dl>
  198. <dl>
  199. <dt><a name="index-arch_002dint32_002dtype"></a>Scheme Procedure: <strong>arch-int32-type</strong> <em>arch</em></dt>
  200. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>int32</code> type
  201. of architecture <var>arch</var>.
  202. </p></dd></dl>
  203. <dl>
  204. <dt><a name="index-arch_002duint32_002dtype"></a>Scheme Procedure: <strong>arch-uint32-type</strong> <em>arch</em></dt>
  205. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>uint32</code> type
  206. of architecture <var>arch</var>.
  207. </p></dd></dl>
  208. <dl>
  209. <dt><a name="index-arch_002dint64_002dtype"></a>Scheme Procedure: <strong>arch-int64-type</strong> <em>arch</em></dt>
  210. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for an <code>int64</code> type
  211. of architecture <var>arch</var>.
  212. </p></dd></dl>
  213. <dl>
  214. <dt><a name="index-arch_002duint64_002dtype"></a>Scheme Procedure: <strong>arch-uint64-type</strong> <em>arch</em></dt>
  215. <dd><p>Return the <code>&lt;gdb:type&gt;</code> object for a <code>uint64</code> type
  216. of architecture <var>arch</var>.
  217. </p></dd></dl>
  218. <p>Example:
  219. </p>
  220. <div class="smallexample">
  221. <pre class="smallexample">(gdb) guile (type-name (arch-uchar-type (current-arch)))
  222. &quot;unsigned char&quot;
  223. </pre></div>
  224. <hr>
  225. <div class="header">
  226. <p>
  227. Next: <a href="Disassembly-In-Guile.html#Disassembly-In-Guile" accesskey="n" rel="next">Disassembly In Guile</a>, Previous: <a href="Lazy-Strings-In-Guile.html#Lazy-Strings-In-Guile" accesskey="p" rel="prev">Lazy Strings In Guile</a>, Up: <a href="Guile-API.html#Guile-API" accesskey="u" rel="up">Guile API</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Concept-Index.html#Concept-Index" title="Index" rel="index">Index</a>]</p>
  228. </div>
  229. </body>
  230. </html>