In software reverse engineering, we use a dissembler, a debugger, and a code patcher. OllyDbg includes all. One of the differences between actual execution of a program and debugging through using OllyDbg is, in OllyDbg the instruction pipe-lining is not used.
How can we take advantage of this fact to make the software immune to reverse engineering attacks?
The obvious answer is write an instruction that modifies already fetched instruction.
My question is how do we write a higher level language code, which after getting translated into assembly language will have instructions such that some instructions scramble previous instructions (those should be fetched before getting scrambled...here we might have to assume size of instruction pipe, say X).
Is it possible to write such code in a higher level language, if yes can I have an example.