Architecture 02 Flashcards

1
Q

What is assembly language?

A

A given assembly language uses the instruction set and operands from a single processor. Thus, many assembly languages exist, one for each processor.

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

What is an assembler?

A

Converts assembly language for ISA to more detailed object code.

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

What is a compiler?

A

Software that converts high-level program into low level instructions for specific machine, and is not (usually) needed at run time.

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

What is an interpreter?

A

Software that reads a high-level program and carries it out. This is done at run time.

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

What is a linker?

A
  • Combines object code files together to make an executable program that can actually run.
  • It incorporates necessary library object code files.
  • It determines memory offsets for functions in different files.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is a loader?

A
  • Software that loads programs and libraries into memory to prepare them for execution
  • It’s provided by the OS
  • Which also provides access to hardware resources
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is a register?

A

A small, high-speed hardware storage device found in a processor. A register has a fixed size and supports two basic operations: fetch and store.

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

What is a general-purpose register?

A
  • Used as a temporary storage mechanism
  • There are usually only a small number of them
  • Each register is usually the size of an integer.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is meant by “orthogonality”?

A

An ISA is orthogonal if each instruction perform a unique task without overlapping with other instructions.

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

What is an operand?

A

Things the CPU can apply operations to, like registers

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

What is meant by register-memory?

A
  • At least one instruction argument can come straight from memory
  • More expressive, less need to find registers to store things in
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is meant by register-register (load-store)?

A
  • All operations work between registers
  • Only data transfer operations access memory
  • Separation of memory access and arithmetic functions makes design simpler
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Explain what is meant by an operation taking 3 operands

A
  • Operation specifies both inputs and an output location
  • e.g Add x to y, store in z
  • Instructions get longer, more memory access required
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Explain what is meant by an operation taking 2 operands

A
  • Result replaces one input

* e.g Add x to y, changing y

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

Explain what is meant by an operation taking 1 operand

A
  • All operations modify an “accumulator”

* e.g Add x to the “accumulator”

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

Explain what is meant by an operation taking 0 operands

A
  • Manipulating the stack directly

* e.g Replace the top two numbers of the stack by their sum

17
Q

What is an opcode?

A
  • Short for operation code, refers to the exact operation to be performed
  • Each operation must be given a unique opcode by the ISA (i.e integer addition might be 5)
18
Q

What are the advantages of having fixed-length instructions over variable-length instructions?

A
  • Variable length instructions instructions require complex hardware to fetch and decode
  • Fixed length instructions are easy to fetch and decode, and the hardware can compute the location of the next instruction easily.