empty-bin-64.test 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. # RUN: %yaml2obj %s -o %t.obj
  2. # RUN: %bloaty --raw-map %t.obj | %FileCheck %s
  3. --- !ELF
  4. FileHeader:
  5. Class: ELFCLASS64
  6. Data: ELFDATA2LSB
  7. Type: ET_EXEC
  8. Machine: EM_X86_64
  9. Sections:
  10. - Name: .text
  11. Type: SHT_PROGBITS
  12. Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
  13. AddressAlign: 0x1
  14. - Name: .data
  15. Type: SHT_PROGBITS
  16. Flags: [ SHF_WRITE, SHF_ALLOC ]
  17. AddressAlign: 0x1
  18. - Name: .bss
  19. Type: SHT_NOBITS
  20. Flags: [ SHF_WRITE, SHF_ALLOC ]
  21. AddressAlign: 0x1
  22. - Name: .comment
  23. Type: SHT_PROGBITS
  24. Flags: [ SHF_MERGE, SHF_STRINGS ]
  25. AddressAlign: 0x1
  26. EntSize: 0x1
  27. Content: 004743433A202844656269616E2031302E322E312D362B6275696C6432292031302E322E3120323032313031313000
  28. - Name: .note.GNU-stack
  29. Type: SHT_PROGBITS
  30. AddressAlign: 0x1
  31. Symbols:
  32. - Name: 'null'
  33. Type: STT_FILE
  34. Index: SHN_ABS
  35. - Name: .text
  36. Type: STT_SECTION
  37. Section: .text
  38. - Name: .data
  39. Type: STT_SECTION
  40. Section: .data
  41. - Name: .bss
  42. Type: STT_SECTION
  43. Section: .bss
  44. - Name: .note.GNU-stack
  45. Type: STT_SECTION
  46. Section: .note.GNU-stack
  47. - Name: .comment
  48. Type: STT_SECTION
  49. Section: .comment
  50. ...
  51. # CHECK: FILE MAP:
  52. # CHECK: 000-040 64 [ELF Header]
  53. # CHECK: 040-070 48 .comment
  54. # CHECK: 070-118 168 .symtab
  55. # CHECK: 118-148 48 .strtab
  56. # CHECK: 148-190 72 .shstrtab
  57. # CHECK: 190-3d0 576 [ELF Section Headers]
  58. # CHECK: VM MAP: