My lecturer told me that when I use an arithmetic I-Type command (ADDI,SUBI etc.) , the IMM field gets sign extended, and when I use a logic I-Type command (ORI,ANDI etc.) , the IMM field is just bits.
He also said that if the IMM field contains a negative number, it is represented in 2's complement.
Let's say I have a command, and two binary numbers X Y, so that X's 2's complement representation looks exactly like Y in regular representation.
Note: X is negative and not the same as Y.
Given a question in which I should say what is the value in the IMM field in an arithmetic I-Type command, how do I know if it's X or Y?