Re: [RFC PATCH] Allow limited extended asm at toplevel

2024-10-02 Thread Alexander Monakov
On Wed, 2 Oct 2024, Jakub Jelinek wrote: > Hi! > > In the Cauldron IPA/LTO BoF we've discussed toplevel asms and it was > discussed it would be nice to tell the compiler something about what > the toplevel asm does. Sure, I'm aware the kernel people said they > aren't willing to use something

Re: [RFC PATCH] Allow limited extended asm at toplevel

2024-10-02 Thread Jakub Jelinek
On Wed, Oct 02, 2024 at 01:59:03PM +0200, Richard Biener wrote: > As you are using input constraints to mark symbol uses maybe we can > use output constraints with a magic identifier (and a constraint letter > specifying 'identifier'): > > asm (".globl %0; %0: ret" : "_D" (extern int foo()) : ...)

Re: [RFC PATCH] Allow limited extended asm at toplevel

2024-10-02 Thread Andi Kleen
Jakub Jelinek writes: > And for kernel perhaps we should add some new option which allows > some dumb parsing of the toplevel asms and gather something from that > parsing. See also https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107779 > The restrictions I've implemented are: > 1) asm qualifiers

Re: [RFC PATCH] Allow limited extended asm at toplevel

2024-10-02 Thread Richard Biener
On Wed, 2 Oct 2024, Jakub Jelinek wrote: > Hi! > > In the Cauldron IPA/LTO BoF we've discussed toplevel asms and it was > discussed it would be nice to tell the compiler something about what > the toplevel asm does. Sure, I'm aware the kernel people said they > aren't willing to use something li

Re: [RFC PATCH] Allow limited extended asm at toplevel

2024-10-02 Thread Uros Bizjak
On Wed, Oct 2, 2024 at 1:03 PM Jakub Jelinek wrote: > > Hi! > > In the Cauldron IPA/LTO BoF we've discussed toplevel asms and it was > discussed it would be nice to tell the compiler something about what > the toplevel asm does. Sure, I'm aware the kernel people said they > aren't willing to use

[RFC PATCH] Allow limited extended asm at toplevel

2024-10-02 Thread Jakub Jelinek
Hi! In the Cauldron IPA/LTO BoF we've discussed toplevel asms and it was discussed it would be nice to tell the compiler something about what the toplevel asm does. Sure, I'm aware the kernel people said they aren't willing to use something like that, but perhaps other projects do. And for kerne