Look at the code block 2, it reads from CodeBuffer[ 1 .. 16 ] to give the EDX; but in your so-called "reversed" code block, it writes to CodeBuffer[ 0 .. 15 ] or CodeBuffer[ -15 .. 0 ] depending upon the direction flag ...
They are NOT reversed to each other at all

((
I am afraid you should revise the "reversed" code block to write to CodeBuffer[ 16 .. 1 ] instead, not only the ROR/SUB etc ....