# wasm-linker: implement \`\_\_heap_base\` symbol · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/c77ca9174976a9fb8769276ce913e761d66af1de)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: c77ca9174976a9fb8769276ce913e761d66af1de

Requested commit: c77ca9174976a9fb8769276ce913e761d66af1de

Commit: c77ca9174976a9fb8769276ce913e761d66af1de

Tree: 94d02f581f1b8b6f0665aed3282ef4bbcb8c258b

Author: Luuk de Gram

Committer: Luuk de Gram

## Message

```
wasm-linker: implement `__heap_base` symbol

When any object files provides an undefined reference to the __heap_base
symbol, we create a new defined symbol for it. During setupMemory we
set the virtual address of this symbol so it can be used for relocations.
This symbol represents where the heap starts and allocators can use
this value for its allocations when it needs to determine where the heap
lives.

```

## Parents

- [f8d1efd99ab0ff9ae49a17b437814f4fe329e83b](https://git.cafe/gitcafe/zig/commit/f8d1efd99ab0ff9ae49a17b437814f4fe329e83b?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/c77ca9174976a9fb8769276ce913e761d66af1de?format=markdown)
