This chapter provides an overall view of the Cell Programming Tutorial.
This tutorial is intended for use by programmers with the knowledge described below.
Oriented in a practical way, with working examples and lessons, this tutorial helps programmers develop programs that can get the most out of the Cell’s distinctive computational capability. It will benefit those people who are:
(1) Interested in programming for the Cell
(2) Planning to migrate existing programs to the Cell
This tutorial focuses on the unique aspects of Cell programming. The basics of programming are outside the scope of this document. Readers should be familiar with:
(1) C-language programming
(2) Basic concept of parallel programming
(3) Program development procedures on Linux
Part of the program development procedures will be explained if it is unique to the Cell. Again, however, general information, such as that on the use of editors, is not included. For details of the C language and Linux commands, refer to their own manuals and treatises.
Each chapter of this tutorial has a specific learning theme to make it easy to acquire necessary knowledge and programming techniques. For first-time learners, we recommend starting with Chapter 1 and continuing in the order presented to better understand the subject.
This tutorial is composed of 4 chapters.
Chapter 1 Basics of Cell Architecture
Describes the architecture of the Cell. The reader can learn about the unique features of both the hardware and software utilized in the Cell.
Chapter 2 Basics of SIMD Programming
Focuses on SIMD operations which enable processing of multiple data with a single instruction. The reader can learn the basics of this concurrent processing method, as well as the SIMD processing architecture on the Cell.
Chapter 3 Basics of SPE Programming
Explains programming using the Cell-unique processor cores called SPEs. The reader can learn how to execute programs on the SPEs and how to task decomposition to multiple SPEs.
Chapter 4 Advanced Cell Programming
Presents information on advanced Cell programming. The reader can learn techniques to improve performance. Useful tips on Cell programming that have not been discussed in previous chapters are also included.
This tutorial is centered around the fundamentals of Cell programming. Refer to the bibliography if it is necessary to find out more about Cell programming.
From Chapter 2 on, this tutorial focuses on developing programming skills. Each chapter covers a specific theme and is divided into sections to explain the theme using sample programs. At the end of each chapter, practice questions are provided for review of the content learned.
The following software documentation conventions are used in this tutorial.
(1) Program code for PPE (written in blue, font: Courier New)
#include <stdio.h>
int main(int argc, char **argv) { return 0; } |
(2) Program code for SPE (written in green, font: Courier New)
#include <stdio.h>
int main(unsigned long long spu_id, unsigned long long arg_ea) { retrun 0; } |
(2) Shell command (written in bold type, font: Arial Bold, spu_gcc)
The spu_gcc command is used to compile SPE programs. |
(3) Function (written in bold type, font: Times New Roman Bold, spu_open_image())
The function spu_open_image() is used to read SPE program files. |
(4) Type/Variable (written in italic type, font: Times New Roman Italic, vector signed int)
vector signed int can store four unsigned integers. The variable vc is a sum of variables va and vb. |