[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-08 Thread Yaxun Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG1d97cb1f6e44: [HIP] Emit amdgpu_code_object_version module flag (authored by yaxunl). Herald added a project: clang. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 406605. yaxunl marked 2 inline comments as done. yaxunl added a comment. fix comments and add a driver test for -cc1as CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119026/new/ https://reviews.llvm.org/D119026 Files: clang/include/clang/Basic/Targ

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked 2 inline comments as done. yaxunl added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:1166 CmdArgs.insert(CmdArgs.begin() + 1, "-mllvm"); +// -cc1as does not need -mcode-object-version option. +if (!IsCC1As) tra wro

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-07 Thread Artem Belevich via Phabricator via cfe-commits
tra accepted this revision. tra added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:1166 CmdArgs.insert(CmdArgs.begin() + 1, "-mllvm"); +// -cc1as does not need -mcode-object-version option. +if (!

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 406536. yaxunl marked 2 inline comments as done. yaxunl added a comment. add a test for -cc1as CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119026/new/ https://reviews.llvm.org/D119026 Files: clang/include/clang/Basic/TargetOptions.h clang/incl

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked 2 inline comments as done. yaxunl added inline comments. Comment at: clang/include/clang/Driver/Options.td:3445 def mcode_object_version_EQ : Joined<["-"], "mcode-object-version=">, Group, - HelpText<"Specify code object ABI version. Defaults to 4. (AMDGPU only)"

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-07 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/include/clang/Driver/Options.td:3445 def mcode_object_version_EQ : Joined<["-"], "mcode-object-version=">, Group, - HelpText<"Specify code object ABI version. Defaults to 4. (AMDGPU only)">, - MetaVarName<"">, Values<"2,3,4,5">; +

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-05 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 406221. yaxunl marked an inline comment as done. yaxunl added a comment. marshalling the arg as enum. fix test failures for -cc1as. temporarily disable it except v5. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119026/new/ https://reviews.llvm.org/

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-05 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked an inline comment as done. yaxunl added inline comments. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:575 +// times 100. +if (getTarget().getTargetOpts().CodeObjectVersion != "none") { + unsigned CodeObjVer; tra wrote: > yaxunl wrote

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-04 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:575 +// times 100. +if (getTarget().getTargetOpts().CodeObjectVersion != "none") { + unsigned CodeObjVer; yaxunl wrote: > tra wrote: > > When will it ever be set to `none`? Do

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-04 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:575 +// times 100. +if (getTarget().getTargetOpts().CodeObjectVersion != "none") { + unsigned CodeObjVer; tra wrote: > When will it ever be set to `none`? Does the new opti

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-04 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:575 +// times 100. +if (getTarget().getTargetOpts().CodeObjectVersion != "none") { + unsigned CodeObjVer; When will it ever be set to `none`? Does the new option parser enforc

[PATCH] D119026: [HIP] Emit amdgpu_code_object_version module flag

2022-02-04 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. yaxunl added reviewers: tra, b-sumner. Herald added subscribers: dang, kerbowa, t-tye, tpr, dstuttard, jvesely, kzhuravl. yaxunl requested review of this revision. Herald added a subscriber: wdng. code object version determines ABI, therefore should not be mixed. Th