https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87291

--- Comment #3 from David Malcolm <dmalcolm at gcc dot gnu.org> ---
Note to self: GCC's documentation for using asm from C:
  https://gcc.gnu.org/onlinedocs/gcc/Using-Assembly-Language-with-C.html

Thanks for the suggestions.

I'm not seeing how the proposed entrypoints in comment #2 would work; sorry.

I suspect we'd need to closely mirror the "basic" and "extended" asm approaches
from C linked to above (probably using the terms "basic" and "extended" in the
entrypoint names, to signal to the developer that that's what the calls would
be analogous to).

I'm wary about basic asm at the top level (outside functions), given that
libgccjit has such an unusual relationship with the rest of the compiler (it
might work, but it might have unexpected snags).

I think the extended asm would need be along the lines of
   gcc_jit_block_add_extended_asm (gcc_jit_block *block,
                                   ...something...);

possibly with and without goto labels.

Do you have a specific use-case in mind?  Thanks

Reply via email to