MULTIMEDIA PROCESSING ON MANY-CORE TECHNOLOGIES USING DISTRIBUTED MULTIMEDIA MIDDLEWARE

Similar documents
SORA: a Service-Oriented Rendering Architecture

high performance medical reconstruction using stream programming paradigms

Dynamic Fine Grain Scheduling of Pipeline Parallelism. Presented by: Ram Manohar Oruganti and Michael TeWinkle

Parallel Variable-Length Encoding on GPGPUs

GPU Programming. Lecture 1: Introduction. Miaoqing Huang University of Arkansas 1 / 27

Portland State University ECE 588/688. Graphics Processors

An Efficient Approach for Emphasizing Regions of Interest in Ray-Casting based Volume Rendering

N-Body Simulation using CUDA. CSE 633 Fall 2010 Project by Suraj Alungal Balchand Advisor: Dr. Russ Miller State University of New York at Buffalo

Computer Architecture

I/O Systems. Jo, Heeseung

Parallel Processing SIMD, Vector and GPU s cont.

DIFFERENTIAL. Tomáš Oberhuber, Atsushi Suzuki, Jan Vacata, Vítězslav Žabka

Dense matching GPU implementation

High Performance Computing. University questions with solution

Exploring GPU Architecture for N2P Image Processing Algorithms

Face Detection CUDA Accelerating

High performance 2D Discrete Fourier Transform on Heterogeneous Platforms. Shrenik Lad, IIIT Hyderabad Advisor : Dr. Kishore Kothapalli

Optimization solutions for the segmented sum algorithmic function

XIV International PhD Workshop OWD 2012, October Optimal structure of face detection algorithm using GPU architecture

NUMA-Aware Data-Transfer Measurements for Power/NVLink Multi-GPU Systems

Lecture 10. Efficient Host-Device Data Transfer

E6895 Advanced Big Data Analytics Lecture 8: GPU Examples and GPU on ios devices

A Parallel Decoding Algorithm of LDPC Codes using CUDA

The rcuda middleware and applications

Communication. Distributed Systems Santa Clara University 2016

Programming hybrid systems with implicit memory based synchronization

Appendix B - Unpublished papers

Dynamic Distributed Multimedia: Seamless Sharing and Reconfiguration of Multimedia Flow Graphs

CSCI 402: Computer Architectures. Parallel Processors (2) Fengguang Song Department of Computer & Information Science IUPUI.

WHY PARALLEL PROCESSING? (CE-401)

Module 11: I/O Systems

Re-architecting Virtualization in Heterogeneous Multicore Systems

High Performance Computing on GPUs using NVIDIA CUDA

GPU Fundamentals Jeff Larkin November 14, 2016

A TALENTED CPU-TO-GPU MEMORY MAPPING TECHNIQUE

Martin Dubois, ing. Contents

ALL the assignments (A1, A2, A3) and Projects (P0, P1, P2) we have done so far.

Performance Analysis of Memory Transfers and GEMM Subroutines on NVIDIA TESLA GPU Cluster

Leveraging Hybrid Hardware in New Ways: The GPU Paging Cache

OpenMP for next generation heterogeneous clusters

CS4961 Parallel Programming. Lecture 3: Introduction to Parallel Architectures 8/30/11. Administrative UPDATE. Mary Hall August 30, 2011

Cor Meenderinck, Ben Juurlink Nexus: hardware support for task-based programming

New Approach for Graph Algorithms on GPU using CUDA

This is a draft chapter from an upcoming CUDA textbook by David Kirk from NVIDIA and Prof. Wen-mei Hwu from UIUC.

IBM Cell Processor. Gilbert Hendry Mark Kretschmann

Professional Multicore Programming. Design and Implementation for C++ Developers

I/O Systems. Jinkyu Jeong Computer Systems Laboratory Sungkyunkwan University

Automatic Pruning of Autotuning Parameter Space for OpenCL Applications

Accelerating Lossless Data Compression with GPUs

CUDA PROGRAMMING MODEL Chaithanya Gadiyam Swapnil S Jadhav

