Presentation is loading. Please wait.

Presentation is loading. Please wait.

Sunita Chandrasekaran 1 Oscar Hernandez 2 Douglas Leslie Maskell 1 Barbara Chapman 2 Van Bui 2 1 Nanyang Technological University, Singapore 2 University.

Similar presentations

Presentation on theme: "Sunita Chandrasekaran 1 Oscar Hernandez 2 Douglas Leslie Maskell 1 Barbara Chapman 2 Van Bui 2 1 Nanyang Technological University, Singapore 2 University."— Presentation transcript:

1 Sunita Chandrasekaran 1 Oscar Hernandez 2 Douglas Leslie Maskell 1 Barbara Chapman 2 Van Bui 2 1 Nanyang Technological University, Singapore 2 University of Houston, HPCTools, Texas, USA Compilation and Parallelization Techniques with Tool Support to Realize Sequence Alignment Algorithm on FPGA and Multicore

2 Challenge Application – Bioinformatics Proposed Idea Tool Support Tuning Methodology Scheduling Execution and Tuning Model Conclusion and Future Work

3 Challenge Reconfigurable Computing – Customizing a computational fabric for specific applications, e.g. FPGA (Field Programmable Gate Array) Reconfigurable Computing and HPC is a reality… Fills the gap between hardware and software FPGA based accelerators – Involving massive parallelism and extensible hardware optimizations Portions of the application can be run on reprogrammable hardware Important to identify the hot spots in the application to determine which portion to be applicable on the software and which portion on the hardware. Paper presents a tuning methodology to identify the bottlenecks in the program using a parallelizing compiler with the help of static and analysis tools

4 Application Bioinformatics – Multiple Sequence Alignment Arranging the primary sequences of DNA, RNA or protein to identify the regions of similarity Areas of research in Bioinformatics Sequence Alignment Gene Structure Prediction Phylogenetic Tree Protein Folding LocalGlobal Constructed based on the distances between the sequences Classification and Identification of genes 2D3D N-W algorithm S-W algorithm End to End Alignment Internal small Stretches of Similarity

5 Smith Waterman Algorithm Similar subsequences of two sequences Implemented by large bioinformatics organizations Dynamic programming algorithm used to compute local alignment of pair of sequences Impractical due to time and space complexities Progressive alignment is the widely used heuristic- distance value between each pair of sequences- phylogenetic tree- pairwise alignment of various profiles Hardware implementations of the algorithm exploit opportunities for parallelism and further accelerate the execution

6 Proposed Idea Efficient C code implementation of the MSA Preprocessing steps and parallel processing approaches Profiling to determine the performance bottlenecks, identifying the areas of the code that can benefit from the parallelization High level optimizations to be performed to obtain a better speed-up Improving the CPI Including pipelining, data prefetching, data locality, avoiding resource contention and support parallelization of the main kernel

7 Front-end (C/C++ & Fortran 77/90) LNO (Loop Nest Optimizer) IPA (Inter Procedural Analyzer) WOPT (global scalar optimizer) IR-to-source translation (whir2c & whirl2f) Native compilers Native compilers Source code w/ OpenMP directives Portable OpenMP Runtime library Executables Linking Backend Source code w/ OMP lib calls OpenUH Compiler Infrastructure Tool Support

8 The OpenUH Compiler Based on the Open64 compiler. A suite of optimizing compiler tools for Linux/Intel IA-64 systems and IA-32 (source-to-source). First release open-sourced by SGI –Available for researchers/developers in the community. Multiple languages and multiple targets –C, C++ and Fortran77/90 –OpenMP 2.0 support ( University of Houston, Tsinghua University, PathScale)

9 Call Graph Flow Graph Array Regions Data Dependence Analysis OpenUH/64 includes The Dragon Analysis Tool

10 TAU- Profiling Toolkit for Performance Analysis of Parallel programs written in Fortran, C, C++, Java or Python

11 Tuning Methodology Bottlenecks in the program are identified with hardware performance counters The following are the investigations: Count of useful instructions = 7.63E+9 No-opt operations = 44% (moving this portion to the reconfigurable platform would be inefficient) Branch Mispredictions = 75% (this would stall the pipeline, cause wastage of resources) Cycles per instruction = 0.3178 (Instructions are stalling)

12 Goal: To reduce total cycles, reduce stalls, no-ops, conditionals and hoist loops outside, improve memory locality Used software parallel programming paradigm, OpenMP and pragmas to parallelize the code Realized the dependencies in the program with Dragon tool Control Flow and Data Flow graph used to distinguish between regions Aggressive privatizations applied to most of the arrays Fine grained locks define to access shared arrays Hot spots of the application identified

13 OpenMP Pseudo code msap { #pragma parallel region private(..) firstprivate(..) { #pragma omp for for(…) Initialize Array of Locks #pragma omp for no wait for (…) { Computations () for (…) { { Computations () } // update to shared data omp_set_lock() Updates to shared data. omp_unset_lock() }

14 Result Obtained after performing optimizations: Count of useful instructions = 8.40E+9 No-opt operations = 24% Branch Mispredictions = 59% Cycles per instruction = 0.28 (Lowered, hence higher performance) CPI improvements of 11.89% - Reduction in branch misprediction of 21.33% - NOP instructions reduced by 45.45% ParametersUnoptimizedOptimized Useful Instruction Count 7.63E + 98.40E + 9 NOP operations44%24% Branch Mispredictions 75%59% Cycles/Inst CPI 0.31780.28

15 Scheduling Static Scheduling Reduced synchronization/communication overhead Uneven sized tasks Load imbalances and idle processors leading to wastage of resources Triangular matrix- resultant matrix not achieved - No ideal speed-up

16 Dynamic Scheduling Option of Flexibility As the parallel loop is executed, number of iterations each thread performs is determined dynamically Loop divided into chunks of h iterations or chunk size equaling to 1 or x% of the h th iterations. Ideal speed-up of ~80% achieved

17 Dynamic Scheduling (Triangular Matrix) Static Scheduling Vs

18 Execution and Tuning Model

19 Conclusion and Future Work Multithreaded application achieves 78% of ideal speed-up on dynamic scheduling with 128 threads on 1000 sequence protein data set. Looking at translating OpenMP to Impulse-C, a tool for main stream embedded programmers seeking high performance through FPGA co- processing Plan to address the lack of tools and techniques for turn-key mapping of algorithms to the hybrid CPU-FPGA systems by developing an OpenUH add – on module to perform this mapping automatically

Download ppt "Sunita Chandrasekaran 1 Oscar Hernandez 2 Douglas Leslie Maskell 1 Barbara Chapman 2 Van Bui 2 1 Nanyang Technological University, Singapore 2 University."

Similar presentations

Ads by Google