Injecting user defined opcode

Mahmood Naderan via gcc-help
Sun Jun 30 11:13:00 GMT 2019

>No.  That's not done by GCC or GNU as.
>It's how Intel/AMD CPU parses the machine code.  There are no "delimeters" in
>machine code so the CPU regards "00 5d c3" as an instruction.  objdump (from
>Binutils) just emulates the behavior of CPU.

But as you can see in the output of "disass /r main", it the GDB or GCC that forms such a machine code. CPU won't fetch any instruction until "run" command is used. Therefore, I think it is GCC or GDB that forms such a machine code.


More information about the Gcc-help mailing list