X10 specific Optimization of CPU GPU Data transfer with Pinned Memory Management

Simplifying Applications Use of Wall-Sized Tiled Displays. Espen Skjelnes Johnsen, Otto J. Anshus, John Markus Bjørndalen, Tore Larsen

Operating Systems Comprehensive Exam. Spring Student ID # 3/20/2013

CME 213 S PRING Eric Darve

Operating System Performance and Large Servers 1

CS330: Operating System and Lab. (Spring 2006) I/O Systems

Multimedia Systems 2011/2012

Hierarchical PLABs, CLABs, TLABs in Hotspot

Faster Simulations of the National Airspace System

CS4230 Parallel Programming. Lecture 3: Introduction to Parallel Architectures 8/28/12. Homework 1: Parallel Programming Basics

Multiprocessors. Flynn Taxonomy. Classifying Multiprocessors. why would you want a multiprocessor? more is better? Cache Cache Cache.

Efficiency Considerations of Cauchy Reed-Solomon Implementations on Accelerator and Multi-Core Platforms

The latency of user-to-user, kernel-to-kernel and interrupt-to-interrupt level communication

HPC Architectures. Types of resource currently in use

Efficient Data Transfers

High Performance Computing. Taichiro Suzuki Tokyo Institute of Technology Dept. of mathematical and computing sciences Matsuoka Lab.

Performance of DB2 Enterprise-Extended Edition on NT with Virtual Interface Architecture

Optimizing the use of the Hard Disk in MapReduce Frameworks for Multi-core Architectures*

Accelerating image registration on GPUs

Communication Library to Overlap Computation and Communication for OpenCL Application

CISC 879 Software Support for Multicore Architectures Spring Student Presentation 6: April 8. Presenter: Pujan Kafle, Deephan Mohan

A Data-Parallel Genealogy: The GPU Family Tree. John Owens University of California, Davis

Experimental Extensions to RSVP Remote Client and One-Pass Signalling

Evaluation of Asynchronous Offloading Capabilities of Accelerator Programming Models for Multiple Devices

Current Trends in Computer Graphics Hardware

CUDA Optimizations WS Intelligent Robotics Seminar. Universität Hamburg WS Intelligent Robotics Seminar Praveen Kulkarni

Analysis-driven Engineering of Comparison-based Sorting Algorithms on GPUs

EXTENDING AN ASYNCHRONOUS MESSAGING LIBRARY USING AN RDMA-ENABLED INTERCONNECT. Konstantinos Alexopoulos ECE NTUA CSLab

6.9. Communicating to the Outside World: Cluster Networking

Chapter 04. Authors: John Hennessy & David Patterson. Copyright 2011, Elsevier Inc. All rights Reserved. 1

Threads SPL/2010 SPL/20 1

Lecture 13: Memory Consistency. + a Course-So-Far Review. Parallel Computer Architecture and Programming CMU , Spring 2013

Chapter 1 Computer System Overview

Adaptive-Mesh-Refinement Hydrodynamic GPU Computation in Astrophysics

HIGH-PERFORMANCE NETWORKING :: USER-LEVEL NETWORKING :: REMOTE DIRECT MEMORY ACCESS

Accelerating Adaptive Background Subtraction with GPU and CBEA Architecture

NVIDIA GPUDirect Technology. NVIDIA Corporation 2011

An RDMA Protocol Specification (Version 1.0)

Accelerating Braided B+ Tree Searches on a GPU with CUDA

Performance of Multihop Communications Using Logical Topologies on Optical Torus Networks

Chapter 13: I/O Systems

A Parallel Access Method for Spatial Data Using GPU

All About the Cell Processor

Chapter 3 Parallel Software

High Performance Remote Sensing Image Processing Using CUDA

Chapter 4 Communication

Lecture 1: Introduction and Basics

Accelerating Blockchain Search of Full Nodes Using GPUs

High-Performance Data Loading and Augmentation for Deep Neural Network Training

CS 179: GPU Computing LECTURE 4: GPU MEMORY SYSTEMS

