[PATCH] D79866: [CUDA][HIP] Do not emit debug info for stub function

2020-05-13 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D79866#2034683 , @yaxunl wrote: > can you try set bp by using file name and line number on the kernel? In regular gdb it is set on the stub. In cuda-gdb the behavior is interesting -- it initially gets set and breaks on the stub,

[PATCH] D79866: [CUDA][HIP] Do not emit debug info for stub function

2020-05-13 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. In D79866#2034460 , @tra wrote: > I do not see the behavior the patch is supposed to fix in CUDA. > If I compile a simple program, host-side debugger does not see the `kernel`, > sees `__device_stub_kernel` and, if the breakpoint

[PATCH] D79866: [CUDA][HIP] Do not emit debug info for stub function

2020-05-13 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. I do not see the behavior the patch is supposed to fix in CUDA. If I compile a simple program, host-side debugger does not see the `kernel`, sees `__device_stub_kernel` and, if the breakpoint is set on `kernel`, it treats it as a yet-to-be-loaded one and does end up breaking

[PATCH] D79866: [CUDA][HIP] Do not emit debug info for stub function

2020-05-13 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. yaxunl added reviewers: tra, rjmccall. Herald added a subscriber: aprantl. Herald added a reviewer: aaron.ballman. The stub function is generated by compiler and its instructions have nothing to do with the kernel source code. Currently clang generates debug info for