In: Computer Science
1) Alternative compiled code sequence using instructions in classes A, B, C. What is the average CPI of sequence 1 and sequence 2?
class A B C
CPI for class 3 4 6
IC in Sequence 1 6 12 10
IC in sequence 2 2 4 2
2) given the 8-bit binary number 1011 1110 (two's compliment, we will call this number N)
a) what is the hEX representation of N
b) what is the decimal value if N is an 8-bit 2's compliment signed number?(please write steps
c)what is the decimal value if N is an 8-bit unsigned number?
To convert a binary number to hexadecimal number, simply we make group of 4bits from LSB (Least Significant Bit) and convert each group into a hexadecimal number.
To convert a 2's complement number to decimal, we check if MSB bit is set or not. If it is set then to get decimal number, we do 2's complement of number.