Compare the performance to that obtained using regular locks

Assignment Help Basic Computer Science
Reference no: EM131091145

Write a threaded program for solving a 15-puzzle. The program takes an initial position and keeps an open list of outstanding positions. This list is sorted on the "goodness" measure of the boards. A simple goodness measure is the Manhattan distance (i.e., the sum of x -displacement and y-displacement of every tile from where it needs to be). This open list is a work queue implemented as a heap. Each thread extracts work (a board) from the work queue, expands it to all possible successors, and inserts the successors into the work queue if it has not already been encountered. Use a hash table (from Problem 7.9) to keep track of entries that have been previously encountered. Plot the speedup of your program with the number of threads. You can compute the speedups for some reference board that is the same for various thread counts.

Problem 7.9 Change the locks to read-write locks in the hash table and use write locks only when inserting an entry into the linked list. Examine the performance of this program as a function of k. Compare the performance to that obtained using regular locks.

Reference no: EM131091145

Questions Cloud

Solve a triangular system of equations of the form ux = y : Describe a pipelined algorithm for performing back-substitution to solve a triangular system of equations of the form Ux = y , where the n x n unit upper-triangular matrix U is 2-D partitioned onto an n x n mesh of processes
A professional cover letter for a potential employer : In today's technological world, it is critical to be able to introduce yourself well in writing. The way in which you present this information may be the "thing" that sets you apart from the competition.
Implement a multi-access threaded queue with multiple thread : Repeat Problem 7.2 using condition variables (in addition to mutex locks). Document the time for the same test case as above. Comment on the difference in the times.
U.s. department of education or the national education : Create one activity (to work for a group of families) that will encourage the positive relationship between an educator and a students' family. The academic activity/strategy should focus on the community as a whole and increasing the involvement ..
Compare the performance to that obtained using regular locks : Change the locks to read-write locks in the hash table and use write locks only when inserting an entry into the linked list. Examine the performance of this program as a function of k. Compare the performance to that obtained using regular locks.
Compare your performance with the previous case : Compare your performance with the previous case
The business development proposal at kids paradise : The business development proposal at kids paradise
Calculate the sound pressure level : Three small fans are located near each other at 1.5 m above the ground, and produce an annoying noise in the 250 Hz band. A localresident whose bedroom window is at the same height as the fans and is 80 m away complains about this noise. Measurements..
Building culturally responsive family-school relationships : Chapter 11: Engaging in Collaborative Problem Solving with Families. Chapter 12: Family-Centered Parent Involvement and Shared Decisions Making in Special Education Classrooms

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Who are getting advantages from piracy robberies

Why are (were) pirates difficult to eliminate? What to you believe about pirates as moder-day Robin Hoods? Who are getting advantages from piracy robberies?

  Sales force requires remote

A mobile sales force requires remote connectivity in order to access shared files and e-mail on the corporate network. All employees in the sales department have laptops equipped with ethernet adapters.

  What is the purpose of a network operations center

What is the purpose of a Network Operations Center (NOC)?Your company is using P2P technology to distribute software. Where is this software stored?Name at least three products that are often called flavors of UNIX.

  Static friction between the blocks is and between the floor

The three stone blocks have weights of WA = 600 lb WB = 150 lb , and WC = 500 lb Determine the smallest horizontal force P that must be applied to block C in order to move this block µ's = 0.3.

  The small publishing company

The small publishing company you work for wants to create a new database for storing information about all of its author contracts. What factors will influence how you design the database?

  Explain sequences of signals that occur on address bus

Explain the sequences of signals that occur on address bus, control bus, and data bus when a simple microcomputer fetches an instruction.

  A direct-mapped cache with 8 two-word blocks

Based on the following sequence of word addresses generated by the processor:1, 134, 212, 1, 135, 213, 162, 161, 2, 44, 41, 221a) Given a direct-mapped cache with 8 two-word blocks that is initially empty

  Define relevant systems analysis and design

Relevant systems analysis and design. Scholarly research should exist performed within the last few years that develop timely and appropriate procedures for an information systems analysis and design.

  Existing event research report

The Existing Event Research Report is an individual written assignment. Your Existing Event Research Report should strike a balance between description and analysis (i.e. the application of concepts learned from the lectures and text). The correct..

  What is structured data and unstructured data

Give an example of each from your experience with data that you may have used.

  Highest and lowest temperatures

Write a program that uses a two-dimensional array to store the highest and lowest temperatures for each month of the year. The program should output the average high, average low, and highest and lowest temperatures of the year. Your program must ..

  How do you solve system of linear equations by substitution

How do you solve a system of linear equations by substitution? How do you solve a system of linear equations by elimination? Give an example of each method.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd