MulticoreInfo.com header image 2

Writing and Optimizing Parallel Programs — A complete example

May 26th, 2011 · No Comments




by Aater Suleman, Intel
This post is a follow up on the previous post titled why parallel programming is hard. To demonstrate parallel programming, this article presents a case study of parallelizing a kernel which computes a histogram using Open MP for parallelization. The post first introduces some basic parallel programming concepts and then deep dives into performance optimizations.

Histogram Problem
Problem: Count the number of times each ASCII character occurs on a page of text.

Input: ASCII text stored as an array of characters.

Output: A histogram with 128 buckets –one for each ascii character– where each entry stores the number of occurrences of the corresponding ascii character on the page.

Full Story

  • Share/Save/Bookmark

Tags: MulticoreInfo

Like what you're reading? Come back every day for multicore news, or subscribe to RSS updates.



Stumble It!     


0 responses so far ↓

  • There are no comments yet...Kick things off by filling out the form below.

You must log in to post a comment.