Presentation on theme: "SYSTEM PROGRAMMING & SYSTEM ADMINISTRATION UNIT-1."— Presentation transcript:
SYSTEM PROGRAMMING & SYSTEM ADMINISTRATION UNIT-1
What Is System Program System Programs were developed to make computers better adapted to the needs of their users. Some examples of system program are: Compliers Loaders Macro processors Operating systems
Brief Introduction Complier:- They are systems programs that accept people-like languages & translate them into machine language. Loaders:- They prepare machine language program for execution. Macro processors:- They allow programmers to use abbreviations. Operating Systems & file system:-They allow flexible storing & retrieval of information.
ASSEMBLERS It is difficult for programmers to write or read programs in machine language. So they began to use a mnemonic (symbol) for each machine instruction,which they would subsequently translate into machine language. Such a mnemonic language is known as ASSEMBLY LANGUAGE.
ASSEMBLERS cont…. Assemblers are programs written to automate the translation of assembly language in to machine language. The input to an assembler program is called the source program. The output is a machine translation (object program).
ASSEMBLERS cont…. An assembly language is a machine dependent, low level programming language which is specific to a certain computer system. Three basic features which simplify programming : 1. Mnemonic operation codes 2. Symbolic operands 3. Data declarations
Execution of program written in a language L involves the following steps 1. Translation of the program- by translator 2. Linking of the program with other programs needed for its execution-by linker 3. Relocation of the program to execute from the specific memory area allocated to it 4. Loading of the program in the memory for the purpose of execution-by loader
Program Execution TranslatorLinkerLoader Binary Program Source Program Objects Modules Binary Programs Results Data Data flow Control flow
LOADERS A loader is a program that places programs into memory & prepares them for execution. In a simple loading scheme, the assembler outputs the machine language translation of a program on a secondary device & a loader is placed in core (memory). Subroutines:- It is a body of computer instruction designed to be used by others routines to accomplish a task.
LOADERS cont…. Two types of subroutines are Closed subroutines: It can be stored outside the main routine &control transfers to the subroutine. Open subroutines : It is one whose code is inserted into main program.
MACROS Macro processing facility which permits the programmer to define an abbreviation for a part of his program & to use the abbreviation in his program. The macro processor treats the identical parts of program defined by the abbreviation as a macro definition & saves the definition.
COMPLIERS A complier is a program that accepts a program written in a high level language & produces an object program. Example of high-level language are: FORTRAN COBOL ALCOL Interpreter : It is a program that appears to execute a source program as if it were machine language.
SOFTWARE TOOLS Program that help in developing & using other programs. These programs, called software tools. Definition:- A software tool is a system program which 1. Interfaces a program with the entity generating its input data. 2. Interfaces the results of a program with the entity consuming them.
A Software tool Originator Raw Program or Data Software Transformed Program or Data Consumer A Software tool
Software Tools For Program Development 1. Program design, coding, & documentation 2. Preparation of programs in machine readable form 3. Program translation, linkage & loading 4. Program testing & debugging 5. Performance tuning 6. Reforming the data and/or results of a program to suit other programs.
1. Program Design & Coding Two categories of tools used in program design & coding are 1. Program generators:- It generates a program which performs a set of functions described in its specification 2. Programming environments:-It supports program coding by incorporating awareness of the programming language syntax & semantics in the lang. editor
2. Program Entry & Editing These are text editors or more sophisticated programs with text editors as front ends. The editor functions in 2 modes:- 1. Command mode 2. Data mode
Program Testing & Debugging Main steps in this are selection of test data for the program, analysis of test results to detect errors,& debugging i.e. localization & removal of errors. Software tools to assist the programmer in these steps are:- 1. Test data generators 2. Automated test drivers 3. Debug monitors 4. Source code control systems
EDITORS Forms of Editors 1. Line Editors 2. Steam Editors 3. Screen Editors 4. Word Processors 5. Structure Editors
EDITORS cont… Line Editors:- The scope of edit operations in a line editor is limited to a line of text. The line is designed positionally,e.g. by specifying its serial number in the text, or contextually, e.g. by specifying a context which uniquely identifies it.
EDITORS cont… Stream Editors:- A stream editor views the entire text as a stream of characters. They typically supports characters, line, & context oriented commands based on the current editing context indicated by the position of a text pointer.
EDITORS cont… Screen Editors: - A line or stream editors does not display the text in the manner it would appear if printed. A screen editor uses the what-you –see-is- what-you-get principle in editor design. This is very useful while formatting the text to produce printed documents.
EDITORS cont… Word processors:- They are document editors with additional features to produce well formatted hard copy output. Essentials features are commands for moving sections of text from one place to another, merging of text, & searching & replacement of words. Many word processor support a spell-check option.
EDITORS cont… Structures Editors:- A structure editor incorporates an awareness of the structure of a document. This is useful in browsing through a document,e.g. if a programmer wishes to edit a specific function in a file.
DEBUG MONITORS It provide the following facilities for dynamic debugging : 1. Setting breakpoints in the program 2. Initiating a debug conversation when control reaches a breakpoint 3. Display values of variables 4. Assigning new values to variables 5. Testing user defined assertions & predicates involving program variables.
DEBUG MONITORS The sequence of steps involved in dynamic debugging of a program is as follows: 1. The user complies the program under the debug option. The compiler produces two files- the compiled code file & the debug information file. 2. The user activates the debug monitor & indicates the name if the program to be debugged.
DEBUG MONITORS cont… 2. The debug monitor opens the compiled code & debug information files for the program. 3. The user specifies his debug requirements – a list of breakpoints & actions to be performed at breakpoints. The debug monitor instruments the program, & builds a debug table containing the pairs.
DEBUG MONITORS cont… 4. The instrumented program gets control & executes up to a breakpoints. 5. A software interrupt is generated when the is executed. Control is given to the debug monitor which consults the debug table & performs the debug actions specified for the breakpoints.
DEBUG MONITORS cont… A debug conversation is now opened during which the user may issue some debug commands or modify breakpoints & debug actions associated with breakpoints. 6. Steps 4 & 5 are repeated until the end if the debug session.
PROGRAMMING ENVIRONMETS A programming environment is a software system that provides integrated facilities for program creation, editing, execution, testing, & debugging. It consists of the following components : 1. A syntax directed editor (which is a structure editor) 2. A language processor –a complier, interpreter, or both 3. A debug monitor 4. A dialog monitor