Transcription:

MULTIMEDIA PROCESSING ON MANY-CORE TECHNOLOGIES USING DISTRIBUTED MULTIMEDIA MIDDLEWARE Michael Repplinger 1,2, Martin Beyer 1, and Philipp Slusallek 1,2 1 Computer Graphics Lab, Saarland University, Saarbrücken, Germany 2 German Research Center for Artificial Intelligence (DFKI), Agents & Simulated Reality, Saarbrücken, Germany email: michael.repplinger@dfki.de, beyer@graphics.cs.uni-sb.de, philipp.slusallek@dfki.de ABSTRACT Today, there are increasingly more powerful many-core processors (MCPs) that are integrated into stationary and mobile devices, freely programmable and well suited for multimedia processing. However, there are still many obstacles and problems when programming multimedia applications for MCPs. In this paper we show that all these obstacles and problems can be solved by treating a device with an integrated MCP in the same way as a distributed system and using distributed multimedia middleware even for developing locally running applications. This approach completely hides all specific aspects of an MCP while the application can fully exploit the processing power of MCPs in local and even remote devices. KEY WORDS Parallel and Distributed Processing, Distributed Multimedia Middleware, Many-Core, CUDA 1 Introduction Available distributed multimedia middleware solutions such as the Network-Integrated Multimedia Middleware (NMM) [7] consider the network as an integral part of their architecture and allow transparent use and control of stationary and mobile devices across the network. To hide technology and network specific aspects from the application, they apply the concept of a distributed flow graph, providing a strict separation of media processing and media transmission as can be seen in Figure 1. The nodes of a distributed flow graph represent processing units and hide all aspects of the underlying technology used for media processing. Edges represent connections between two nodes and hide all specific aspects of data transmission within a transport strategy (e.g., pointer forwarding for local and TCP for network connections). Thus, media streams can flow from distributed source to sink nodes, being processed by each node in-between. However, upcoming many-core technologies and processors like Nvidia s Compute Unified Device Architecture (CUDA) [8] on top of GPUs or IBM s Cell Broadband Engine (CBE) [6] allow highly parallel processing within a single system and are well suited to be used for multimedia processing. In general, an MCP can only execute algorithms for Figure 1. Technology specific aspects are either hidden within nodes or edges of a distributed flow graph. data processing, we call kernels, while the corresponding control logic still has to be executed on the CPU. The main problem for a software developer is that a kernel runs in a different address space than the application itself. To exchange data between the application and the kernel, specialized communication mechanisms (e.g., DMA data transfer), memory areas, and special scheduling strategies have to be used. This seriously complicates integrating MCPs into new and existing multimedia applications. However, these problems are quite similar to the problems solved by a distributed multimedia middleware. The general idea presented in this paper is to solve these problems by treating collocated CPUs and MCPs like a distributed system. As an example, we use CUDA. Employing distributed multimedia middleware makes it possible to attain the following three goals: 1. hide CUDA specific aspects from the application, 2. enable the efficient combination of nodes using CPU and GPU for media processing, i.e., avoid unrequired memory copies and use all GPUs within a system, 3. and transparently use remote GPUs for processing. In Section 2 we discuss CUDA specific issues and evaluate the requirements for integrating CUDA into a distributed multimedia middleware to reach the above goals. Section 3 discusses related work and Section 4 presents the integration of CUDA into NMM. Section 5 shows how to extend a distributed multimedia middleware so that it can transparently use remote GPUs for media processing. Section 6 presents performance measurements showing that multimedia applications using CUDA can even improve their performance when using our approach. Section 7 concludes this paper and highlights future work.

