On 10/11/2023 16:12, Grischa Göbel via Gcc-help wrote:
Dear gcc team, i would like to write an educational book about software engineering. Beside the usual introductions to programming i would like to show the reader examples of disassemblies generated by the compiler, so that the reader gets a deeper understanding on whats actually happening under the hood. I would like to ask you, if i am allowed to print disassemblies generated by the GNU C++ compiler in a commercial book / blog or any other medium. Regards, Grischa Göbel
The disassembly is generated from /your/ code - /you/ choose the license for it.
A tool you might find useful is <https://www.godbolt.org/>. The code for the site is also available under an open source license (AFAIK).
You might find it useful to discuss some of your sample code on the Usenet groups comp.lang.c and comp.lang.c++ (as appropriate). You could get some helpful feedback - as well as some strong opinions!