GIMPLE_005fDEBUG.html 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  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-2017 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 "Funding Free Software", the Front-Cover
  8. Texts being (a) (see below), and with the Back-Cover Texts being (b)
  9. (see below). A copy of the license is included in the section entitled
  10. "GNU Free Documentation License".
  11. (a) The FSF's Front-Cover Text is:
  12. A GNU Manual
  13. (b) The FSF's Back-Cover Text is:
  14. You have freedom to copy and modify this GNU Manual, like GNU
  15. software. Copies published by the Free Software Foundation raise
  16. funds for GNU development. -->
  17. <!-- Created by GNU Texinfo 5.2, http://www.gnu.org/software/texinfo/ -->
  18. <head>
  19. <title>GNU Compiler Collection (GCC) Internals: GIMPLE_DEBUG</title>
  20. <meta name="description" content="GNU Compiler Collection (GCC) Internals: GIMPLE_DEBUG">
  21. <meta name="keywords" content="GNU Compiler Collection (GCC) Internals: GIMPLE_DEBUG">
  22. <meta name="resource-type" content="document">
  23. <meta name="distribution" content="global">
  24. <meta name="Generator" content="makeinfo">
  25. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  26. <link href="index.html#Top" rel="start" title="Top">
  27. <link href="Option-Index.html#Option-Index" rel="index" title="Option Index">
  28. <link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
  29. <link href="Tuple-specific-accessors.html#Tuple-specific-accessors" rel="up" title="Tuple specific accessors">
  30. <link href="GIMPLE_005fEH_005fFILTER.html#GIMPLE_005fEH_005fFILTER" rel="next" title="GIMPLE_EH_FILTER">
  31. <link href="GIMPLE_005fCOND.html#GIMPLE_005fCOND" rel="prev" title="GIMPLE_COND">
  32. <style type="text/css">
  33. <!--
  34. a.summary-letter {text-decoration: none}
  35. blockquote.smallquotation {font-size: smaller}
  36. div.display {margin-left: 3.2em}
  37. div.example {margin-left: 3.2em}
  38. div.indentedblock {margin-left: 3.2em}
  39. div.lisp {margin-left: 3.2em}
  40. div.smalldisplay {margin-left: 3.2em}
  41. div.smallexample {margin-left: 3.2em}
  42. div.smallindentedblock {margin-left: 3.2em; font-size: smaller}
  43. div.smalllisp {margin-left: 3.2em}
  44. kbd {font-style:oblique}
  45. pre.display {font-family: inherit}
  46. pre.format {font-family: inherit}
  47. pre.menu-comment {font-family: serif}
  48. pre.menu-preformatted {font-family: serif}
  49. pre.smalldisplay {font-family: inherit; font-size: smaller}
  50. pre.smallexample {font-size: smaller}
  51. pre.smallformat {font-family: inherit; font-size: smaller}
  52. pre.smalllisp {font-size: smaller}
  53. span.nocodebreak {white-space:nowrap}
  54. span.nolinebreak {white-space:nowrap}
  55. span.roman {font-family:serif; font-weight:normal}
  56. span.sansserif {font-family:sans-serif; font-weight:normal}
  57. ul.no-bullet {list-style: none}
  58. -->
  59. </style>
  60. </head>
  61. <body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000">
  62. <a name="GIMPLE_005fDEBUG"></a>
  63. <div class="header">
  64. <p>
  65. Next: <a href="GIMPLE_005fEH_005fFILTER.html#GIMPLE_005fEH_005fFILTER" accesskey="n" rel="next"><code>GIMPLE_EH_FILTER</code></a>, Previous: <a href="GIMPLE_005fCOND.html#GIMPLE_005fCOND" accesskey="p" rel="prev"><code>GIMPLE_COND</code></a>, Up: <a href="Tuple-specific-accessors.html#Tuple-specific-accessors" accesskey="u" rel="up">Tuple specific accessors</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Option-Index.html#Option-Index" title="Index" rel="index">Index</a>]</p>
  66. </div>
  67. <hr>
  68. <a name="GIMPLE_005fDEBUG-1"></a>
  69. <h4 class="subsection">11.8.7 <code>GIMPLE_DEBUG</code></h4>
  70. <a name="index-GIMPLE_005fDEBUG"></a>
  71. <a name="index-GIMPLE_005fDEBUG_005fBIND"></a>
  72. <dl>
  73. <dt><a name="index-_002agimple_005fbuild_005fdebug_005fbind"></a>GIMPLE function: <em>gdebug</em> <strong>*gimple_build_debug_bind</strong> <em>(tree var, tree value, gimple stmt)</em></dt>
  74. <dd><p>Build a <code>GIMPLE_DEBUG</code> statement with <code>GIMPLE_DEBUG_BIND</code> of
  75. <code>subcode</code>. The effect of this statement is to tell debug
  76. information generation machinery that the value of user variable
  77. <code>var</code> is given by <code>value</code> at that point, and to remain with
  78. that value until <code>var</code> runs out of scope, a
  79. dynamically-subsequent debug bind statement overrides the binding, or
  80. conflicting values reach a control flow merge point. Even if
  81. components of the <code>value</code> expression change afterwards, the
  82. variable is supposed to retain the same value, though not necessarily
  83. the same location.
  84. </p>
  85. <p>It is expected that <code>var</code> be most often a tree for automatic user
  86. variables (<code>VAR_DECL</code> or <code>PARM_DECL</code>) that satisfy the
  87. requirements for gimple registers, but it may also be a tree for a
  88. scalarized component of a user variable (<code>ARRAY_REF</code>,
  89. <code>COMPONENT_REF</code>), or a debug temporary (<code>DEBUG_EXPR_DECL</code>).
  90. </p>
  91. <p>As for <code>value</code>, it can be an arbitrary tree expression, but it is
  92. recommended that it be in a suitable form for a gimple assignment
  93. <code>RHS</code>. It is not expected that user variables that could appear
  94. as <code>var</code> ever appear in <code>value</code>, because in the latter we&rsquo;d
  95. have their <code>SSA_NAME</code>s instead, but even if they were not in SSA
  96. form, user variables appearing in <code>value</code> are to be regarded as
  97. part of the executable code space, whereas those in <code>var</code> are to
  98. be regarded as part of the source code space. There is no way to
  99. refer to the value bound to a user variable within a <code>value</code>
  100. expression.
  101. </p>
  102. <p>If <code>value</code> is <code>GIMPLE_DEBUG_BIND_NOVALUE</code>, debug information
  103. generation machinery is informed that the variable <code>var</code> is
  104. unbound, i.e., that its value is indeterminate, which sometimes means
  105. it is really unavailable, and other times that the compiler could not
  106. keep track of it.
  107. </p>
  108. <p>Block and location information for the newly-created stmt are
  109. taken from <code>stmt</code>, if given.
  110. </p></dd></dl>
  111. <dl>
  112. <dt><a name="index-gimple_005fdebug_005fbind_005fget_005fvar"></a>GIMPLE function: <em>tree</em> <strong>gimple_debug_bind_get_var</strong> <em>(gimple stmt)</em></dt>
  113. <dd><p>Return the user variable <var>var</var> that is bound at <code>stmt</code>.
  114. </p></dd></dl>
  115. <dl>
  116. <dt><a name="index-gimple_005fdebug_005fbind_005fget_005fvalue"></a>GIMPLE function: <em>tree</em> <strong>gimple_debug_bind_get_value</strong> <em>(gimple stmt)</em></dt>
  117. <dd><p>Return the value expression that is bound to a user variable at
  118. <code>stmt</code>.
  119. </p></dd></dl>
  120. <dl>
  121. <dt><a name="index-gimple_005fdebug_005fbind_005fget_005fvalue_005fptr"></a>GIMPLE function: <em>tree *</em> <strong>gimple_debug_bind_get_value_ptr</strong> <em>(gimple stmt)</em></dt>
  122. <dd><p>Return a pointer to the value expression that is bound to a user
  123. variable at <code>stmt</code>.
  124. </p></dd></dl>
  125. <dl>
  126. <dt><a name="index-gimple_005fdebug_005fbind_005fset_005fvar"></a>GIMPLE function: <em>void</em> <strong>gimple_debug_bind_set_var</strong> <em>(gimple stmt, tree var)</em></dt>
  127. <dd><p>Modify the user variable bound at <code>stmt</code> to <var>var</var>.
  128. </p></dd></dl>
  129. <dl>
  130. <dt><a name="index-gimple_005fdebug_005fbind_005fset_005fvalue"></a>GIMPLE function: <em>void</em> <strong>gimple_debug_bind_set_value</strong> <em>(gimple stmt, tree var)</em></dt>
  131. <dd><p>Modify the value bound to the user variable bound at <code>stmt</code> to
  132. <var>value</var>.
  133. </p></dd></dl>
  134. <dl>
  135. <dt><a name="index-gimple_005fdebug_005fbind_005freset_005fvalue"></a>GIMPLE function: <em>void</em> <strong>gimple_debug_bind_reset_value</strong> <em>(gimple stmt)</em></dt>
  136. <dd><p>Modify the value bound to the user variable bound at <code>stmt</code> so
  137. that the variable becomes unbound.
  138. </p></dd></dl>
  139. <dl>
  140. <dt><a name="index-gimple_005fdebug_005fbind_005fhas_005fvalue_005fp"></a>GIMPLE function: <em>bool</em> <strong>gimple_debug_bind_has_value_p</strong> <em>(gimple stmt)</em></dt>
  141. <dd><p>Return <code>TRUE</code> if <code>stmt</code> binds a user variable to a value,
  142. and <code>FALSE</code> if it unbinds the variable.
  143. </p></dd></dl>
  144. <hr>
  145. <div class="header">
  146. <p>
  147. Next: <a href="GIMPLE_005fEH_005fFILTER.html#GIMPLE_005fEH_005fFILTER" accesskey="n" rel="next"><code>GIMPLE_EH_FILTER</code></a>, Previous: <a href="GIMPLE_005fCOND.html#GIMPLE_005fCOND" accesskey="p" rel="prev"><code>GIMPLE_COND</code></a>, Up: <a href="Tuple-specific-accessors.html#Tuple-specific-accessors" accesskey="u" rel="up">Tuple specific accessors</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Option-Index.html#Option-Index" title="Index" rel="index">Index</a>]</p>
  148. </div>
  149. </body>
  150. </html>