2 Requirements The Nvidia CUDA Toolkit [8] offers great possibilities for parallel programming on GPUs but does not provide convenient abstractions for multimedia applications. We identified the following five requirements to be supported by a distributed multimedia middleware in order to integrate CUDA and to reach the three goals introduced in Section 1. (1) Distributed Flow Graph The concept of distributed flow graph is required to achieve a strict separation of media processing and transmission which allows presenting nodes using the CPU or GPU in a unified way to the application. CUDA kernels can than be integrated into nodes. In the following, nodes using the CPU for media processing are called CPU nodes while nodes using the GPU are called GPU nodes. A GPU node runs in the address space of the application but configures and controls kernel functions running on a GPU. Since kernels of a GPU node run in a different address space, media data received from main memory has to be copied to the GPU before it can be processed. CUDA provides DMA transfer to reduce the overhead caused by memory transfers from CPU to GPU and vice versa. However, since DMA transfer is only required when connecting nodes that process data in different address spaces (e.g., GPU and CPU nodes), data should not be copied within a node to avoid dependencies and ensure extendability. Therefore, a strict separation of media processing and transmission is essential. This is ensured in the approach of a distributed flow graph. Here, the DMA transfer has to be integrated as a transport strategy and is completely hidden from the application and independent of nodes. (2) Parallel Binding In general, a multimedia stream consists of multimedia data, called buffers, and control information, called events, while a strict message order has to be preserved [9]. Since a GPU can only process buffers, events have to be sent to and executed within the corresponding GPU node. This means that different transport strategies have to be used to send messages of a data stream to a GPU node, i.e., DMA transfer for media data and pointer forwarding for control events. In [9] the concept of parallel binding, as shown in Figure 2, is introduced. This allows to use different transport strategies for buffers and events, while the original message order is preserved. Using (1) distributed flow graph together with (2) parallel binding hides CUDA specific aspects from the application and thus constitutes the completion of our first goal. (3) Shareable Buffer Manager CUDA needs memory allocated as page-locked memory on the CPU side to use DMA communication for transporting media data, which is generally not used by CPU nodes. To enable efficient communication and avoid unnecessary memory copies between CPU and GPU nodes, a distributed multimedia mid- Figure 2. A multimedia stream consists of buffers B and events E. A parallel binding allows to use different transport strategies to send these messages while the strict message order is preserved. dleware has to support shareable buffer managers. Shareable buffer managers are responsible for allocating and releasing specific memory blocks, e.g., page-locked memory, and which is the important aspect here they can be shared between multiple nodes and transport strategies. This allows a transport strategy or node to inform all preceding nodes and transport strategies to use a specific buffer manager for media processing. (4) Scheduling Strategies To consider CUDAs special requirements regarding scheduling and to achieve an efficient integration of CUDA, support for different scheduling strategies within a distributed multimedia middleware is essential. As soon as a CUDA specific operation is executed (e.g., allocating page-locked memory on CPU side), all following operations related to this memory are bound to the same GPU. Moreover, all following CUDA operations must be initiated by the same application thread. Due to the complexity of using multiple application threads together with CUDA, Nvidia proposes to use a single application thread in its programming guide [8]. This is not acceptable within a distributed multimedia middleware, especially because one application thread cannot be used to access and control different GPUs. Thus, all components of a distributed multimedia middleware have to be enabled to request a specific application thread for processing. Support for (3) sharable buffer manager together with support for different (4) scheduling strategies enables efficient communication between CPU and GPU nodes which constitutes the completion of our second goal. (5) Pipeline of Transport Strategies A pipeline of transport strategies is required to use remote GPU nodes. A GPU only has access to the main memory of the collocated CPU and is not able to send buffers directly to a network interface. If a buffer located on a GPU has to be sent to a remote system, it has to be copied to the main memory first. In a second step, the buffer can be sent to a remote system using standard network protocols like TCP. This requires to set up a pipeline of different transport strategies within a parallel binding in order to reuse existing transport strategies. Support for (5) pipeline of transport strategies

