brintos

brintos / llvm-project-archived public Read only

0
0
Text · 7.3 KiB · 088d616 Raw
255 lines · yaml
1# clang -target wasm32 -nostdlib -Wl,--no-entry -Wl,--export-all -O0 -g -o simple.wasm simple.c2# char* str = "data str";3#4# int add(int a, int b) {5#   return a + b;6# }7#8# int main() {9#   int i = 1;10#   int j = 2;11#   return add(i, j);12# }13--- !WASM14FileHeader:15  Version:         0x116Sections:17  - Type:            TYPE18    Signatures:19      - Index:           020        ParamTypes:      []21        ReturnTypes:     []22      - Index:           123        ParamTypes:24          - I3225          - I3226        ReturnTypes:27          - I3228      - Index:           229        ParamTypes:      []30        ReturnTypes:31          - I3232  - Type:            FUNCTION33    FunctionTypes:   [ 0, 1, 2, 1 ]34  - Type:            TABLE35    Tables:36      - Index:           037        ElemType:        FUNCREF38        Limits:39          Flags:           [ HAS_MAX ]40          Minimum:         0x141          Maximum:         0x142  - Type:            MEMORY43    Memories:44      - Minimum:         0x245  - Type:            GLOBAL46    Globals:47      - Index:           048        Type:            I3249        Mutable:         true50        InitExpr:51          Opcode:          I32_CONST52          Value:           6657653      - Index:           154        Type:            I3255        Mutable:         false56        InitExpr:57          Opcode:          I32_CONST58          Value:           103659      - Index:           260        Type:            I3261        Mutable:         false62        InitExpr:63          Opcode:          I32_CONST64          Value:           102465      - Index:           366        Type:            I3267        Mutable:         false68        InitExpr:69          Opcode:          I32_CONST70          Value:           104071      - Index:           472        Type:            I3273        Mutable:         false74        InitExpr:75          Opcode:          I32_CONST76          Value:           104077      - Index:           578        Type:            I3279        Mutable:         false80        InitExpr:81          Opcode:          I32_CONST82          Value:           6657683      - Index:           684        Type:            I3285        Mutable:         false86        InitExpr:87          Opcode:          I32_CONST88          Value:           102489      - Index:           790        Type:            I3291        Mutable:         false92        InitExpr:93          Opcode:          I32_CONST94          Value:           6657695      - Index:           896        Type:            I3297        Mutable:         false98        InitExpr:99          Opcode:          I32_CONST100          Value:           131072101      - Index:           9102        Type:            I32103        Mutable:         false104        InitExpr:105          Opcode:          I32_CONST106          Value:           0107      - Index:           10108        Type:            I32109        Mutable:         false110        InitExpr:111          Opcode:          I32_CONST112          Value:           1113      - Index:           11114        Type:            I32115        Mutable:         false116        InitExpr:117          Opcode:          I32_CONST118          Value:           65536119  - Type:            EXPORT120    Exports:121      - Name:            memory122        Kind:            MEMORY123        Index:           0124      - Name:            __wasm_call_ctors125        Kind:            FUNCTION126        Index:           0127      - Name:            add128        Kind:            FUNCTION129        Index:           1130      - Name:            __original_main131        Kind:            FUNCTION132        Index:           2133      - Name:            main134        Kind:            FUNCTION135        Index:           3136      - Name:            str137        Kind:            GLOBAL138        Index:           1139      - Name:            __main_void140        Kind:            FUNCTION141        Index:           2142      - Name:            __indirect_function_table143        Kind:            TABLE144        Index:           0145      - Name:            __dso_handle146        Kind:            GLOBAL147        Index:           2148      - Name:            __data_end149        Kind:            GLOBAL150        Index:           3151      - Name:            __stack_low152        Kind:            GLOBAL153        Index:           4154      - Name:            __stack_high155        Kind:            GLOBAL156        Index:           5157      - Name:            __global_base158        Kind:            GLOBAL159        Index:           6160      - Name:            __heap_base161        Kind:            GLOBAL162        Index:           7163      - Name:            __heap_end164        Kind:            GLOBAL165        Index:           8166      - Name:            __memory_base167        Kind:            GLOBAL168        Index:           9169      - Name:            __table_base170        Kind:            GLOBAL171        Index:           10172      - Name:            __wasm_first_page_end173        Kind:            GLOBAL174        Index:           11175  - Type:            CODE176    Functions:177      - Index:           0178        Locals:          []179        Body:            0B180      - Index:           1181        Locals:182          - Type:            I32183            Count:           1184        Body:            23808080800041106B21022002200036020C20022001360208200228020C20022802086A0F0B185      - Index:           2186        Locals:187          - Type:            I32188            Count:           2189        Body:            23808080800041106B210020002480808080002000410036020C2000410136020820004102360204200028020820002802041081808080002101200041106A24808080800020010F0B190      - Index:           3191        Locals:          []192        Body:            1082808080000F0B193  - Type:            DATA194    Segments:195      - SectionOffset:   7196        InitFlags:       0197        Offset:198          Opcode:          I32_CONST199          Value:           1024200        Content:         '646174612073747200'201      - SectionOffset:   22202        InitFlags:       0203        Offset:204          Opcode:          I32_CONST205          Value:           1036206        Content:         '00040000'207  - Type:            CUSTOM208    Name:            name209    FunctionNames:210      - Index:           0211        Name:            __wasm_call_ctors212      - Index:           1213        Name:            add214      - Index:           2215        Name:            __original_main216      - Index:           3217        Name:            main218    GlobalNames:219      - Index:           0220        Name:            __stack_pointer221    DataSegmentNames:222      - Index:           0223        Name:            .rodata224      - Index:           1225        Name:            .data226  - Type:            CUSTOM227    HeaderSecSizeEncodingLen: 2228    Name:            producers229    Languages:230      - Name:            C11231        Version:         ''232    Tools:233      - Name:            clang234        Version:         '22.0.0git'235  - Type:            CUSTOM236    Name:            target_features237    Features:238      - Prefix:          USED239        Name:            bulk-memory240      - Prefix:          USED241        Name:            bulk-memory-opt242      - Prefix:          USED243        Name:            call-indirect-overlong244      - Prefix:          USED245        Name:            multivalue246      - Prefix:          USED247        Name:            mutable-globals248      - Prefix:          USED249        Name:            nontrapping-fptoint250      - Prefix:          USED251        Name:            reference-types252      - Prefix:          USED253        Name:            sign-ext254...255