Re: [PTX] no return fns

2015-12-07 Thread Nathan Sidwell
On 12/07/15 12:42, Bernd Schmidt wrote: On 12/07/2015 06:34 PM, Nathan Sidwell wrote: Aren't noreturn fns required to be void? It certainly doesn't make sense for them to do otherwise. The documentation says "it makes no sense" for them to have a type other than void, but I don't think that

Re: [PTX] no return fns

2015-12-07 Thread Bernd Schmidt
On 12/07/2015 06:34 PM, Nathan Sidwell wrote: Aren't noreturn fns required to be void? It certainly doesn't make sense for them to do otherwise. The documentation says "it makes no sense" for them to have a type other than void, but I don't think that translates into a requirement. I suppos

Re: [PTX] no return fns

2015-12-07 Thread Nathan Sidwell
On 12/07/15 12:08, Alexander Monakov wrote: Hello Nathan, On Mon, 7 Dec 2015, Nathan Sidwell wrote: This patch changes call emission to look for a noreturn note and emit a trap insn after the call. The JIT no longer explodes. I think there's a potential issue with the patch: when the noretu

Re: [PTX] no return fns

2015-12-07 Thread Bernd Schmidt
On 12/07/2015 06:03 PM, Nathan Sidwell wrote: On 12/07/15 11:18, Nathan Sidwell wrote: calls to no return fns can cause problems with the PTX JIT. It doesn't understand their no-return nature and can erroneously think there are unexitable loops (depending on the precise placement of bbs). It c

Re: [PTX] no return fns

2015-12-07 Thread Alexander Monakov
Hello Nathan, On Mon, 7 Dec 2015, Nathan Sidwell wrote: > This patch changes call emission to look for a noreturn note and emit a trap > insn after the call. The JIT no longer explodes. I think there's a potential issue with the patch: when the noreturn function has a non-void return value, you

Re: [PTX] no return fns

2015-12-07 Thread Nathan Sidwell
On 12/07/15 11:18, Nathan Sidwell wrote: calls to no return fns can cause problems with the PTX JIT. It doesn't understand their no-return nature and can erroneously think there are unexitable loops (depending on the precise placement of bbs). It can get so upset it segfaults. gcc.dg/pr68671.c

[PTX] no return fns

2015-12-07 Thread Nathan Sidwell
calls to no return fns can cause problems with the PTX JIT. It doesn't understand their no-return nature and can erroneously think there are unexitable loops (depending on the precise placement of bbs). It can get so upset it segfaults. gcc.dg/pr68671.c started causing this last week, with w