enables transparent use of distributed CPU and GPU nodes and constitutes the completion of our third and last goal. 3 Related Work Due to the wide acceptance of CUDA, there already exist some CUDA specific extensions, but none of them achieve all of the three goals introduced in Section 1. Typical libraries on top of CUDA, like GpuCV [1] and Open- Vidia [4], completely hide the underlying GPU architecture. Since they act as black box solutions it is difficult to combine them with existing multimedia applications that use the CPU. However, the CUDA kernels of such libraries can be reused in the presented approach. Hartley et al. [5] integrated CUDA in a grid computing framework which is built on top of the DataCutter middleware, to speed up compute intensive tasks. Since the DataCutter middleware focuses on processing a large number of completely independent tasks, it is not suitable for multimedia processing. Available distributed multimedia middleware solutions like NMM [7], NIST II [3] and Infopipe [2] are especially designed for distributed multimedia processing, but only NMM and NIST II support the concept of a distributed flow graph. However, the concept of parallel binding (requirement (2)) as well as shareable buffer managers (requirement (3)) is only supported by NMM and not by NIST II. Moreover, in NMM each node can choose its own scheduling approach, and scheduling information (e.g., thread IDs) can be exchanged between all components of the flow graph either as part of buffers or as special events. This allows to combine different scheduling strategies within NMM (requirement (4)). The combination of different transport strategies within parallel binding (requirement (5)) is not support by NMM. However, to the best of our knowledge, none of the available distributed multimedia middleware solutions support this functionality. Altogether, there is no framework on top of CUDA that attains all three goals stated in Section 1 and no multimedia middleware that fulfills the five requirements stated in 2. 4 Integration of CUDA We use a three layer approach for integrating CUDA into NMM as can be seen in Figure 3. All three layers can be accessed from the application, but only the first layer, which includes the distributed flow graph, can be seen by default. Here, all CUDA kernels are encapsulated into specific GPU nodes, so that they can be used within a distributed flow graph for media processing. Since processing of a specific buffer requires that all following operations have to be executed on the same GPU, our integration of CUDA utilizes this aspect and ensures that all following GPU nodes use the same GPU. Therefore, GPU nodes are interconnected using thelocalstrategy which simply Figure 3. CUDA is integrated into NMM using a three layer approach. All layers can be accessed by the application, but only the distributed flow graph is seen by default. forwards pointer of buffers. However, the concept of parallel binding is required for connecting CPU and GPU nodes. Here, incoming events are still forwarded to a LocalStrategy because a GPU node processes events in the same address space as a CPU node. Incoming buffers are sent to a CPUToGPUStrategy or GPUToCPUStrategy to copy media data from main memory to GPU memory or vice versa using CUDA s asynchronous DMA transfer. NMM also provides a connection service that is extended to automatically choose these transport strategies for transmitting buffers between GPU and CPU nodes. This shows that the approach of a distributed flow graph hides all specific aspects of CUDA to the application and thus attains the first goal introduced in Section 1. The second layer enables efficient memory management. Page-locked memory that can be directly copied to a GPU is allocated and managed by a CPUBufferManager, while a GPUBufferManager allocates and manages memory on a GPU. Since a CPUToGPUStrategy requires page-locked memory to avoid unnecessary copy operations, it forwards a CPUBufferManager to all predecessor nodes. This is enabled by the concept of shareable buffer managers, described in Section 2. As can be seen in Figure 3, this is done as soon as a connection between a CPU and GPU node is established. Again, this shows the benefit of using a distributed multimedia middleware for multimedia processing on an MCP. GPU nodes can be combined with existing CPU nodes in an efficient way, i.e., without unrequired memory copies, and without changing the implementation of existing nodes. The lowest layer is responsible for managing and scheduling of available GPUs within a system. Since different GPUs cannot be accessed by using the same application thread, the CUDAManager maintains an individual thread for each GPU, called GPU thread. If a component executes a CUDA operation within one of its methods (e.g., executes a kernel), it requests the CUDAManager to invoke this method by using a specific GPU thread. Execut-

