powerpc - What would be the C equivalent of rlwinm (PPC Instruction) -
i wondering if of know c equivelent of powerpc instruction below.
rlwinm r31, r0, 0,13,13 thanks.
rotate left register immediate, and mask.
rotate left 0 here, can ignore this. mask bits set 13 13, bit 13 (0x2000 bitmask; command chosen on and document bit 13 selected).
so in case, need build mask bit 13 , apply bitwise and source.
r31 = r0 & (1 << 13); << shift left operation in c, use here create mask bit 13. & , operation in c.
documentation source: http://sametwice.com/rlwinm
Comments
Post a Comment