Chap 2 - Part 2 - Cont'd Flashcards

1
Q

Define:

Binary Digit

A

Also known as binary bit

  • One of the two numbers in base 2, 0 or 1, that are the components of information
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Define:

Least significant bit

A

The rightmost bit in a MIPS word

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Define:

Most significant bit

A

The leftmost bit in a MIPS word

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Define:

Instruction format

A

This is a form of representation of an instruction composed of fields of binary numbers

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Define:

Machine language

A

This is the binary representation used for communication within a computer system

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Define and explain:

Unsigned Binary Integers

A
  • An unsigned binary integer: is a fixed-point system with no fractional digits
  • Unsigned binary integers are positive number systems, usually with a modulus, which is a power of 2
  • Ex.
    • a 4-bit unsigned binary number has values ranging from:
      • (00002)(010) to 11112 (1510)

Modern computers support binary integers of 8, 16, 32, or 64 bits

the largest value in any unsigned binary integer system is:

  • one containing all 1’s, similarly, just as the largest decimal number is the one containing all 9’s.
  • largest modulo - 100010 = 99910
  • Largest modulo - 10002 = 1112
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is the largest value possible in N bits for unsigned binary integers?

A

largest value possible in N bits is:

2N -1

Image;

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Explain:

One’s complement

A

This is a notation that represents:

  • The most negative value by 10…0002 and…
  • the most positive value by 01…. 112

This notation leaves an equal number of negatives and positives but ends up with two zeroes

The term is also used to mean the Inversion of every bit in a pattern:

0 to 1 and 1 to 0

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Negation shortcut:

Explain this concept

A

This is also known as:

Bitflipping

Suppose we want to come up with the 1’s complement representation for the number -2 in base 10…

  • start by converting 210 to base 2:
    • 210 = 00102
  • flip all the bits == 1101
  • And, add 1, therefore == 1110

OR

Another shortcut of bitflipping is:

you may flip all the bits to the left of the least significant set bit…

  • eg.
    • 210 = 00102 = 1110 [done!]
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Explain the concept of:

2s- complement signed integers

A

Given an N-bit number…

we can let its range be:

  • -2n-1 to + 2n-1 - 1

So, using 32 bits yield the range:

Image:

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Example of:

2s-Complement signed integers

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Explain:

Signed Negation

A

Complement and add 1:

  • Complement means 1 > 0, 0 > 1
  • ex
    • Image:
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

About Sign Extension Concept

A

Image:

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

About Hexadecimal concept

A

Image:

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Signed Vs. Unsigned

A

Image:

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Define leaf procedures

A

This are types of procedures that doesn’t call any other procedures

17
Q

Leaf Procedure Example:

A
18
Q

Define non-leaf procedures

A

These are procedures that call other procedures

For nested call, caller needs to save on the stack:

  • its return address
  • any arguments and temporaries needed after the call
  • restore from the stack after the call

Image:

19
Q

Non-leaf procedure Example:

A

No answer to this, just an example of the non-leaf procedure, check question

20
Q
A