Figure 5. Pipelined parallel binding allows to combine different transport strategies and allows to connect distributed CPU and GPU nodes. Figure 4. This figure shows buffer processing using a combination of CPU and GPU nodes. ing a method through the CUDAManager blocks until the CUDAManager has executed the corresponding method. This completely hides the use of multiple GPU threads as well as different application threads for accessing a GPU and the application logic. However, since page-locked memory is already bound to a specific GPU, the CUDAManager instantiates a CPUBufferManager and GPUBufferManager for each GPU. To propagate scheduling information between different nodes, each buffer stores information about the GPU thread that has to be used for processing. Moreover, CUDA operations are executed asynchronously in so called CUDA streams. Therefore, each buffer provides its own CUDA stream where all components along the flow graph queue their CUDA specific operations asynchronously. Since all buffers used by asynchronous operations of a single CUDA stream can only be released if the CUDA stream is synchronized, each CUDA stream is encapsulated into an NMM-CUDA stream that also stores involved resources and releases them if the CUDA stream is synchronized. Figure 4 shows all steps for processing a buffer using CPU and GPU nodes: 1. When CPUToGPUStrategy receives a buffer B CPU, it requests a suitable buffer B GPU for the same GPU. Then it initiates an asynchronous copy operation. Before forwarding B GPU to GPU node A, it adds B CPU to the NMM-CUDA stream because this buffer can only be released if the CUDA stream is synchronized. 2. GPU node A initiates the asynchronous execution of its kernel and forwards B GPU to GPU node B. Since both GPU nodes execute their kernel on the same GPU, the connecting transport strategy uses simple pointer forwarding to transmit B GPU to GPU node B. 3. GPU node B also initiates the asynchronous execution of the kernel and forwards B GPU. 4. When GPUtoCPUStrategy receives B GPU, it requests a new B CPU and initiates asynchronous memory copy from GPU to CPU. 5. Finally, the transport strategy synchronizes the CUDA stream to ensure that all operations on the GPU have been finished, before forwarding B CPU to CPU node B and releases all resources stored in the CUDA- NMM stream. 4.1 Using Multiple GPUs The last step to attain the second goal introduced in Section 1 is to automatically use multiple GPUs within the same system. The most important influence on scheduling, especially when using multiple GPUs, is that page-locked memory is bound to a specific GPU. This means that all following processing steps are bound to a specific GPU but GPU nodes are not explicitly bound to a specific GPU. As soon as multiple GPUs are available, the processing of the next media buffer can be initialized on a different GPU. However, this is only possible if a kernel is stateless and does not depend on information about already processed buffers, e.g. a kernel that changes the resolution of each incoming video buffer. In contrast to this, a stateful kernel, e.g. for encoding or decoding video, stores state information on a GPU and cannot automatically be distributed to multiple GPUs. When using a stateful kernel inside a GPU node, the corresponding CPUToGPUStrategy uses a CPUBufferManager of a specific GPU to limit media processing to a single GPU. But if a stateless kernel inside a GPU node is used, the corresponding CPUToGPUStrategy forwards a CompositeBufferManager to all preceding nodes. The CompositeBufferManager includes CPUBufferManager for all GPUs, and when a buffer is requested it asks the CUDAManager which GPU should be used and returns a page-locked buffer for the corresponding GPU. So far we implemented a simple round robin mechanism that is used inside the CUDAManager to distribute buffers one GPU after the other. Together, this integration of CUDA into NMM attains goal 1 and 2 as stated in Section 1. 5 Pipelined Parallel Binding To use remote GPUs for media processing, the combination of different transport strategies within parallel binding has to be supported, as described in Section 2. This is for example required, if a video stream is received from a remote source and should be directly send to the local GPU

