assign1

Course: CS 571, Spring 2008
School: George Mason
Rating:
 
 
 
 
 

Word Count: 237

Document Preview

MASON GEORGE UNIVERSITY DEPARTMENT OF COMPUTER SCIENCE CS 571 OPERATING SYSTEMS Fall 2002 Assignment 1: DUE Sept 10 Experiment 1. Thread and Process Creation Study the programs thr_create.c and fork.c. Compile and execute the programs. These programs measure the average time to create a thread using thr_create and to create a process using fork. What do you conclude from this experiment? Briey describe the...

Register Now

Unformatted Document Excerpt

Coursehero >> Virginia >> George Mason >> CS 571

Course Hero has millions of student submitted documents similar to the one
below including study guides, practice problems, reference materials, practice exams, textbook help and tutor support.

Course Hero has millions of student submitted documents similar to the one below including study guides, practice problems, reference materials, practice exams, textbook help and tutor support.
MASON GEORGE UNIVERSITY DEPARTMENT OF COMPUTER SCIENCE CS 571 OPERATING SYSTEMS Fall 2002 Assignment 1: DUE Sept 10 Experiment 1. Thread and Process Creation Study the programs thr_create.c and fork.c. Compile and execute the programs. These programs measure the average time to create a thread using thr_create and to create a process using fork. What do you conclude from this experiment? Briey describe the reasons for the difference in timings. Experiment 2. Processes vs Threads Study the two programs thr_shared.c and proc_shared.c. Compile and execute the programs. These programs are identical except that one uses threads and the other uses processes. What do you conclude from this experiment? Explain the reason for the difference in Experiment behavior. 3: The Lost Update Problem Study the program shared_data.c. Compile and execute it. The main thread and the child thread are both updating (i.e., modifying) the shared variable shared_number. Is the program behaving correctly? What do you conclude from this experiment? NOTES 1. All these programs are available from the web page with URL http://cs.gmu.edu/setia/cs571/assignments/assign1. These programs have been tested on S...

Find millions of documents on Course Hero - Study Guides, Lecture Notes, Reference Materials, Practice Exams and more. Course Hero has millions of course specific materials providing students with the best way to expand their education.

Below is a small sample set of documents:

