








































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!









































2
4
© 2006 IBM Corporation
5
ProgrammerExperience
Dev
elopment Tools Stack
System Level Simulator
Linux PPC64 with CBE Extensions
SPE Management Lib
Samples Workloads
Demos
Code Dev Tools
Debug Tools
Performance Tools
Standards:
Language extensionsSPU ABI, Linux Reference ABI
End-UserExperience
Miscellaneous Tools
Distributed on IBM alphaworks & Barcelona Super Computer sites
Documentation
SPE Optimized Function
LIbraries
© 2006 IBM Corporation
7
Cell BE – full system simulator
Execution Environment
© 2006 IBM Corporation
8
Standard Terminal System Activity Monitors
Traces
Execution Environment
© 2006 IBM Corporation
10
Provided as patched to the 2.6.15 PPC64 Kernel
Added heterogeneous lwp/thread model
SPE thread API created (similar to pthreads library)
User mode direct and indirect SPE access models
Full pre-emptive SPE context management
spe_ptrace() added for gdb support
spe_schedule() for thread to physical SPE assignment –
SPE threads share address space with parent PPE process (through DMA)
Demand paging for SPE accesses
Shared hardware page table with PPE
PPE proxy thread allocated for each SPE thread to:
Provide a single namespace for both PPE and SPE threads
Assist in SPE initiated C99 and POSIX-1 library services
SPE Error, Event and Signal handling directed to parent PPE thread
SPE elf objects wrapped into PPE shared objects with extended gld
All patches for Cell in architecture dependent layer (subtree of PPC64)
Execution Environment
© 2006 IBM Corporation
11
Application Source
& Libraries
SPE
SPE
SPE
SPE
SPE
SPE
SPE
SPE
Cell AwareOS ( Linux)
SPE Virtualization / Scheduling Layer (m->n SPE threads)
PPE Threads, SPE Threads
SPE DMA EA = PPE Process EA Space
OS supports Create/Destroy SPE tasks
Atomic Update Primitives used for Mutex
SPE Context Fully Managed
Context Save/Restore for Debug
Virtualization Mode (indirect access)
Direct Access Mode (realtime)
OS assignment of SPE threads to SPEs
Programmer directed using affinity mask
SPE Compilers use SPE Management Lib.
© 2006 IBM Corporation
13
SPEs are exposed as threads
SPE thread model interface is similar to POSIX threads.
SPE thread consists of the local store, register file, program counter,and MFC-DMA queue.
Associated with a single Linux task.
Features include:
SPE Executable
Standalone SPE program managed by a PPE executive.
Executive responsible for loading and executing SPE program. It alsoservices assisted requests for I/O (eg, fopen, fwrite, fprintf) andmemory requests (eg, mmap, shmat, …).
Execution Environment
© 2006 IBM Corporation
14 Optimized SPE and Multimedia Extension Libraries
Execution Environment
Audio resample - resampling audio signals
FFT - 1D and 2D fft functions
gmath - mathematic functions optimized for gaming environment
image - convolution functions
intrinsics - generic intrinsic conversion functions
large-matrix - functions performing large matrix operations
matrix - basic matrix operations
mpm - multi-precision math functions
noise - noise generation functions
oscillator - basic sound generation functions
sim – simulator only function including print, profile checkpoint, socket I/O, etc …
surface - a set of bezier curve and surface functions
sync - synchronization library
vector - vector operation functions
© 2006 IBM Corporation
16
GNU gdb
PPE multithreading, SPE multithreading, interacting PPEand SPE threads
Standalone SPE debugging
Attach to SPE thread – Thread ID output when SPU_DEBUG_START=
Development Environment
© 2006 IBM Corporation
17
Static analysis (spu_timing)
Annotates assembly source with instruction pipeline state
Dynamic analysis (CBE System Simulator)
Generates statistical data on SPE execution
Cycles, instructions, and CPI
Single/Dual issue rates
Stall statistics
Register usage
Instruction histogram
pmcount
Tool to access to HW performance counters
Not currently public – being ported to oprofile interfacestandard
Development Environment
© 2006 IBM Corporation
19
cesof - the samples for the CBE embedded SPU object format usage
spu_clean - cleans the SPU register and local store
spu_entry - sample SPU entry function (crt0)
spu_interrupt - SPU first level interrupt handler sample
spulet - direct invocation of a spu program from Linux shell
sync
simpleDMA / DMA
tutorial - example source code from the tutorial
SDK test suite– 57 tests– Exercising all packages in the SDK
Execution Environment
© 2006 IBM Corporation
20
FFT16M – optimized 16 M point complex FFT
Oscillator - audio signal generator
Matrix Multiply – matrix multiplication workload
VSE_subdiv - variable sharpness subdivision algorithm
Execution Environment