jhuber6 added a subscriber: tra.
jhuber6 added a comment.

In D128090#3648879 <https://reviews.llvm.org/D128090#3648879>, @saiislam wrote:

> `-Xopenmp-target -march ` used to be the only option to target a specific sub 
> arch before `--offload-arch`. But, it doesn't support multiple archs.
> This patch relies on infra used by `--offload-arch` to support this verbose 
> method of specifying multiple archs.
>
> Use case: people already familiar with `-Xopenmp-target -march` option are 
> likely to use the same for multiple archs, until they learn about shorthand 
> representation, `--offload-arch`.

Overloading the meaning of `-march` might not work here. Typically `-march` is 
just checked via `Args.getLastArg()`, so repeated uses just override the last 
one. I'm not exactly sure what the expected use is however, maybe @tra can help 
there. Although we could consider ones contained inside of `-Xopenmp-target=` 
to be different. That being said, if we wanted to support this I think the 
easiest way to do it would be to add handling for `-march` in the source here 
<https://github.com/llvm/llvm-project/blob/main/clang/lib/Driver/Driver.cpp#L4361>.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D128090/new/

https://reviews.llvm.org/D128090

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to