JuliaLang/julia

Choose target ISA in `@code_llvm` and `@code_native`

Open

#52,949 创建于 2024年1月17日

在 GitHub 查看
 (12 评论) (1 反应) (0 负责人)Julia (5,773 fork)batch import
featuregood first issue

仓库指标

Star
 (48,709 star)
PR 合并指标
 (平均合并 20天 6小时) (30 天内合并 157 个 PR)

描述

@vchuravy mentioned on slack that it should be possible to teach @code_llvm and @code_native to generate code for a different ISA (but within same architecture) than the target chosen at startup with -C (native by default), with the only caveat that it'd work only for ISAs that are equal to or smaller than the current one.

A nice use case for this would be to able to choose the target in Compiler Explorer, whose julia backend at the moment only generates code for whatever is the native CPU currently being used.

It'd be nice to have pointers of where one would need to look at, in case they were interested in tackling the issue :slightly_smiling_face:

贡献者指南