for decoding. Since such a functionality is not supported by NMM or any other existing multimedia middleware, we propose the concept of pipelined parallel binding as an extension to the parallel binding described in [9]. The general idea of this concept can be seen in Figure 5. This figure shows how to connect two remote GPU nodes. In this example, three transport strategies, i.e., a GPUtoCPUStrategy, a TCPStrategy, and a CPUtoGPUStrategy, are required to send buffers between two remote GPU nodes. For sending events, a single TCPStrategy is sufficient because events are processed on the CPU. To automatically find suitable combinations of transport strategies we propose the following extensions to a distributed multimedia middleware. These were also integrated into NMM. First, we uniquely describe an address space by using a so called location information that consists of the following key value pairs: Domain specifies the name of the network domain of a system, Host specifies the hostname of a system within a network domain, PID specifies the process ID to distinguish between different applications running on the same host and Core describes the used processor (e.g., CPU, GPU, CBE,... ). Each node in NMM is extended by a location information for buffer and event processing. The keys Domain, Host and PID are automatically set by NMM as soon as a node is instantiated. Only the keycore, which is set to CPU by default, has to be changed within a node that does not use the CPU for processing events or buffers. Furthermore, each transport strategy is extended to provide two types of location information, called source location and destination location, that describe the address spaces between which buffers and events can be transported. If a transport strategy supports arbitrary or multiple values for a specific key, it can specify a wildcard or a list of values, respectively. For example, transport strategies using a network protocol can in general be used for sending data between different hosts, domains and processes. Thus a transport strategy specifies a wildcard for these values. Since different transport strategies can be used for exchanging data between the same address spaces, e.g., for network transport, each transport strategy is extended by a suitable weight > 0 to automatically decide which transport strategy is used by default. However, an application can change these suitable values if required. Using this information, we developed a connection algorithm that is able to (1) find possible combinations of transport strategies that are stored in a connection graph and (2) to choose a default combination for automatic connection setup based on the weight of transport strategies. If two nodes are connected, the connection algorithm creates the corresponding connection graph for buffers and events. Figure 6 shows the establishment of the connection graph for buffers between two remote GPU nodes. The location information of the GPU nodes is used as source and sink of the connection graph (Figure 6 (a)). Afterwards, source and destination location of transport strategies are Figure 6. Creating the connection graph for sending buffers between two remote GPU nodes. Step (d) includes all valid combinations of transport strategies that can be used to establish a connection. added as nodes of the connection graph, if they either produce a partial match (e.g., Figure 6 (b) and (c)) or a complete match (e.g., Figure 6 (d)). The weight of a transport strategy is stored in added edges. A partial match occurs if a transport strategy is found the source location of which is identical with the destination location of the preceding location information. Two instances of location information are identical if and only if they have at least one identical value for each key. Wildcards are replaced by matching values. Furthermore, the destination location has to differ at least in one key with the sink of the connection graph, and the added pair of location information must not already occur on the corresponding path of the connection graph in order to avoid cycles. A complete match occurs if the destination location is identical with the sink of the connection graph. As soon as a complete match has been found, a valid combination of transport strategies has been found to establish a connection between two nodes. In a second step, the connection algorithm determines the shortest path of the graph. Since the connection graph has a single source, it can be reduced to the standard graph problem Single Source Shortest Path (SSSP). Moreover, all edges have a weight > 0, so we apply Dijkstra s algorithm for finding the shortest path. Altogether, the proposed approach of pipelined parallel binding allows to use GPU nodes for distributed processing and thus completes the third goal introduced in Section 1. Furthermore, this approach achieves a maximum of flexibility and re-usability because only the MCP specific transport strategies have to be added. These are automatically used and combined with existing transport strategies by the above described connection algorithm.