George Mason - CS - 571
Operating Systems CS 571Prof. Sanjeev Setia Fall 20021Overview Prerequisites Computer Architecture (CS 365) Data structures and programming (CS 310) (C+/C/Java progamming) Textbooks Modern Operating Systems (Tannenbaum) Distributed System
George Mason - CS - 2
GEORGE MASON UNIVERSITY Computer Science Department CS 571 Operating Systems Fall 2002 Assignment 2 Multithreaded Programming DUE DATE Oct 1Process Synchronization The goal of this exercise to give you some experience writing concurrent programs.
George Mason - CS - 571
GEORGE MASON UNIVERSITY Computer Science Department CS 571 Operating Systems Fall 2002 Assignment 2 Multithreaded Programming DUE DATE Oct 1Process Synchronization The goal of this exercise to give you some experience writing concurrent programs.
George Mason - CS - 571
Time and Coordination in Distributed SystemsOperating Systems1Clock SynchronizationPhysical clocks drift, therefore need for clock synchronization algorithmsMany algorithms depend upon clock synchronization Often we need to know the order in
George Mason - CS - 571
BackgroundConcurrent access to shared data may result in data inconsistency. Maintaining data consistency requires mechanisms to ensure the orderly execution of cooperating processes. Bounded Buffer problem (also called producer consumer problem)1
George Mason - CS - 571
Distributed File SystemsOperating Systems1Distributed-File Systems Background Naming and Transparency Remote File Access Stateful versus Stateless Service File Replication Example Systems NFS AFS DFS project21Background Distribu
George Mason - CS - 571
Communication in distributed systems: network programming using sockets Operating SystemsTCP/IP layersLayers ApplicationMessageMessages (UDP) or Streams (TCP) Transport UDP or TCP packets Internet IP datagrams Network interface Network-specif
George Mason - CS - 571
Figure 5.5C program for client in Sun RPC./* File : C.c - Simple client of the FileReadWrite service. */ #include <stdio.h> #include <rpc/rpc.h> #include "FileReadWrite .h" main(int argc, char * argv) { CLIENT *clientHandle; char *serverName = "co
George Mason - CS - 3
GEORGE MASON UNIVERSITY Computer Science Department CS 571 Operating Systems Fall 2002 Assignment 3 Client-Server Programming using Sockets and RPC/RMI DUE DATE Oct 221. Implementing an arithmetic server using sockets Write a program with two par
George Mason - CS - 571
GEORGE MASON UNIVERSITY Computer Science Department CS 571 Operating Systems Fall 2002 Assignment 3 Client-Server Programming using Sockets and RPC/RMI DUE DATE Oct 221. Implementing an arithmetic server using sockets Write a program with two par
George Mason - CS - 3
GEORGE MASON UNIVERSITY Computer Science Department CS 571 Operating Systems Assignment 3 Client-Server Programming using Sockets and RPC/RMI1. Implementing an arithmetic server using sockets Write a program with two parts: 1) a client, and 2) an
George Mason - CS - 571
GEORGE MASON UNIVERSITY Computer Science Department CS 571 Operating Systems Assignment 3 Client-Server Programming using Sockets and RPC/RMI1. Implementing an arithmetic server using sockets Write a program with two parts: 1) a client, and 2) an
George Mason - CS - 2
GEORGE MASON UNIVERSITY Computer Science Department CS 571 Operating Systems Fall 2003 Assignment 2 Multithreaded Programming DUE DATE Oct 6Process Synchronization The goal of this exercise to give you some experience writing concurrent programs.
George Mason - CS - 571
GEORGE MASON UNIVERSITY Computer Science Department CS 571 Operating Systems Fall 2003 Assignment 2 Multithreaded Programming DUE DATE Oct 6Process Synchronization The goal of this exercise to give you some experience writing concurrent programs.
George Mason - CS - 367
Chapter 4 The Von Neumann ModelACKNOWLEDGEMENT: This lecture uses slides prepared by Gregory T. Byrd, North Carolina State University4-21The Stored Program Computer1943: ENIAC Presper Eckert and John Mauchly - first general electronic compu
George Mason - CS - 367
Bitwise OperatorsSymbol ~ < > & ^ | Operation bitwise NOT left shift right shift bitwise AND bitwise XOR bitwise OR Usage ~x x < y x > y x & y x ^ y x | yPrecedence 4 8 8 11 12 13 Assoc r-to-l l-to-r l-to-r l-to-r l-to-r l-to-rOperate on variable
George Mason - CS - 365
Ch 5: Designing a Single Cycle DatapathComputer Systems Architecture CS 365The Big Picture: Where are We Now? The Five Classic Components of a ComputerProcessor Input Control Memory Datapath Output Today Topic: Design a Single Cycle Processo
George Mason - CS - 818
Privacy and Security in library RFID Issues, Practices and ArchitectureDavid Molnar and David Wagner University of California, BerkeleyCCS '04 October 2004OverviewMotivation RFID Background Library RFID IssuesCurrent Architectures, Atta
George Mason - CS - 580
T R E N D S&C O N T R O V E R S I E SPlaying with AIThe use of puzzles and games in AI research dates to its earliest days. In the early 1950s, Claude Shannon and Alan Turing wrote papers proposing the creation of computer programs that could
George Mason - CS - 803
Data-Hiding CodesPIERRE MOULIN, FELLOW, IEEE, AND RALF KOETTER, MEMBER, IEEE Invited PaperThis tutorial paper reviews the theory and design of codes for hiding or embedding information in signals such as images, video, audio, graphics, and text. S
George Mason - CS - 682
CS 682: Computer VisionDr. Zoran DuricCS Dept. GMUJanuary 27, 2009Oce: S&T II, Rm. 427 email: zduric@cs.gmu.edu Oce Hours: Tue. 2:00-4:00pm, Thu 1:30-2:30pm or by app. URL: http:/www.cs.gmu.edu/zduric/ Course: http:/www.cs.gmu.edu/zduric/cs682.
George Mason - CS - 580
CS 580'$1Introduction to Articial Intelligence: cs580Dr. Zoran Duric Oce: S&T II, Rm. 427 email: zduric@cs.gmu.edu Oce Hours: Tue. 2:00-4:00pm or by app. URL: http:/www.cs.gmu.edu/zduric/ Course: http:/www.cs.gmu.edu/zduric/cs580.html&%
George Mason - CS - 580
LispLisp: Question 1Write a recursive lisp function that takes a list as an argument and returns the number of atoms on any level of the list. For instance, list (A B (C D E ) () contains six atoms (A, B, C , D, E , and NIL). (defun count-atoms (
George Mason - CS - 580
'$Intelligent AgentsChapter 2&1%'$Outline Agents and environments Rationality PEAS (Performance measure, Environment, Actuators, Sensors) Environment types Agent types&2%'$Agents and environmentssensors percepts envi
George Mason - CS - 580
X X X X X1/ 10 Dr. Zoran Duric (CS Dept., GMU)MAX nodes MIN nodesXStart nodeAlpha-Beta Pruning ExampleAlpha-Beta Pruning(Backed-up value = +1)XX X X 1998 Morgan Kaufman PublishersMidterm Review 3XX X2 +2 3 +3 1 1 +1 +5 +4 +1
George Mason - CS - 682
Projectss s sSummarizing videossSummarizing videos Find image copies Detecting motion patterns in surveillance videoss sUse edge and flow histograms as image descriptors to summarize videos Use k-means to find sub-sequence center frames Tes
George Mason - CS - 112
Pickling and ShelvesDan FleckComing up: What is pickling?What is pickling?Pickling - is the process of preserving food by anaerobic fermentation in brine (a solution of salt in water), to produce lactic acid, or marinating and storing it in an
George Mason - CS - 112
CS 112 Lab AssignmentInstructor: Dan Fleck Lab: 401K MathOverviewThis lab will help you understand the mathematical operators in Python and how to get user input. Additionally, it will show you the financial benefits of a 401(k) program, and why
George Mason - CS - 112
CS 112 Lab AssignmentInstructor: Dan Fleck Lab: Web Favorites (to learn how to create and use Classes) Due Date: As with all labs, this lab is due one week from your lab section!OverviewThis lab will familiarize you with creating and using Classe
George Mason - CS - 112
Python Programming: An Introduction To Computer ScienceChapter 8 BooleansComing up: Computing with Booleans1Computing with Booleans!if and while both use Boolean expressions. ! Boolean expressions evaluate to True or False. ! So far weve used
George Mason - CS - 112
Python Programming: An Introduction to Computer ScienceChapter 4 (End of Chapter) File IOComing up: File Processing1File Processing! The process of opening a file involves associating a file on disk with a variable. ! We can manipulate the fi
George Mason - CS - 112
Creating a large GUI ProgramDan Fleck Spring 2007Coming up: Hangman yes again!Hangman yes again!! Lets say we want to create a more fun, graphical version of our Hangman game. This is alarger program and we will follow the Software Developmen
George Mason - CS - 112
The Software Development Process Python Programming: An Introduction to Computer Science Chapter 2 Dan Fleck The process of creating a program is often broken down into stages according to the information that is produced in each phase.Coming up:
George Mason - CS - 112
Passing a function as a parameter and How NOT to do menusDan FleckComing up: Passing Functions as ParametersPassing Functions as Parameters You have seen in GUI programming that Buttons (for example) allow you to pass a function to the button t
George Mason - CS - 112
Objectives Python Programming: An Introduction to Computer ScienceChapter 3 Computing with Numbers Updated by Dan FleckComing up: Objectives 1 Coming up: Numeric Data Types 2 To understand the concept of data types. To be familiar with the basic
George Mason - CS - 112
The Function of Functions Python Programming: An Introduction to Computer ScienceChapter 6 Functions,Variables,Modules Why use functions at all? Reduces duplicate code (Less maintenance, debugging, etc) Makes programs easier to read Makes progra
George Mason - CS - 112
The String Data Type Python Programming: An Introduction to Computer ScienceChapter 4 Computing with Strings The most common use of personal computers is word processing. Text is represented in programs by the string data type. A string is a sequ
George Mason - CS - 112
Debugging & Errors Why you were up till 2AMDan Fleck Fall 2008Coming up: Running programs from the command lineRunning programs from the command lineIn windows just double-click on the sliders.py le In Unix/Mac (or Windows also) run the command
George Mason - CS - 112
Sorting and ComparatorsDan FleckComing up: Sorting a listSorting a list! Sorting a list seems simple: myList = [1, 4, 3, 5] myList.sort() print myList > [1, 3, 4, 5] Backwards? Not so hard reallyOkay, how about backwards then!! A little hard
George Mason - CS - 112
Exception HandlingDan FleckComing up: Long ago we wrote thisLong ago we wrote thisdef addGraphicalButton(parent): # Create the PhotoImage widget im = PhotoImage(file='cake.gif') button2 = Button(root, text="Potato", image=im) button2.image = im
George Mason - CS - 112
Python Programming: An Introduction To Computer ScienceChapter 10 Defining Classes (These slides were heavily editted/ rewritten by Dan Fleck)Coming up: Objectives 1Objectives! To appreciate how defining new classes can provide structure for a c
George Mason - CS - 112
Python Programming: An Introduction to Computer ScienceChapter 1 Computers and Programs Modified by Dan FleckObjectives Introduction to the class Why we program and what that means Introduction to the Python programming languageComing up: Wha
George Mason - CS - 112
Tkinter GUIs in PythonDan Fleck CS112 George Mason UniversityNOTE: This information is not in your textbook! See references for more information!Coming up: What is it?What is it?! Tkinter is a Python interface to the Tk graphics library.!Tk i
George Mason - CS - 112
New Datatypes:Tuples and SetsDan FleckComing up: Passing a list as a parameterPassing a list as a parameterdef class FamilyTree:# This class holds a list of family members in the variable tree lots of code not shown def getTree(self): retur
George Mason - CS - 112
CS 112 Lab AssignmentInstructor: Dan Fleck Lab: Pig Latin TranslatorOverviewThis lab will familiarize you with the String class and String functions available in Python. You will be ask the user for a word and convert it into PigLatin. Pig Latin
George Mason - CS - 112
CS 112 Lab AssignmentInstructor: Dan Fleck Lab: Graphics Due Date: SPECIAL ALERT: This lab (and ONLY this lab) will be due on April 14th at midnight for EVERYONE. Just this once well have a longer due date for people because of the midterm the week
George Mason - CS - 112
CS 112 Lab AssignmentInstructor: Dan Fleck Lab: Software design and documentation Due Date: As with all labs, this lab is due one week from your lab section!OverviewThroughout the semester you have hopefully been writing pseudocode and adding goo
George Mason - CS - 112
CS 112 Lab AssignmentInstructor: Dan Fleck Lab: #1OverviewThis lab will help you familiarize yourself with Python, the computer lab and Blackboard. For this lab you will do two things: 1. Type in and run a simple Python file 2. Submit that file a
George Mason - CS - 112
CS 112 Lab AssignmentInstructor: Dan Fleck Lab: For Loops (and a little math)OverviewThis lab will help you understand how to use for loops. You will compute an estimated value for the square root of a number to a specific accuracy given from the
George Mason - CS - 112
CS 112 Project Assignment: SlidersInstructor: Dan FleckOverviewIn this project you will use Python to implement the number sliders game. This game can be seen at: http:/www.classbrain.com/artgames/publish/sliders_game.shtml You will only be imple
George Mason - CS - 540
Building SLR Parse TablesThe easiest technique for generating LR-based parse table is known as SLR (Simple LR). Understanding this technique should provide you with what you need to know to understand how LR parsers work in general; it is also the f
George Mason - CS - 367
Introduction to CAcknowledgement: These slides are adapted from lecture slides made available by Prof. Dave O Halloran (Carnegie Mellon University)Outline Overview comparison of C and Java Good evening Preprocessor Command line arguments Arr
George Mason - CS - 707
Assignment #2 - Auction ToolDue April 12IntroductionThe goal of this assignment is to introduce you to the use of a distributed object middleware such as CORBA or Java RMI to build a distributed auction tool. This tool will allow users to create
George Mason - CS - 640
SPECIALISSUEArticlesADVANCED COMPILER OPTIMIZATIONS FOR SUPERCOMPUTERSCompilers for vector or multiprocessor computers must have certain optimization features to successfully generate parallel code.DAVID A. PADUA and MICHAEL J. WOLFESuperco
George Mason - CS - 640
REGISTER ALLOCATION & SPILLING VIA GRAPH COLORING G. J. Chaitin IBM Research P.O.Box 218, Yorktown Heights, NY 10598ABSTRACT In a previous paper we reported the successful use of graph coloring techniques for doing global register allocation in an
George Mason - CS - 367
Programming in C in a UNIX environmentSoftware Development LifecycleUnderstand the requirements Develop the algorithm/approach Write the code Debug the code Test the code Iterate until you get it right2Programming ToolsSeveral Integrated Deve
George Mason - CS - 640
Improvements to Graph Coloring Register AllocationPRESTON BRIGGS, KEITH D. COOPER, and LINDA TORCZON Rice UniversityWe describeopttmzstwtwo improvements to Chaitin-style graph coloring register allocators. The first, uses a stronger heuristic t
George Mason - CS - 640
CS 640 HW #1 Fall 2008 Due Sept 22 at classtime1. For the code below, what optimizations can be detected using Local Value Numbering? What about DAG construction? a = 2 b = 3 c = a + b d = a + a b = a e = a + b c = 3 f = a + c 2. In order to do supe
George Mason - CS - 640
Redundant Expression EliminationCS640 Lecture 3Redundant ExpressionstDefinitionrAn expression x op y is redundant at a point p if it has already been computed and no intervening operations redefined x or y Preserve the result of earlier comp
George Mason - CS - 640
CS640Advanced CompilersInstructor: Elizabeth Whitewhite@gmu.eduAbout the CourseInstructor: Dr. Elizabeth WhiteEmail: white@gmu.edu Office: STII 429 Office hour:Mon/Wed 2-3 By appointmentCourse web site:http:/cs.gmu.edu/~white/CS640 Check
George Mason - CS - 707
ProcessesCh. 1, 3 Tanenbaum Distributed Software Systems CS 707Software ArchitectureComponents/processesprocess = program in execution Often multi-threaded! How the processes are organized influences the overall applicationConnections between