dw2-op-stack-value.S 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. /* This testcase is part of GDB, the GNU debugger.
  2. Copyright 2011-2022 Free Software Foundation, Inc.
  3. This program is free software; you can redistribute it and/or modify
  4. it under the terms of the GNU General Public License as published by
  5. the Free Software Foundation; either version 3 of the License, or
  6. (at your option) any later version.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  10. GNU General Public License for more details.
  11. You should have received a copy of the GNU General Public License
  12. along with this program. If not, see <http://www.gnu.org/licenses/>. */
  13. .section .data
  14. aa551234: .byte 0xaa, 0x55, 0x12, 0x34
  15. .section .debug_info
  16. .Lcu1_begin:
  17. /* CU header */
  18. .4byte .Lcu1_end - .Lcu1_start /* Length of Compilation Unit */
  19. .Lcu1_start:
  20. .2byte 2 /* DWARF Version */
  21. .4byte .Labbrev1_begin /* Offset into abbrev section */
  22. .byte 4 /* Pointer size */
  23. /* CU die */
  24. .uleb128 1 /* Abbrev: DW_TAG_compile_unit */
  25. .ascii "file1.txt\0" /* DW_AT_name */
  26. .ascii "GNU C 3.3.3\0" /* DW_AT_producer */
  27. .byte 2 /* DW_LANG_C (C) */
  28. .L2byte_type:
  29. .uleb128 2 /* Abbrev: DW_TAG_base_type */
  30. .ascii "2byte\0" /* DW_AT_name */
  31. .byte 2 /* DW_AT_byte_size */
  32. .byte 7 /* DW_AT_encoding: DW_ATE_unsigned */
  33. .L4byte_type:
  34. .uleb128 2 /* Abbrev: DW_TAG_base_type */
  35. .ascii "4byte\0" /* DW_AT_name */
  36. .byte 4 /* DW_AT_byte_size */
  37. .byte 7 /* DW_AT_encoding: DW_ATE_unsigned */
  38. .L8byte_type:
  39. .uleb128 2 /* Abbrev: DW_TAG_base_type */
  40. .ascii "8byte\0" /* DW_AT_name */
  41. .byte 4 /* DW_AT_byte_size */
  42. .byte 7 /* DW_AT_encoding: DW_ATE_unsigned */
  43. .uleb128 3 /* Abbrev: DW_TAG_variable */
  44. .ascii "stack2\0" /* DW_AT_name */
  45. .4byte .L2byte_type-.Lcu1_begin /* DW_AT_type */
  46. .byte 2f - 1f /* DW_AT_location */
  47. 1: .byte 0x31 /* DW_OP_lit1 */
  48. .byte 0x9f /* DW_OP_stack_value */
  49. 2:
  50. .uleb128 3 /* Abbrev: DW_TAG_variable */
  51. .ascii "stack8\0" /* DW_AT_name */
  52. .4byte .L8byte_type-.Lcu1_begin /* DW_AT_type */
  53. .byte 2f - 1f /* DW_AT_location */
  54. 1: .byte 0x31 /* DW_OP_lit1 */
  55. .byte 0x9f /* DW_OP_stack_value */
  56. 2:
  57. .uleb128 3 /* Abbrev: DW_TAG_variable */
  58. .ascii "implicit4to2\0" /* DW_AT_name */
  59. .4byte .L2byte_type-.Lcu1_begin /* DW_AT_type */
  60. .byte 3f - 1f /* DW_AT_location */
  61. 1: .byte 0x9e /* DW_OP_implicit_value */
  62. .uleb128 3f - 2f
  63. 2: .byte 0x11, 0x22, 0x33, 0x44
  64. 3:
  65. .uleb128 3 /* Abbrev: DW_TAG_variable */
  66. .ascii "implicit4to4\0" /* DW_AT_name */
  67. .4byte .L4byte_type-.Lcu1_begin /* DW_AT_type */
  68. .byte 3f - 1f /* DW_AT_location */
  69. 1: .byte 0x9e /* DW_OP_implicit_value */
  70. .uleb128 3f - 2f
  71. 2: .byte 0x11, 0x22, 0x33, 0x44
  72. 3:
  73. .byte 0 /* End of children of CU */
  74. .Lcu1_end:
  75. /* Abbrev table */
  76. .section .debug_abbrev
  77. .Labbrev1_begin:
  78. .uleb128 1 /* Abbrev code */
  79. .uleb128 0x11 /* DW_TAG_compile_unit */
  80. .byte 1 /* has_children */
  81. .uleb128 0x3 /* DW_AT_name */
  82. .uleb128 0x8 /* DW_FORM_string */
  83. .uleb128 0x25 /* DW_AT_producer */
  84. .uleb128 0x8 /* DW_FORM_string */
  85. .uleb128 0x13 /* DW_AT_language */
  86. .uleb128 0xb /* DW_FORM_data1 */
  87. .byte 0x0 /* Terminator */
  88. .byte 0x0 /* Terminator */
  89. .uleb128 2 /* Abbrev code */
  90. .uleb128 0x24 /* DW_TAG_base_type */
  91. .byte 0 /* has_children */
  92. .uleb128 0x3 /* DW_AT_name */
  93. .uleb128 0x8 /* DW_FORM_string */
  94. .uleb128 0xb /* DW_AT_byte_size */
  95. .uleb128 0xb /* DW_FORM_data1 */
  96. .uleb128 0x3e /* DW_AT_encoding */
  97. .uleb128 0xb /* DW_FORM_data1 */
  98. .byte 0x0 /* Terminator */
  99. .byte 0x0 /* Terminator */
  100. .uleb128 3 /* Abbrev code */
  101. .uleb128 0x34 /* DW_TAG_variable */
  102. .byte 0 /* has_children */
  103. .uleb128 0x3 /* DW_AT_name */
  104. .uleb128 0x8 /* DW_FORM_string */
  105. .uleb128 0x49 /* DW_AT_type */
  106. .uleb128 0x13 /* DW_FORM_ref4 */
  107. .uleb128 0x2 /* DW_AT_location */
  108. .uleb128 0xa /* DW_FORM_block1 */
  109. .byte 0x0 /* Terminator */
  110. .byte 0x0 /* Terminator */
  111. .byte 0x0 /* Terminator */
  112. .byte 0x0 /* Terminator */