Você está na página 1de 33

IT PROGRAM

LOGIC
FORMULATION
Topics to be discussed

▸Introduction
▸History of computer
▸Types of computer
▸Functional units of a computer
▸Basic operation of computer
▸Computer Level Hierarchy
▸Computer Architecture
▸Types of Computer Language
BASIC OPERATION OF
A COMPUTER
Basic Operation of a computer

1. The computer accepts


information in the form of
programs and data through an
input unit and stores it in memory.
2. Information stored in the
memory is fetched, under
program control, into an arithmetic
and logic unit, where it is
processed.
3. Processed information leaves the
computer through an output unit.
4. All activities inside the machine are
directed by the control unit.
Computer Level
Hierarchy
Level 6: User

▸It is composed of applications and is the level where


everyone is most familiar

▸other levels are invisible to most users most of the time


Level 5: High-Level Language Level

▸Consists of language such as C, C++, Java

▸These languages must be translated to a language


the machine can understand.

▸Needs a compiler or interpreter

▸User still abstracted from actual implementation of


concepts such as data types and memory storage
Level 4: Assembly Language Level

▸Translates the compiled higher-level languages into


machine language.

▸It reduces the gap between a high-level language and


the actual machine language
Level 3: System Software Level

▸This level deals with the operating system

▸It is responsible for multiprogramming, protecting the


memory, synchronizing processes and various
important functions.

▸Instructions translated from assembly to machine


language passed through this level.
Level 2: Instruction Set Architecture / Machine Level

▸Consists of machine language recognized by the


particular architecture of the computer system

▸Programs written in a computer’s true machine


language on a hardwired computer can be executed
directly by electronic circuits.
Level 1: Control Unit

▸ The control unit makes sure that instructions are


decoded and executed properly and that data is
moved where and when it should be.

▸Interprets instructions given to it one-at-a-time


Level 0 : Digital Logic

▸Where physical components of the computer system,


gates and wires can be found.

▸Fundamental building blocks, the implementations of


the mathematical logic and are common to all
computer systems
Computer
Architecture
Computer Architecture

▸Computer Architecture is the design of


computers, including their instruction sets, hardware
components

▸Most computers follow the Von Neumann


Architecture, also known as the Stored Program
Architecture or the Fetch-Decode-Execute
Architecture.
Von Neumann Architecture

▸named after John von Neumann, who published the first


paper describing it consists of three hardware systems:

▸a Central Processing Unit (CPU) with a control unit, an


Arithmetic Logic Unit (ALU), registers and a program
counter
▸a Main Memory System, which holds program and data
▸an I/O System
this single pathway creates the von Neumann Bottleneck
Von Neumann Bottleneck

▸program and data memory cannot be accessed at


the same time

▸large impact on processing speed when large


amounts of data are handled with little processing

▸with increases in CPU and memory size the


bottleneck becomes worse
Von Neumann Bottleneck

▸one remedy, the Harvard Architecture, separates data and instructions into
two pathways
▸most modern systems use a System Bus to alleviate:
Types of Computer
Language
Generation of Programming Languages

1. Machine Language
2. Assembly Language
3. High Generation Language
4. 4GL
Machine Language

▸The natural or primitive language that 10111000


the computer actually understands. This 00000101
programming language consists of 0’s and 1’s 00000000
which makes programming very difficult. 10111011
00000011
▸Sample machine language program to add 5 00000000
and 3 (using the Intel microprocessor 00010001
instruction set): 11011000
Assembly Language

▸A programming language that uses “abbreviations” or


mnemonics in place of binary patterns in order to make the task
of programming easier.

▸An assembly language program has to be converted to


machine language before a computer can execute it.
Assembly Language

▸Sample assembly language program to add 5


and 3 (using the Intel microprocessor instruction
set):

▸MOV AX, 05
▸MOV BX, 03 ADC AX, BX
High Level Language

▸A programming language that uses English-like


commands or instructions. High-level languages are the
easiest to use and contains many complicated or advanced
instructions.

▸A high-level language has to be converted to machine language


before a computer can execute it.
High Level Language

▸Examples of High-level Languages:

▸FORTRAN (FORmula TRANslation)


▸COBOL (COmmon Business-Oriented Language)
▸BASIC (Beginner’s All-purpose Symbolic Instruction
Code)
▸Pascal
▸JAVA
4GL

▸A fourth generation (programming) language (4GL) is a


grouping of programming languages that attempt to get closer
than 3GLs to human language, form of thinking and
conceptualization.

▸4GLs are designed to reduce the overall time, effort and cost of
software development.
4GL

▸The main domains and families of 4GLs are:

1. database queries,
2. report generators,
3. data manipulation,
4. analysis and reporting,
5. screen painters and generators,
6. GUI creators,
7. mathematical optimization,
8. web development
9. general purpose languages.
Advantages using high level languages

1.Easy to Learn. Low-level languages are more cryptic than high-


level language.

2.Predefined Functions. Most high-level languages


provide many pre-defined functions and subroutines, thereby
simplifying programming tasks.

3.Portability. Low-level languages are specific towards a certain


processor. The instruction set of the Intel processors (IBM PC’s
and compatibles) is very much different from the instruction
set of the Motorola processors (Apple Macintosh).
Advantages of Low Level Language

▸Compact Code. Programs are executed in their


machine language format. Programs written in a high-level
language should still be compiled and translated to machine
language. Most compilers are not optimized to generate compact
code.

▸Speed. This is directly related to compact code. The


shorter the code, the shorter the execution time of the program.

▸Flexible. Low-level language does not constrain the


programmer to follow a certain programming convention or
a rigid coding constraint
System Software

▸Operating Systems.
▹An operating system is the most fundamental set of
programs on a computer. The operating system
controls the internal operations of the computer’s
hardware, manages all of the devices connected to the
computer, allows data to be saved to and retrieved
from storage devices, and allows other programs to
run on the computer. There are four popular operating
systems: Windows, iOS, Mac OS®, and Linux®.
▸A utility program performs a specialized task that
enhances the computer’s operation or safeguards
data. Examples of utility programs are virus scanners,
file compression programs, and data backup
programs.
▸Software development tools are the programs that
programmers use to create, modify, and test software.
Assemblers, compilers, and interpreters are examples
of programs that fall into this category.

Você também pode gostar