1 of 87
Computer Systems
Seminar 3 Petru Eles petel@ida.liu.se tf: 281396 Some few slides are based on material from the course book as well as from the book “Computer Systems: A Programmer’s Perspective” by Bryant & O’Hallaron
2 of 87
Binary Representation
■
Information is represented as a sequence of binary digits: Bits
■
What the actual bits represent depends on the context:
❚
Numerical value (integer, floating point, fixed point)
❚
Sequence of characters (text)
❚
Executable instruction
3 of 87
Binary Representation
■
Information is represented as a sequence of binary digits: Bits
■
What the actual bits represent depends on the context:
❚
Numerical value (integer, floating point, fixed point)
❚
Sequence of characters (text)
❚
Executable instruction
■
Depending on the context, operations performed are:
❚
Logical computation (context: logic) 1: true Operations: And, Or, Exclusive-Or (Xor), Not 0: false
❚
Numerical Computation (context: numbers) 1 Operations: Addition, Subtraction, Multiplication, Division
4 of 87