kparzysz wrote: I looked at the clang code and it's not clear to me why they do it at runtime. Mappers can refer to other mappers (for sub-objects), but all mappers and all type layouts should be present in (or obtainable from) the AST[1]. In other words, clang should be able to emit all the "expanded" map clauses (i.e. after application of the mappers) at compile-time. It's possible that instead of emitting all that code inline, they put it in a runtime function to save code size.
[1] The mapper definition must be visible at the time of use in a clause, so all mappers (recursively) should be visible. https://github.com/llvm/llvm-project/pull/117046 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits