From the "Java Language Specification", section 15.19, about shifting "If the promoted type of the left-hand operand is long, then only the six lowest-order bits of the right-hand operand are used as the shift distance. It is as if the right-and operand were subjected to a bitwise logical AND operator & with the mask value 0x3f. The shift distance actually used is therefore awlays 0 to 64, inclusive."
So, >>> -3
has equivalent effect as >>> 61
, and -1L >>> -n
equals -1L >>> (0x3f&-n)
Actually this seems to be the most effective way of producing a consecutive 1s
in the lowest n-bits of a long integer.