For the purpose of this answer, I'm going to assume x86 or x86_64 and that you are really looking for an assembly answer. Also, since I misread the question the first time, I'm providing two answers for you... :)
What that context, there are no instructions to allow you to deal with just a few bits directly, though there are the various register names to allow you to get to things as small as a single byte. Otherwise, bit manipulation would require AND and OR with masking.
For your specific case, though, there is an alternative. Consider this:
mov eax, 0xAABBCCDD
We now have your value in eAX. If you want to reverse the order of the bytes within that register, the BSWAP
instruction is for you:
bswap eax
This will result in EAX containing 0xDDCCBBAA, which seems to be what you've asked.
On the other hand, if you want to switch the bits to move the 0xAABB to the lower two bytes, you can do this:
ror eax, 16
This will rotate the 32 bit value to the right 16 bits. In other words, EAX will now contain 0xCCDDAABB, which was your goal.