C ABI for small tags is incorrect #7142
Labels
bug
Something isn't working
code gen
Generating machine code
intermediate issue
Likely good for someone who has completed a few other issues
llvm
If a tag is small, The c-abi has us pass multiple values in a single register. This really happens with any aggregate.
For example
Task U8 {}
should be passed to the platform in a single register. Roc is always passing it in two registers as if it was a larger type.Read this full thread for real context: https://roc.zulipchat.com/#narrow/stream/395097-compiler-development/topic/tags.20and.20c.20abi
Also this repo and commit should be a relatively small repro: https://github.com/jared-cone/roc-zig/tree/c72f6d79063302f18c9dcd9cc8747d0e7ce97117
The text was updated successfully, but these errors were encountered: