[Bug c/117265] RFE: support for assembly macros/assembly headers

2025-04-29 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #17 from H. Peter Anvin --- So I am still confused by this. It would seem that this really ought to be a very simple request, and that adding compiler support for all these cases would impose a really large burden on the gcc team (y

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-27 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #16 from H. Peter Anvin --- Except there is no load or store anywhere (see the case on comment 12), so I don't understand.

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-26 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #15 from Andrew Pinski --- Maybe what you want is really a builtin does the load/store and the ability to output the register # that the address is formed into instead of this inline-asm. This might be better than what you are asking

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-26 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #12 from H. Peter Anvin --- Certainly. This is *not* only used by copy_*_user (or {get,put}_user for that matter), here is an example from msr.h: static inline unsigned long long native_read_msr_safe(unsigned int msr,

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-26 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #14 from H. Peter Anvin --- Note: comment 13 is not intended to be rhetorical but is a genuine question.

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-26 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #13 from H. Peter Anvin --- When you say "should be done in an exceptional way", could you please clarify what you mean? I'm not sure I follow you there? Are you saying we should be asking for compiler support?

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-26 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #10 from Andrew Pinski --- Your example is not a full example on how you use _ASM_EXTABLE_TYPE_REG .

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-26 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #11 from Andrew Pinski --- Plus your example is only for copy_{to,from}_user which itself is an exceptional part of the kernel and should be done in an exceptional way in the first place. Do you have other examples that is not from

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-26 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #9 from H. Peter Anvin --- Created attachment 59450 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=59450&action=edit Proposed assembly header implementation

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-26 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #8 from H. Peter Anvin --- Created attachment 59449 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=59449&action=edit Current code

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-26 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #7 from H. Peter Anvin --- I have included a concrete example from the Linux kernel (with other parts of the code stripped for clarity.) The file asm_header.s shows how it could be implemented as an assembly header. As you can see,

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-23 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #6 from H. Peter Anvin --- No idea what you mean with #asmoptions. Using hacks in the Makefile is equivalent to having to do dependencies by hand (keep in mind that these statements will generally be part of header files.) In other

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-23 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #5 from Richard Biener --- So instead of having the #asminclude in the C file you can arrange for it in the Makefile by source specific rules? That said, at what point would you request a #asmoptions directive?

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-22 Thread hpa at zytor dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #4 from H. Peter Anvin --- On October 22, 2024 1:19:05 PM PDT, "pinskia at gcc dot gnu.org" wrote: >https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 > >Andrew Pinski changed: > > What|Removed |A

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 Andrew Pinski changed: What|Removed |Added Severity|normal |enhancement Keywords|

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #3 from Andrew Pinski --- Let me expand on this and question why what you want is needed. Can you explain exactly what kind of macros that are asm macros are being used and why they can't be C processor macros that will then be used

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 Andrew Pinski changed: What|Removed |Added Last reconfirmed||2024-10-22 Status|UNCONFIRM

[Bug c/117265] RFE: support for assembly macros/assembly headers

2024-10-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117265 --- Comment #1 from Andrew Pinski --- Why not use the c preprocessor and string concating?