It has come to my attention the following:

"The only case where you have to resort to writing hex code manually
is when the assembler cannot output the desired code for some reason.
If I recall correctly, there is only one such case in the HelenOS
sources:

#define ___traceon()  asm volatile ( "\t.word\t0x39\n");

#define ___traceoff()  asm volatile ( "\t.word\t0x3d\n");

#define ___regview()  asm volatile ( "\t.word\t0x37\n");

#define ___halt()  asm volatile ( "\t.word\t0x28\n");

#define ___intmode()  asm volatile ( "\t.word\t0x29\n");

http://trac.helenos.org/browser/mainline/kernel/arch/mips32/include/debug.h?rev=mainline%2C1446.3.1

Here they manually encode the opcodes of five special debugging
instructions for the MSIM MIPS simulator (these instructions are not
part of the standard MIPS ISA, thus the assembler does not know them)."

How the OpenBSD developers solve problems that are not resolved by Assembly?

Reply via email to