anza-xyz / move

Move compiler targeting llvm supported backends
https://discord.gg/wFgfjG9J
Apache License 2.0
107 stars 32 forks source link

Extend entrypoint generation to handle multi-module packages #374

Closed dmakarov closed 10 months ago

dmakarov commented 10 months ago

Motivation

Current generation of entrypoint glue code works only for packages with entry functions defined in a single module. These changes move entrypoint glue code generation outside ModuleContext. The glue code is generated in a separate LLVM module, so that it can make calls to entry functions defined in any module of a package.

Test Plan

Added rbpf-tests test with entry functions in different modules.

Resolves #369