Buffer [KB] Reference [Buf/s] NMM 1 GPU [Buf/s] NMM 2 GPUs [Buf/s] 50 6572 6771 (103 %) 10762 (163.8 %) 500 996 1175 (118 %) 2317 (232.6 %) 1000 513 585 (114 %) 1173 (228.7 %) 2000 259 297 (114.7 %) 592 (228.6 %) 3000 174 203 (116.7 %) 407 (233.9 %) Table 1. Performance of the NMM-CUDA integration versus a single threaded reference implementation. Throughput is measured in buffers per second [Buf/s]. 6 Performance Measurements For all performance measurements we use a PC with an Intel Core2 Duo 3.33 GHz processor, 4 GB RAM and 2 Nvidia GeForce 9600 GT graphics boards with 512 MB RAM, running 64 Bit Linux and CUDA Toolkit 2.0. In order to measure the overhead of the presented approach, we compare the maximum throughput of buffers processed on a GPU using a reference program that copies data from CPU to GPU, executes a kernel and finally copies data back to main memory using a single application thread with a corresponding flow graph that consists of two CPU nodes and one GPU node in between using the same kernel. Based on the throughput of buffers per second that can be passed, we compare the reference implementation and the corresponding NMM flow graph. Since NMM inherently uses multiple application threads, which is not possible by the reference application without using a framework like NMM, these measurements also include the influence of using multiple threads. For all measurements, we used a stateless kernel that adds a value to each byte of the buffer. The resulting throughput with different buffer sizes can be seen in Table 1. The achieved throughput of our integration is up to 16.7% higher compared to the reference application. These measurements show that there is no overhead when using NMM as distributed multimedia middleware together with our CUDA integration, even for purely locally running applications. Moreover, the presented approach inherently uses multiple application threads for accessing the GPU, which leads to a better exploitation of the used GPU. Since CUDA operations are executed asynchronously, the CPU only spends a negligible amount of time to issue the kernel calls which can then be processed on the GPU. Finally, adding a second GPU can double the buffer throughput for larger buffer sizes, if a stateless kernel is used. 7 Conclusion and Future Work In this paper we demonstrated that a distributed multimedia middleware like NMM is suitable for multimedia processing on a GPU. Moreover, it fulfills three essential goals: 1. to hide CUDA-specific aspects from the application, 2. to enable the efficient combination of components using CPU and GPU for media processing, and 3. the transparent use of remote GPUs for media processing. From our point of view, a distributed multimedia middleware such as NMM is essential to fully exploit the processing power of many-core technologies, while still offering a suitable abstraction for developers. Thus, future work will focus on integrating emerging many-core technologies to conclude on which functionality should additionally be provided by a distributed multimedia middleware. References [1] Y. Allusse, P. Horain, A. Agarwal, and C. Saipriyadarshan. GpuCV: An Open-Source GPU-accelerated Framework for Image Processing and Computer Vision. In MM 08: Proceeding of the 16th ACM international conference on Multimedia, pages 1089 1092, New York, NY, USA, 2008. ACM. [2] A. P. Black, J. Huang, R. Koster, J. Walpole, and C. Pu. Infopipes: An Abstraction for Multimedia Streaming. Multimedia Syst., 8(5):406 419, 2002. [3] A. Fillinger, L. Diduch, I. Hamchi, M. Hoarau, S. Degr, and V. Stanford. The NIST Data Flow System II: A Standardized Interface for Distributed Multimedia Applications. In IEEE International Symposium on a World of Wireless; Mobile and MultiMedia Networks (WoWMoM). IEEE, 2008. [4] J. Fung and S. Mann. OpenVIDIA: parallel GPU computer vision. In MULTIMEDIA 05: Proceedings of the 13th annual ACM international conference on Multimedia, pages 849 852, New York, NY, USA, 2005. ACM. [5] Hartley, T. D. R., C. Umit, R. Antonio, I. Francisco, M. Rafael, and U. Manuel. Biomedical Image Analysis on a Cooperative Cluster of GPUs and Multicores. In ICS 08: Proceedings of the 22nd annual international conference on Supercomputing, pages 15 25, New York, NY, USA, 2008. ACM. [6] J. A. Kahle, M. N. Day, H. P. Hofstee, C. R. Johns, T. R. Maeurer, and D. Shippy. Introduction to the CELL Multiprocessor. IBM J. Res. Dev., 49(4/5):589 604, 2005. [7] M. Lohse, F. Winter, M. Repplinger, and P. Slusallek. Network-Integrated Multimedia Middleware (NMM). In MM 08: Proceedings of the 16th ACM international conference on Multimedia, pages 1081 1084, 2008. [8] NVIDIA. CUDA Programming Guide 2.0. 2008. [9] M. Repplinger, F. Winter, M. Lohse, and P. Slusallek. Parallel Bindings in Distributed Multimedia Systems. In Proceedings of the 25th IEEE International Conference on Distributed Computing Systems Workshops (ICDCS 2005), pages 714 720. IEEE Computer Society, 2005.