Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

As it was described in the class, the microprocessor has a single hardware unit

ID: 2291525 • Letter: A

Question

As it was described in the class, the microprocessor has a single hardware unit (Arith metic Logic Unit) for arithmetic operations. That means, both signed operations as well as unsigned operations are performed by the same unit. How then does the microprocessor distinguish between the signed and unsigned data? Consider the subtractions 26-27-99 and 18-34-84. Explain how these answers (99 and 84) can be interpreted as the correct signed results of these subtractions? Note that all the numbers are decimal numbers. (Hint: subtraction through compliments) 111.

Explanation / Answer

2) Microprocessor does not have any special mechanism for distinguishing whether integer is signed or unsigned . Computer stotes signed and unsigned numbers in same data .For example 11111111 is 255 or -1 .Howe How we need to tell compilers which type of variable you need to use compiler program to make processor understand .This information was taken from below source link. Thank you

3) There is no particular mechanism for checking that .

https://stackoverflow.com/questions/10893232/how-computer-distinguish-an-integer-is-signed-or-unsigned