[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-06-01 Thread Jessica Clarke via Phabricator via cfe-commits
jrtc27 added a comment. In D149867#4387189 , @glaubitz wrote: > In D149867#4386271 , @jrtc27 wrote: > >> I disagree. Being experimental doesn't mean you should do the wrong thing. >> Reusing stdcall in the

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-06-01 Thread John Paul Adrian Glaubitz via Phabricator via cfe-commits
glaubitz added a comment. In D149867#4386271 , @jrtc27 wrote: > I disagree. Being experimental doesn't mean you should do the wrong thing. > Reusing stdcall in the frontend is ugly, pollutes non-m68k code paths (doing > your own thing _avoids_ that and

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-31 Thread Jessica Clarke via Phabricator via cfe-commits
jrtc27 requested changes to this revision. jrtc27 added a comment. This revision now requires changes to proceed. I disagree. Being experimental doesn't mean you should do the wrong thing. Reusing std call in the frontend is ugly, pollutes non-m68k code paths (doing your own thing _avoids_ that

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-31 Thread Sheng via Phabricator via cfe-commits
0x59616e accepted this revision. 0x59616e added a comment. This revision is now accepted and ready to land. Though creating our own calling convention is better, I think Min's path is correct at this moment given that m68k is still an experimental target. We can reignite this discussion once

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-25 Thread Min-Yih Hsu via Phabricator via cfe-commits
myhsu added a comment. ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149867/new/ https://reviews.llvm.org/D149867 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-08 Thread Min-Yih Hsu via Phabricator via cfe-commits
myhsu added a comment. In D149867#4325040 , @jrtc27 wrote: > So GCC gives me: > > warning: ‘stdcall’ attribute directive ignored [-Wattributes] > > when trying to use `__attribute__((stdcall))` on m68k, which matches the fact > it's only mentioned in

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-07 Thread Jessica Clarke via Phabricator via cfe-commits
jrtc27 added a comment. So GCC gives me: warning: ‘stdcall’ attribute directive ignored [-Wattributes] when trying to use `__attribute__((stdcall))` on m68k, which matches the fact it's only mentioned in the manage for the x86 option. Interestingly it seems to ICE during expand when I use

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-05 Thread Sheng via Phabricator via cfe-commits
0x59616e added a comment. I didn't see any issue here. Let's wait for the approval from other (more senior) reviewers. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149867/new/ https://reviews.llvm.org/D149867 ___ cfe-commits mailing list

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-05 Thread Min-Yih Hsu via Phabricator via cfe-commits
myhsu updated this revision to Diff 519983. myhsu added a comment. Minor updates. NFC. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149867/new/ https://reviews.llvm.org/D149867 Files: clang/lib/Basic/Targets/M68k.cpp clang/lib/Basic/Targets/M68k.h clang/lib/CodeGen/CGCall.cpp

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-05 Thread Min-Yih Hsu via Phabricator via cfe-commits
myhsu updated this revision to Diff 519982. myhsu added a comment. Introduce `m68k_rtdcc` the textual LLVM IR designation for M68k_RTD CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149867/new/ https://reviews.llvm.org/D149867 Files: clang/lib/Basic/Targets/M68k.cpp

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-05 Thread Min-Yih Hsu via Phabricator via cfe-commits
myhsu added inline comments. Comment at: clang/test/CodeGen/mrtd.c:9 +// X86: define{{.*}} x86_stdcallcc void @foo(i32 noundef %arg) [[NUW:#[0-9]+]] +// M68k: define{{.*}} cc104 void @foo(i32 noundef %arg) void foo(int arg) { 0x59616e wrote: > 0x59616e wrote: >

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-04 Thread Sheng via Phabricator via cfe-commits
0x59616e added inline comments. Comment at: clang/test/CodeGen/mrtd.c:9 +// X86: define{{.*}} x86_stdcallcc void @foo(i32 noundef %arg) [[NUW:#[0-9]+]] +// M68k: define{{.*}} cc104 void @foo(i32 noundef %arg) void foo(int arg) { 0x59616e wrote: > Just curious,

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-04 Thread Sheng via Phabricator via cfe-commits
0x59616e added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:559 +emitError |= DefaultCC == LangOptions::DCC_StdCall && + !(Arch == llvm::Triple::m68k || Arch == llvm::Triple::x86); emitError |= (DefaultCC ==

[PATCH] D149867: [M68k] Add Clang support for the new M68k_RTD CC

2023-05-04 Thread Min-Yih Hsu via Phabricator via cfe-commits
myhsu created this revision. myhsu added reviewers: 0x59616e, RKSimon, craig.topper. Herald added a subscriber: pengfei. Herald added a project: All. myhsu requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. We basically piggyback most of