Friday 13 November 2015

SCHEDULING: An Introduction

When you learn to quit, it becomes a habit.
-Vince Lombardi

SCHEDULING: An Introduction

‘Schedule’ in literal sense means plan for something to happen at a particular time, but in the terms of operating system ‘Schedule’ or ‘Scheduling’ means to manage or to plan the process such that it has minimum utilization of Central Processing unit(CPU).

The policies which are used for scheduling are called ‘Scheduling Policies’ (or disciplines).

1.1 Workload Assumptions

Here we will make some assumptions that will be implied as we move further.The assumptions we make are:-

1)All processes/workload run for same amount of time.
2)Each Process start at the same time.
3)When run each process runs to its completion.
4)Each process uses CPU.
5)The run time of each process is known.

1.2 Scheduling Metrices

A ‘Metric’ is something used to measure something.

Let me introduce you to our first metric i.e. Turnaround time.

The formula for Turnaround time is as follows:

T(turnaround)= T(completion)-T(arrival)

where, T(turnaround)= Turnaround time
T(completion)= Completion Time
T(arrival)= Arrival Time

Since, as we stated in our assumption no. 2 i.e.:-
Each process start at the same time, so,
T(arrival)= 0 seconds (for every process)

So, the above equation becomes,

T(turnaround)= T(completion)- T(arrival)
T(turnaround)= T(completion) - 0
T(turnaround)= T(completion)

This equation will be applicable for further tutorials.

‘Turnaround time’ and another term called ‘fairness’ are two main point of focus in scheduling processes.

Since, we already discussed ‘Turnaround time’, it’s time for our new term ‘Fairness’.
So, what does ‘Fairness’ in terms of Scheduling means. Here, the term ‘Fairness’ means increasing performance by running one process/job to its fullest and restricting others.





Monday 13 April 2015

First Video

Here is the video of the first post i.e. The Compilation Process, hope everybody like it.

Please give any suggestions if you have. Like and comment.

Here's the link:-

https://www.youtube.com/watch?v=3_zh7iGUHG0


and here is my channel:-

https://www.youtube.com/channel/UCT-PXnXV-XYnkUt6c6VcLCw

Sunday 12 April 2015

Survey

Hey Guys Please participate in my survey:-

http://freeonlinesurveys.com/app/showpoll.asp?qid=650541&sid=hjsuez974kbrfyl650541&new=True

Please share any ideas if you have.

Tuesday 7 April 2015

The Compilation Process

Compilation process is a sophisticated and a bit large process as it involves many things like:-

1)Pre-processing- In this step any pre-processing directories are included with hash tag include i.e. #include.

2)Parsing- An 'Internal representation' of code is prepared by gcc.

3)Static Changes- The compiler checks whether the declarations are right or not. Any errors found here are termed as "semantic errors".

4)Code Generation- "Internal representation " as done in step three is converted into byte code by the gcc compiler.

5)Linking- Any file or code that has to be linked to the file is linked here

6)Optimization- Small changes are done to free up space and reduce the time involved in compilation process. We will get in detail at this topic later on.

Compilation process has many advantages like knowing the compilation process helps you debug your code, optimize it , make it neater.

Here are the slides for this Post:-

https://docs.google.com/presentation/d/1VZEJo1Hh8zMR6eQcbo5OctPdzylvoaJ1MXYcvob5Msw/edit?usp=sharing

Saturday 4 April 2015

Compilation

Compiled and Interpreted languages

Programming languages are of basically two types i.e. either Compiled or Interpreted. 
We will discuss the characterstics of both one by one. Let's Start.

1)Compiled Languages:- These type of languages are first converted into machine code and then executed by hardware. For eg:- C.

2)Interpreted Languages:- These type of languages are executed by interpreter line by line.
For eg:-Phython.

but being compiled or interpreted is not an integrated characterstics of a languages as Compile languages like C may have interpreters and Interpreted languages may have compilers.