Course outline and Introduction
IT264 Computer Architecture & Microprocessor Interfacing
Outline
IT264 Computer Architecture & Microprocessor Interfacing
2
12/20/2024
IT264 Computer Architecture & Microprocessor Interfacing
IT264 Computer Architecture & Microprocessor Interfacing
3
12/20/2024
Teaching Scheme | Theory | Practical | Total | Credit |
Hours/week | 4 | 2 | 6 | 5 |
Marks | 100 | 50 | 150 |
Reference material
IT264 Computer Architecture & Microprocessor Interfacing
4
12/20/2024
Course Objectives…
IT264 Computer Architecture & Microprocessor Interfacing
5
12/20/2024
Course Motivation…
This knowledge will be useful if you need to
IT264 Computer Architecture & Microprocessor Interfacing
6
12/20/2024
Course Pre requisite…
Require Knowledge of
IT264 Computer Architecture & Microprocessor Interfacing
7
12/20/2024
Outline of the Course…
IT264 Computer Architecture & Microprocessor Interfacing
8
12/20/2024
Let’s know about our computer
Tools to discover our computer
IT264 Computer Architecture & Microprocessor Interfacing
10
12/20/2024
Measuring Performance of Computer
IT264 Computer Architecture & Microprocessor Interfacing
11
12/20/2024
Intel Processors
IT264 Computer Architecture & Microprocessor Interfacing
12
12/20/2024
Comparing two similar processors
IT264 Computer Architecture & Microprocessor Interfacing
13
12/20/2024
Moore’s Law
IT264 Computer Architecture & Microprocessor Interfacing
14
12/20/2024
Time Line: Intel Processor
IT264 Computer Architecture & Microprocessor Interfacing
15
12/20/2024
Time Line: Intel Processor
IT264 Computer Architecture & Microprocessor Interfacing
16
12/20/2024
Why is AMD Ryzen 5 3500U better than Intel Core i5-1035G1?
IT264 Computer Architecture & Microprocessor Interfacing
17
12/20/2024
Why is Intel Core i5-1035G1 better than AMD Ryzen 5 3500U?
IT264 Computer Architecture & Microprocessor Interfacing
18
12/20/2024
Few Terms…
IT264 Computer Architecture & Microprocessor Interfacing
19
12/20/2024
Software Abstraction…
IT264 Computer Architecture & Microprocessor Interfacing
20
12/20/2024
Computer understand this
Programmer understand this
Comparison of programming languages
IT264 Computer Architecture & Microprocessor Interfacing
21
12/20/2024
0 0010 0000 0000 0100
1 0001 0000 0000 0101
10 0011 0000 0000 0110
11 0111 0000 0000 0001
100 0000 0000 0101 0011
101 1111 1111 1110 1001
110 0000 0000 0000 0000
Location Instruction Code
000 2004
001 1005
002 3006
003 7001
004 0053
005 FFE9
006 0000
Location Instruction
000 LDA 004 Load 1st operand into AC
001 ADD 005 Add 2nd operand to AC
002 STA 006 Store sum in location 006
003 HLT Halt computer
004 0053 1st operand
005 FFE9 2nd operand (negative)
006 0000 Store sum here
Location Instruction Comments
INTEGER A, B, C
DATA A,83 / B,-23
C = A + B
END
ORG 0 /Origin of program is location 0
LDA A /Load operand from location A
ADD B /Add operand from location B
STA C /Store sum in location C
HLT /Halt computer
A, DEC 83 /Decimal operand
B, DEC -23 /Decimal operand
C, DEC 0 /Sum stored in location C
END /End of symbolic program
int A=83, B=-23, C
C = A + B
Compiler
Assembler
Steps in gcc.
IT264 Computer Architecture & Microprocessor Interfacing
22
12/20/2024
cpp
hello.c
cc1
as
ld
hello.s
hello.o
a.out
Library files
e.g., math.o, the math library
Linking Multiple Modules
IT264 Computer Architecture & Microprocessor Interfacing
23
12/20/2024
Header Info |
Compute(){ call MatMul() } |
Data |
Symbol Table |
Reloc Info |
Header Info |
MatMul(){ } |
Data |
Symbol Table |
Reloc Info |
Linking Multiple Modules
IT264 Computer Architecture & Microprocessor Interfacing
24
12/20/2024
Header Info |
Compute(){ call MatMul } |
Data |
Symbol Table |
Relocation Info |
Combined Header Info |
Compute() MatMul() |
Combined Data |
Symbol Table |
Reloc Info |
Header Info |
MatMul(){ } |
Data |
Symbol Table |
Relocation Info |
From C Code to Process
IT264 Computer Architecture & Microprocessor Interfacing
25
12/20/2024
binary files
C source code
process
compiling
running
executable
linking
Memory architecture
IT264 Computer Architecture & Microprocessor Interfacing
26
12/20/2024
0xffffffff
0
Organization of Memory: .text
IT264 Computer Architecture & Microprocessor Interfacing
27
12/20/2024
0xffffffff
0
text
Organization of Memory: .text
IT264 Computer Architecture & Microprocessor Interfacing
28
12/20/2024
0xffffffff
0
text
Organization of Memory: .data
IT264 Computer Architecture & Microprocessor Interfacing
29
12/20/2024
0xffffffff
0
text
data
bss
Organization of Memory: heap
IT264 Computer Architecture & Microprocessor Interfacing
30
12/20/2024
0xffffffff
0
text
data
bss
heap
Organization of Memory: stack
IT264 Computer Architecture & Microprocessor Interfacing
31
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
Summary
IT264 Computer Architecture & Microprocessor Interfacing
32
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
Example
char *string = “hello”;
int iSize;
char *f (int x)
{
char *p;
iSize = 8;
p = (char *)malloc (iSize);
return p;
}
IT264 Computer Architecture & Microprocessor Interfacing
33
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
Example
char *string = “hello”;
int iSize;
char *f (int x)
{
char *p;
iSize = 8;
p = (char *)malloc (iSize);
return p;
}
IT264 Computer Architecture & Microprocessor Interfacing
34
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
Variable Lifetime (Scope)
IT264 Computer Architecture & Microprocessor Interfacing
35
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
Data Initialization
char *string = “hello”;
int iSize;
char *f (int x)
{
char* p;
iSize = 8;
p = (char *)malloc (iSize);
return p;
}
IT264 Computer Architecture & Microprocessor Interfacing
36
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
program startup
when f() is called
live after allocation; till free() or program finish
Variable Initialization
IT264 Computer Architecture & Microprocessor Interfacing
37
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
Explicit Memory Management
IT264 Computer Architecture & Microprocessor Interfacing
38
12/20/2024
Example
int main()
{
int *p;
p = (int *)malloc (sizeof (*p));
*p = 99;
return 0;
}
IT264 Computer Architecture & Microprocessor Interfacing
39
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
p
Example
int main()
{
int *p;
p = (int *)malloc (sizeof (*p));
*p = 99;
return 0;
}
IT264 Computer Architecture & Microprocessor Interfacing
40
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
#@%*&
p
Example
int main()
{
int *p;
p = (int *)malloc (sizeof (*p));
*p = 99;
return 0;
}
IT264 Computer Architecture & Microprocessor Interfacing
41
12/20/2024
0xffffffff
0
text
data
bss
heap
stack
99
p
Architecture & Organization
IT264 Computer Architecture & Microprocessor Interfacing
42
12/20/2024
Structure of Von Neumann machine
IT264 Computer Architecture & Microprocessor Interfacing
43
12/20/2024
References
IT264 Computer Architecture & Microprocessor Interfacing
44
12/20/2024