llvm-project/lldb/test/Shell/Symtab/symtab-wasm.test
Jonas Devlieghere 8bd9897815
[lldb] Create sections for Wasm segments (#153634)
This is a continuation of #153494. In a WebAssembly file, the "name"
section contains names for the segments in the data section
(WASM_NAMES_DATA_SEGMENT). We already parse these as symbols, and with
this PR, we now also create sub-sections for each of the segments.
2025-08-19 11:07:49 -07:00

16 lines
1.1 KiB
Plaintext

# RUN: yaml2obj %S/Inputs/simple.wasm.yaml -o %t.wasm
# RUN: %lldb %t.wasm -o 'image dump symtab' -o 'image dump sections' | FileCheck %s
CHECK: Code 0x0000000000000002 0x0000000000000002 0x00000000 __wasm_call_ctors
CHECK: Code 0x0000000000000005 0x0000000000000029 0x00000000 add
CHECK: Code 0x000000000000002f 0x000000000000004c 0x00000000 __original_main
CHECK: Code 0x000000000000007c 0x0000000000000009 0x00000000 main
CHECK: Data 0x0000000000000233 0x0000000000000009 0x00000000 .rodata
CHECK: Data 0x0000000000000242 0x0000000000000004 0x00000000 .data
CHECK: 0x0000000000000001 code {{.*}} 0x000001a1 0x00000085 0x00000000 symtab-wasm.test.tmp.wasm.code
CHECK: 0x0000000000000003 data {{.*}} 0x0000022c 0x0000001a 0x00000000 symtab-wasm.test.tmp.wasm.data
CHECK: 0x0000000000000040 wasm-name {{.*}} 0x00000251 0x00000059 0x00000000 symtab-wasm.test.tmp.wasm.name
CHECK: 0x0000000000000100 data {{.*}} 0x00000233 0x00000009 0x00000000 symtab-wasm.test.tmp.wasm.data..rodata
CHECK: 0x0000000000000200 data {{.*}} 0x00000242 0x00000004 0x00000000 symtab-wasm.test.tmp.wasm.data..data