Hello Philipp, Thursday, July 14, 2022, 2:35:46 PM, you wrote:
The main problem is not that this assembler in "form 1" exist. The problem that this form is very popular. It is used in almost every project. There is a lot of such code in GBStudio, which is a very large and extremely popular project too. No preprocessor in form1? That is a crucial feature as well, because it will break stuff like this: https://github.com/gbdk-2020/gbdk-2020/blob/develop/gbdk-lib/include/gb/gb.h#L455-L461 and a lot of other places. PKK> SDCC needs a new preprocessor, and the inline asm forms is an issue that came up there. The peephole optimizer, which is invoked much later is not such a problem. PKK> Even with the proposed changes, naked functions written in assembly would still work. Only the possible future GCC-style forms with : in them would not work there (but that is fine, since they are meant to provide functionality for interacting with surrounding C code in the same function, so they don't make sense for naked functions anyway). PKK> I see the problem with exiting asm using form 1. However, it causes issues with the preprocessor. PKK> Would it be ok for your project, if we keep support for form 1, but restrict it a bit: disallow the use of preprocessor directives and macros in between __asm and __endasm? PKK> Then only the users that want to use preprocessor functionality in inline assembler would have to switch to form 2. -- Best regards, Tony mailto:unt...@mail.ru _______________________________________________ Sdcc-user mailing list Sdcc-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sdcc-user