{"id":3324,"date":"2025-06-06T03:49:17","date_gmt":"2025-06-06T03:49:17","guid":{"rendered":"https:\/\/diznr.com\/?p=3324"},"modified":"2025-06-06T03:49:17","modified_gmt":"2025-06-06T03:49:17","slug":"day-01part-04-operating-sysytem-for-computer-who-executes-the-program-and-where-program-resides-is","status":"publish","type":"post","link":"https:\/\/www.reilsolar.com\/pdf\/day-01part-04-operating-sysytem-for-computer-who-executes-the-program-and-where-program-resides-is\/","title":{"rendered":"Day 01Part 04- Operating sysytem for computer-Who executes the Program and where program is resides."},"content":{"rendered":"<p>Day 01Part 04- Operating sysytem for computer-Who executes the Program and where program is resides.<\/p>\n<p>[fvplayer id=&#8221;353&#8243;]<\/p>\n<h3 data-start=\"0\" data-end=\"56\"><strong data-start=\"2\" data-end=\"54\">Operating System for Computers \u2013 Day 01, Part 04<\/strong><\/h3>\n<h3 data-start=\"57\" data-end=\"126\"><strong data-start=\"61\" data-end=\"124\">Who Executes the Program and Where Does the Program Reside?<\/strong><\/h3>\n<h3 data-start=\"128\" data-end=\"152\"><strong data-start=\"131\" data-end=\"150\">\u00a0Introduction<\/strong><\/h3>\n<p data-start=\"153\" data-end=\"405\">A <strong data-start=\"155\" data-end=\"166\">program<\/strong> is a set of instructions written to perform a specific task. To execute a program, the <strong data-start=\"254\" data-end=\"279\">Operating System (OS)<\/strong> manages its loading, execution, and termination. But where does a program reside, and who executes it? Let\u2019s break it down.<\/p>\n<h3 data-start=\"412\" data-end=\"452\"><strong data-start=\"415\" data-end=\"450\">\u00a0Where Does a Program Reside?<\/strong><\/h3>\n<h3 data-start=\"454\" data-end=\"518\"><strong data-start=\"460\" data-end=\"516\">1. Storage (Secondary Memory &#8211; Hard Disk, SSD, etc.)<\/strong><\/h3>\n<p data-start=\"519\" data-end=\"715\"><strong data-start=\"522\" data-end=\"616\">Before execution, a program is stored in secondary memory (HDD, SSD, or external storage).<\/strong><br data-start=\"616\" data-end=\"619\" \/>\u00a0Example: Applications like MS Word, Chrome, or a game are stored as files on the hard disk.<\/p>\n<h3 data-start=\"722\" data-end=\"794\"><strong data-start=\"728\" data-end=\"792\">2. RAM (Primary Memory &#8211; Temporary Storage During Execution)<\/strong><\/h3>\n<p data-start=\"795\" data-end=\"1057\"><strong data-start=\"798\" data-end=\"878\">When a user runs a program, the OS loads it from secondary storage into RAM.<\/strong><br data-start=\"878\" data-end=\"881\" \/><strong data-start=\"884\" data-end=\"892\">Why?<\/strong> Because <strong data-start=\"901\" data-end=\"923\">RAM is much faster<\/strong> than a hard drive and provides quick access for the CPU.<br data-start=\"980\" data-end=\"983\" \/>\u00a0Example: When you open a browser, the program moves from disk to RAM.<\/p>\n<h3 data-start=\"1064\" data-end=\"1112\"><strong data-start=\"1070\" data-end=\"1110\">3. CPU Cache (Temporary Fast Memory)<\/strong><\/h3>\n<p data-start=\"1113\" data-end=\"1288\">\u00a0Some frequently used instructions are stored in <strong data-start=\"1164\" data-end=\"1177\">CPU Cache<\/strong> to speed up execution.<br data-start=\"1200\" data-end=\"1203\" \/><strong data-start=\"1206\" data-end=\"1214\">Why?<\/strong> Cache memory is <strong data-start=\"1231\" data-end=\"1241\">faster<\/strong> than RAM and reduces the CPU&#8217;s waiting time.<\/p>\n<h3 data-start=\"1295\" data-end=\"1332\"><strong data-start=\"1298\" data-end=\"1330\">\u00a0Who Executes the Program?<\/strong><\/h3>\n<h3 data-start=\"1334\" data-end=\"1406\"><strong data-start=\"1340\" data-end=\"1404\">1. CPU (Central Processing Unit &#8211; The Brain of the Computer)<\/strong><\/h3>\n<p data-start=\"1407\" data-end=\"1600\">\u00a0The CPU <strong data-start=\"1418\" data-end=\"1452\">fetches, decodes, and executes<\/strong> instructions of a program.<br data-start=\"1479\" data-end=\"1482\" \/>\u00a0The <strong data-start=\"1489\" data-end=\"1510\">Control Unit (CU)<\/strong> directs the operation, while the <strong data-start=\"1544\" data-end=\"1575\">Arithmetic Logic Unit (ALU)<\/strong> performs calculations.<\/p>\n<h3 data-start=\"1607\" data-end=\"1658\"><strong data-start=\"1613\" data-end=\"1656\">2. Operating System\u2019s Role in Execution<\/strong><\/h3>\n<p data-start=\"1659\" data-end=\"1914\">\u00a0The <strong data-start=\"1666\" data-end=\"1690\">OS acts as a manager<\/strong>, handling:<br data-start=\"1701\" data-end=\"1704\" \/><strong data-start=\"1706\" data-end=\"1728\">Process scheduling<\/strong> \u2013 Decides which program runs and for how long.<br data-start=\"1775\" data-end=\"1778\" \/><strong data-start=\"1780\" data-end=\"1801\">Memory management<\/strong> \u2013 Allocates RAM to active programs.<br data-start=\"1837\" data-end=\"1840\" \/><strong data-start=\"1842\" data-end=\"1865\">Resource allocation<\/strong> \u2013 Assigns CPU, disk, and input\/output devices.<\/p>\n<h3 data-start=\"1921\" data-end=\"1963\"><strong data-start=\"1924\" data-end=\"1961\">\u00a0Step-by-Step Execution Process<\/strong><\/h3>\n<p data-start=\"1965\" data-end=\"2289\"><strong data-start=\"1969\" data-end=\"2002\">User clicks to open a program<\/strong> (e.g., a browser).<br data-start=\"2021\" data-end=\"2024\" \/><strong data-start=\"2028\" data-end=\"2079\">The OS loads the program from storage into RAM.<\/strong><br data-start=\"2079\" data-end=\"2082\" \/><strong data-start=\"2086\" data-end=\"2128\">CPU fetches and processes instructions<\/strong> from RAM.<br data-start=\"2138\" data-end=\"2141\" \/><strong data-start=\"2145\" data-end=\"2218\">Execution continues until the program is closed or task is completed.<\/strong><br data-start=\"2218\" data-end=\"2221\" \/><strong data-start=\"2225\" data-end=\"2249\">The OS clears memory<\/strong> after execution to free up resources.<\/p>\n<h3 data-start=\"2296\" data-end=\"2318\"><strong data-start=\"2299\" data-end=\"2316\">Conclusion<\/strong><\/h3>\n<p data-start=\"2319\" data-end=\"2556\"><strong data-start=\"2321\" data-end=\"2405\">Programs reside in secondary storage (HDD\/SSD) and move to RAM during execution.<\/strong><br data-start=\"2405\" data-end=\"2408\" \/><strong data-start=\"2410\" data-end=\"2467\">The CPU executes the program with the help of the OS.<\/strong><br data-start=\"2467\" data-end=\"2470\" \/><strong data-start=\"2472\" data-end=\"2554\">The OS plays a crucial role in managing memory, CPU scheduling, and execution.<\/strong><\/p>\n<p data-start=\"2558\" data-end=\"2642\" data-is-last-node=\"\" data-is-only-node=\"\">\u00a0<strong data-start=\"2561\" data-end=\"2642\" data-is-last-node=\"\">Want to learn more about process management or scheduling in OS? Let me know!<\/strong><\/p>\n<h3 data-start=\"2558\" data-end=\"2642\"><a href=\"https:\/\/www.cl.cam.ac.uk\/teaching\/1011\/OpSystems\/os1a-slides.pdf\" target=\"_blank\" rel=\"noopener\">Day 01Part 04- Operating sysytem for computer-Who executes the Program and where program is resides.<\/a><\/h3>\n<h3 class=\"LC20lb MBeuO DKV0Md\"><a href=\"https:\/\/prathyusha.edu.in\/wp-content\/uploads\/2023\/11\/OPERATING-SYSTEM-1.pdf\" target=\"_blank\" rel=\"noopener\">iv semester cs3451-introduction to operating systems<\/a><\/h3>\n<h3 class=\"LC20lb MBeuO DKV0Md\"><a href=\"https:\/\/ncert.nic.in\/vocational\/pdf\/keit102.pdf\" target=\"_blank\" rel=\"noopener\">Installation and Configuration of Operating System<\/a><\/h3>\n<h3 class=\"LC20lb MBeuO DKV0Md\"><a href=\"https:\/\/aits-tpt.edu.in\/wp-content\/uploads\/2022\/06\/Operating_System-min.pdf\" target=\"_blank\" rel=\"noopener\">UNIT-I Operating Systems Functions<\/a><\/h3>\n<h3 class=\"LC20lb MBeuO DKV0Md\"><a href=\"https:\/\/mu.ac.in\/wp-content\/uploads\/2020\/12\/Operating-System.pdf\" target=\"_blank\" rel=\"noopener\">Operating-System.pdf<\/a><\/h3>\n<p data-start=\"0\" data-end=\"162\">Here\u2019s a clear explanation for <strong data-start=\"31\" data-end=\"69\">Operating System \u2013 Day 01, Part 04<\/strong>, covering <strong data-start=\"80\" data-end=\"106\">who executes a program<\/strong> and <strong data-start=\"111\" data-end=\"140\">where the program resides<\/strong> in a computer system:<\/p>\n<hr data-start=\"164\" data-end=\"167\" \/>\n<h2 data-start=\"169\" data-end=\"223\">\ud83d\udda5\ufe0f <strong data-start=\"176\" data-end=\"223\">Operating System Basics \u2013 Program Execution<\/strong><\/h2>\n<h3 data-start=\"225\" data-end=\"261\">\ud83d\udd04 <strong data-start=\"232\" data-end=\"261\">Who Executes the Program?<\/strong><\/h3>\n<p data-start=\"263\" data-end=\"344\"><strong data-start=\"263\" data-end=\"300\">The CPU (Central Processing Unit)<\/strong> is responsible for executing the program.<\/p>\n<ul data-start=\"345\" data-end=\"513\">\n<li data-start=\"345\" data-end=\"408\">\n<p data-start=\"347\" data-end=\"408\">It <strong data-start=\"350\" data-end=\"361\">fetches<\/strong>, <strong data-start=\"363\" data-end=\"374\">decodes<\/strong>, and <strong data-start=\"380\" data-end=\"392\">executes<\/strong> instructions.<\/p>\n<\/li>\n<li data-start=\"409\" data-end=\"513\">\n<p data-start=\"411\" data-end=\"513\">The <strong data-start=\"415\" data-end=\"440\">Operating System (OS)<\/strong> manages the CPU&#8217;s scheduling and decides which program gets to run next.<\/p>\n<\/li>\n<\/ul>\n<hr data-start=\"515\" data-end=\"518\" \/>\n<h3 data-start=\"520\" data-end=\"561\">\ud83d\udccd <strong data-start=\"527\" data-end=\"561\">Where Does the Program Reside?<\/strong><\/h3>\n<p data-start=\"563\" data-end=\"685\">Programs <strong data-start=\"572\" data-end=\"616\">initially reside on the hard disk or SSD<\/strong>, but to be executed, they must be <strong data-start=\"651\" data-end=\"684\">loaded into main memory (RAM)<\/strong>.<\/p>\n<p data-start=\"687\" data-end=\"697\"><strong data-start=\"687\" data-end=\"697\">Steps:<\/strong><\/p>\n<ol data-start=\"698\" data-end=\"859\">\n<li data-start=\"698\" data-end=\"764\">\n<p data-start=\"701\" data-end=\"764\">Program stored on storage device (e.g., <code data-start=\"741\" data-end=\"747\">.exe<\/code> file on HDD\/SSD)<\/p>\n<\/li>\n<li data-start=\"765\" data-end=\"801\">\n<p data-start=\"768\" data-end=\"801\">OS loads the program into <strong data-start=\"794\" data-end=\"801\">RAM<\/strong><\/p>\n<\/li>\n<li data-start=\"802\" data-end=\"859\">\n<p data-start=\"805\" data-end=\"859\">CPU fetches instructions from RAM and begins execution<\/p>\n<\/li>\n<\/ol>\n<hr data-start=\"861\" data-end=\"864\" \/>\n<h3 data-start=\"866\" data-end=\"888\">\ud83d\udd27 <strong data-start=\"873\" data-end=\"888\">In Summary:<\/strong><\/h3>\n<ul data-start=\"889\" data-end=\"1093\">\n<li data-start=\"889\" data-end=\"934\">\n<p data-start=\"891\" data-end=\"934\"><strong data-start=\"891\" data-end=\"912\">Storage (HDD\/SSD)<\/strong>: Long-term location<\/p>\n<\/li>\n<li data-start=\"935\" data-end=\"990\">\n<p data-start=\"937\" data-end=\"990\"><strong data-start=\"937\" data-end=\"958\">Main Memory (RAM)<\/strong>: Temporary execution location<\/p>\n<\/li>\n<li data-start=\"991\" data-end=\"1036\">\n<p data-start=\"993\" data-end=\"1036\"><strong data-start=\"993\" data-end=\"1000\">CPU<\/strong>: Executes instructions one by one<\/p>\n<\/li>\n<li data-start=\"1037\" data-end=\"1093\">\n<p data-start=\"1039\" data-end=\"1093\"><strong data-start=\"1039\" data-end=\"1045\">OS<\/strong>: Manages loading, memory, and execution control<\/p>\n<\/li>\n<\/ul>\n<hr data-start=\"1095\" data-end=\"1098\" \/>\n<p data-start=\"1100\" data-end=\"1217\" data-is-last-node=\"\" data-is-only-node=\"\">Would you like a <span class=\"decoration-token-text-secondary hover:text-token-text-secondary cursor-pointer underline decoration-dotted decoration-[12%] underline-offset-4 transition-colors duration-200 ease-in-out\">diagram of this flow<\/span>, <span class=\"decoration-token-text-secondary hover:text-token-text-secondary cursor-pointer underline decoration-dotted decoration-[12%] underline-offset-4 transition-colors duration-200 ease-in-out\">step-by-step execution example<\/span>, or <span class=\"decoration-token-text-secondary hover:text-token-text-secondary cursor-pointer underline decoration-dotted decoration-[12%] underline-offset-4 transition-colors duration-200 ease-in-out\">intro to process management<\/span>?<\/p>\n<h3 data-start=\"1100\" data-end=\"1217\"><a href=\"https:\/\/www.gpsanghi.ac.in\/downloads\/files\/n6512b9003af80.pdf\" target=\"_blank\" rel=\"noopener\">Day 01Part 04- Operating sysytem for computer-Who executes the Program and where program is resides.<\/a><\/h3>\n<h3 class=\"LC20lb MBeuO DKV0Md\"><a href=\"https:\/\/sist.sathyabama.ac.in\/sist_coursematerial\/uploads\/SCS1301.pdf\" target=\"_blank\" rel=\"noopener\">I UNIT \u2013 I- SCS1301- OPERATING SYSTEM<\/a><\/h3>\n","protected":false},"excerpt":{"rendered":"<p>Day 01Part 04- Operating sysytem for computer-Who executes the Program and where program is resides. [fvplayer id=&#8221;353&#8243;] Operating System for Computers \u2013 Day 01, Part 04 Who Executes the Program and Where Does the Program Reside? \u00a0Introduction A program is a set of instructions written to perform a specific task. To execute a program, the [&hellip;]<\/p>\n","protected":false},"author":66,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[78],"tags":[],"class_list":["post-3324","post","type-post","status-publish","format-standard","hentry","category-operating-system"],"_links":{"self":[{"href":"https:\/\/www.reilsolar.com\/pdf\/wp-json\/wp\/v2\/posts\/3324","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.reilsolar.com\/pdf\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.reilsolar.com\/pdf\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.reilsolar.com\/pdf\/wp-json\/wp\/v2\/users\/66"}],"replies":[{"embeddable":true,"href":"https:\/\/www.reilsolar.com\/pdf\/wp-json\/wp\/v2\/comments?post=3324"}],"version-history":[{"count":0,"href":"https:\/\/www.reilsolar.com\/pdf\/wp-json\/wp\/v2\/posts\/3324\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.reilsolar.com\/pdf\/wp-json\/wp\/v2\/media?parent=3324"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.reilsolar.com\/pdf\/wp-json\/wp\/v2\/categories?post=3324"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.reilsolar.com\/pdf\/wp-json\/wp\/v2\/tags?post=3324"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}