OpenCL: Free Your GPU… and the rest of your system too!

By Nicole Hemsoth

May 6, 2013

For the uninitiated, OpenCL may just seem like a tool for accessing GPUs in a portable manner, an alternative to CUDA that works for ATI cards.  This view of OpenCL is a vast oversimplification.  The truth is that OpenCL offers a rich set of features that will provide the infrastructure needed for application developers to fully utilize an increasingly heterogeneous hardware future.  In this article, we will consider how OpenCL can address some of the coming challenges, and what the OpenCL community is doing to insure that there is a vibrant ecosystem of support, as more and more users turn to OpenCL from vendor-locked solutions.

By now, we’ve all heard of the power wall, and we know that the only way to climb over it is parallelism.  Data-level parallelism (think GPUs) was the first technology to make a mark in the new computing age.  Employing very uniform work units, data-parallel implementations have achieved noteworthy performance gains for many scientific algorithms, and OpenCL certainly has support for this model.

However, this is not the end of the story.  As CPU vendors seek to adapt their architectures to the new parallel reality (and GPU vendors evolve theirs), alternate ideas about how to expose and exploit parallelism within a program are surfacing.  These designs seek to mitigate performance limitations for algorithms where the majority of the work does not fit neatly into non-divergent units of execution.

One such approach is to take a multicore architecture and scale it, providing increased resources for task-parallel workloads.  An example of this is the Intel Xeon Phi architecture, released in 2012.  Sharing similarities with CPUs and GPUs, the Xeon Phi programming model requires a little bit of both.  Like a CPU, the Xeon Phi prefers somewhat longer persistence from a work item, so that its caching scheme can work efficiently to hide memory access latency.  At the same time, the Xeon Phi offers many more units of execution than traditional SMP implementations are designed to handle.  For many applications, there is likely a good balance to be found that combines both data and task-parallelism, and fortunately for developers, Intel has provided OpenCL support for their entire processor line, including Xeon Phi and embedded graphics.  As an example of why this is beneficial, OpenCL has no problem expressing local accumulations, with or without blocked memory access, and its interface for managing work groups is sufficient for any level of data-parallel execution.  These features make it possible to seamlessly integrate mixed programming models that reflect the hybrid characteristics of the Xeon Phi hardware.

A third hardware strategy that has already been widely deployed, but not yet fully utilized (and often not even recognized) is the heterogeneous system-on-a-chip (SoC).  Founded with the now-extinct IBM Cell, and combining so-called latency-optimized cores (think CPU) with throughput-optimized cores (GPU), heterogeneous architectures attempt to provide the best of both worlds, albeit on separate parts of the die.  If you are reading this article on a mobile computing device, or a late model laptop or desktop, chances are that you already have a heterogeneous chip at your disposal: Apple A Series, NVIDIA Tegra, AMD Fusion, Qualcomm Snapdragon, and Intel Ivybridge are all heterogeneous.  Some of these chips are even likely to find their way onto the next generation of supercomputers.  If this is the case, and unless you are explicitly utilizing these resources, they can be an energy drain on your system with no benefit.  OpenCL makes the full potential of heterogeneous architectures available to the developer.

A final evolving hardware strategy that should be mentioned is the Field Programmable Gate Array (FPGA).  Few general-purpose processing architectures can compete with the energy efficiency of a custom circuit.  Sadly, very few developers are prepared to invest the time and effort needed to learn VHDL or Verilog to turn their ideas into a working core.  One very novel application of OpenCL seeks to remove this barrier by creating FPGA firmware from kernels written in the OpenCL C programming language.  The Altera Corporation (maker of the Stratix V architecture) has released the Altera SDK for OpenCL.  Using this set of tools, developers can generate custom hardware, tailor-made for their specific application.  This frees the application developer from the tedium of a job better left to electrical engineers, and, at the same time, opens a fascinating world of possibilities.

All of the hardware trends we have discussed, taken together, present significant challenges for any vendor-specific toolchain.  Consider the programming model for a system with a heterogeneous host processor, augmented with a discrete accelerator (GPU or other).  Efficient utilization of these resources will require the ability to tightly integrate both data-parallel and task-parallel work, along with data motion between the various compute units.  Do we really want to rely on a clumsy vendor-specific patchwork of tools to meet this challenge?  Imagine now that you must also support a similarly provisioned system but built from a different set of architectures.  How many versions of your code would you have to write?  How many man-years might you need for such a task?

With OpenCL, implementing such a model is straightforward.  This is because OpenCL is a natural reflection of the competing hardware architectures on which it is designed to run.  OpenCL accommodates each of the above architectures, and, by design, has no trouble in accommodating all of them together.  Being an open standard, new vendors are able to join the OpenCL dialogue, insuring that OpenCL will be able to support future hardware developments, regardless of what direction they may take.  Additionally, with its support for custom devices, OpenCL offers the flexibility to incorporate system resources that do not fit the current notion of a compute device, opening opportunities for integration of DSPs or internally developed ASICs.

Much of the FUD (fear, uncertainty and doubt) directed at OpenCL has focused on the mantra that OpenCL may be portable but not portably performant.  This is an attempt to divert the discussion from the real issue.  Clearly, all hardware is not the same, and no single approach to expressing a parallel algorithm can be optimal across the wide variety of architectures that are currently available.  This is not the point of OpenCL.  The true power of OpenCL is that it provides the infrastructure that allows us to target different combinations of hardware within a single framework.  OpenCL frees us from the old scenario where developers must use an ad hoc combination of interfaces to support multiple architectures.  True, we may need to write a new version of our kernel to get the best performance on Architecture A, but isn’t this what we actually want?  With OpenCL, developers can easily switch between different kernel implementations, execution topologies and memory model interpretations.  This flexibility is at the core of the OpenCL philosophy.  So, to the OpenCL detractors: A toad may criticize the way that a bird flaps its wings, but only to distract us from the fact that the toad cannot fly.

One thing that has thus far been missing from OpenCL is a formal organization for its users.  To remedy this, some of the primary advocates of OpenCL have organized a new user group.  Since OpenCL is about computing portability, this new group is aptly named Comportability.  Established as a non-profit corporation, Comportability is an open forum for all things related to OpenCL.  Membership is free.  Individuals are invited to participate in discussions, upload software and take part in the annual workshop.  Institutions and vendors may join as voting members, and are invited to form regional chapters, which are encouraged to host future meetings and workshops.

The 1st International Workshop on OpenCL (IWOCL), the annual meeting of the Comportability user group will take place May 13-14, 2013 at the Technology Square Research Building (TSRB) at the Georgia Institute of Technology in Atlanta, Georgia.  Registration for this event is open and the program is on-line.

Subscribe to HPCwire's Weekly Update!

Be the most informed person in the room! Stay ahead of the tech trends with industy updates delivered to you every week!

RIKEN Post-K Supercomputer Named After Japan’s Tallest Peak

May 23, 2019

May 23 -- RIKEN President Hiroshi Matsumoto announced that the successor to the K computer will be named Fugaku, another name for Mount Fuji, which is the tallest mountain peak in Japan. Supercomputer Fugaku, developed b Read more…

By Tiffany Trader

Cray’s Emerging Market & Technology Director Arti Garg Peers Around HPC/AI Corner

May 23, 2019

In her position as emerging market and technology director at Cray, Arti Garg doesn't just have a front-row seat to the future of computing, she plays an active role in making that future happen. Key to Garg's role is understanding how deep learning scientists are using state-of-the-art HPC infrastructures and figuring out how to push those limits further. Read more…

By Tiffany Trader

Combining Machine Learning and Supercomputing to Ferret out Phishing Attacks

May 23, 2019

The relentless ingenuity that drives cyber hacking is a global engine that knows no rest. Anyone with a laptop and run-of-the-mill computer smarts can buy or rent a phishing kit and start attacking – or it can be done Read more…

By Doug Black

HPE Extreme Performance Solutions

HPE and Intel® Omni-Path Architecture: How to Power a Cloud

Learn how HPE and Intel® Omni-Path Architecture provide critical infrastructure for leading Nordic HPC provider’s HPCFLOW cloud service.

For decades, HPE has been at the forefront of high-performance computing, and we’ve powered some of the fastest and most robust supercomputers in the world. Read more…

IBM Accelerated Insights

Smarter EDA: Leveraging New Technologies for Product Verification

There is perhaps no sector more competitive than the modern electronics industry. Macro-trends, including artificial intelligence, 5G, and the internet of things (IoT), continue to propel dramatic growth. Read more…

TACC’s Upgraded Ranch Data Storage System Debuts New Features, Exabyte Potential

May 22, 2019

There's a joke attributed to comedian Steven Wright that goes, "You can't have everything. Where would you put it?" Users of advanced computing can likely relate to this. The exponential growth of data poses a steep challenge to efforts for its reliable storage. For over 12 years, the Ranch system at the Texas Advanced Computing Center... Read more…

By Jorge Salazar, TACC

Cray’s Emerging Market & Technology Director Arti Garg Peers Around HPC/AI Corner

May 23, 2019

In her position as emerging market and technology director at Cray, Arti Garg doesn't just have a front-row seat to the future of computing, she plays an active role in making that future happen. Key to Garg's role is understanding how deep learning scientists are using state-of-the-art HPC infrastructures and figuring out how to push those limits further. Read more…

By Tiffany Trader

Combining Machine Learning and Supercomputing to Ferret out Phishing Attacks

May 23, 2019

The relentless ingenuity that drives cyber hacking is a global engine that knows no rest. Anyone with a laptop and run-of-the-mill computer smarts can buy or re Read more…

By Doug Black

Cray – and the Cray Brand – to Be Positioned at Tip of HPE’s HPC Spear

May 22, 2019

More so than with most acquisitions of this kind, HPE’s purchase of Cray for $1.3 billion, announced last week, seems to have elements of that overused, often Read more…

By Doug Black and Tiffany Trader

HPE to Acquire Cray for $1.3B

May 17, 2019

Venerable supercomputer pioneer Cray Inc. will be acquired by Hewlett Packard Enterprise for $1.3 billion under a definitive agreement announced this morning. T Read more…

By Doug Black & Tiffany Trader

Deep Learning Competitors Stalk Nvidia

May 14, 2019

There is no shortage of processing architectures emerging to accelerate deep learning workloads, with two more options emerging this week to challenge GPU leader Nvidia. First, Intel researchers claimed a new deep learning record for image classification on the ResNet-50 convolutional neural network. Separately, Israeli AI chip startup Hailo.ai... Read more…

By George Leopold

CCC Offers Draft 20-Year AI Roadmap; Seeks Comments

May 14, 2019

Artificial Intelligence in all its guises has captured much of the conversation in HPC and general computing today. The White House, DARPA, IARPA, and Departmen Read more…

By John Russell

Cascade Lake Shows Up to 84 Percent Gen-on-Gen Advantage on STAC Benchmarking

May 13, 2019

The Securities Technology Analysis Center (STAC) issued a report Friday comparing the performance of Intel's Cascade Lake processors with previous-gen Skylake u Read more…

By Tiffany Trader

Nvidia Claims 6000x Speed-Up for Stock Trading Backtest Benchmark

May 13, 2019

A stock trading backtesting algorithm used by hedge funds to simulate trading variants has received a massive, GPU-based performance boost, according to Nvidia, Read more…

By Doug Black

Cray, AMD to Extend DOE’s Exascale Frontier

May 7, 2019

Cray and AMD are coming back to Oak Ridge National Laboratory to partner on the world’s largest and most expensive supercomputer. The Department of Energy’s Read more…

By Tiffany Trader

Graphene Surprises Again, This Time for Quantum Computing

May 8, 2019

Graphene is fascinating stuff with promise for use in a seeming endless number of applications. This month researchers from the University of Vienna and Institu Read more…

By John Russell

Why Nvidia Bought Mellanox: ‘Future Datacenters Will Be…Like High Performance Computers’

March 14, 2019

“Future datacenters of all kinds will be built like high performance computers,” said Nvidia CEO Jensen Huang during a phone briefing on Monday after Nvidia revealed scooping up the high performance networking company Mellanox for $6.9 billion. Read more…

By Tiffany Trader

ClusterVision in Bankruptcy, Fate Uncertain

February 13, 2019

ClusterVision, European HPC specialists that have built and installed over 20 Top500-ranked systems in their nearly 17-year history, appear to be in the midst o Read more…

By Tiffany Trader

It’s Official: Aurora on Track to Be First US Exascale Computer in 2021

March 18, 2019

The U.S. Department of Energy along with Intel and Cray confirmed today that an Intel/Cray supercomputer, "Aurora," capable of sustained performance of one exaf Read more…

By Tiffany Trader

Intel Reportedly in $6B Bid for Mellanox

January 30, 2019

The latest rumors and reports around an acquisition of Mellanox focus on Intel, which has reportedly offered a $6 billion bid for the high performance interconn Read more…

By Doug Black

Looking for Light Reading? NSF-backed ‘Comic Books’ Tackle Quantum Computing

January 28, 2019

Still baffled by quantum computing? How about turning to comic books (graphic novels for the well-read among you) for some clarity and a little humor on QC. The Read more…

By John Russell

Deep Learning Competitors Stalk Nvidia

May 14, 2019

There is no shortage of processing architectures emerging to accelerate deep learning workloads, with two more options emerging this week to challenge GPU leader Nvidia. First, Intel researchers claimed a new deep learning record for image classification on the ResNet-50 convolutional neural network. Separately, Israeli AI chip startup Hailo.ai... Read more…

By George Leopold

Leading Solution Providers

SC 18 Virtual Booth Video Tour

Advania @ SC18 AMD @ SC18
ASRock Rack @ SC18
DDN Storage @ SC18
HPE @ SC18
IBM @ SC18
Lenovo @ SC18 Mellanox Technologies @ SC18
NVIDIA @ SC18
One Stop Systems @ SC18
Oracle @ SC18 Panasas @ SC18
Supermicro @ SC18 SUSE @ SC18 TYAN @ SC18
Verne Global @ SC18

The Case Against ‘The Case Against Quantum Computing’

January 9, 2019

It’s not easy to be a physicist. Richard Feynman (basically the Jimi Hendrix of physicists) once said: “The first principle is that you must not fool yourse Read more…

By Ben Criger

Deep500: ETH Researchers Introduce New Deep Learning Benchmark for HPC

February 5, 2019

ETH researchers have developed a new deep learning benchmarking environment – Deep500 – they say is “the first distributed and reproducible benchmarking s Read more…

By John Russell

IBM Bets $2B Seeking 1000X AI Hardware Performance Boost

February 7, 2019

For now, AI systems are mostly machine learning-based and “narrow” – powerful as they are by today's standards, they're limited to performing a few, narro Read more…

By Doug Black

Arm Unveils Neoverse N1 Platform with up to 128-Cores

February 20, 2019

Following on its Neoverse roadmap announcement last October, Arm today revealed its next-gen Neoverse microarchitecture with compute and throughput-optimized si Read more…

By Tiffany Trader

Intel Launches Cascade Lake Xeons with Up to 56 Cores

April 2, 2019

At Intel's Data-Centric Innovation Day in San Francisco (April 2), the company unveiled its second-generation Xeon Scalable (Cascade Lake) family and debuted it Read more…

By Tiffany Trader

Announcing four new HPC capabilities in Google Cloud Platform

April 15, 2019

When you’re running compute-bound or memory-bound applications for high performance computing or large, data-dependent machine learning training workloads on Read more…

By Wyatt Gorman, HPC Specialist, Google Cloud; Brad Calder, VP of Engineering, Google Cloud; Bart Sano, VP of Platforms, Google Cloud

In Wake of Nvidia-Mellanox: Xilinx to Acquire Solarflare

April 25, 2019

With echoes of Nvidia’s recent acquisition of Mellanox, FPGA maker Xilinx has announced a definitive agreement to acquire Solarflare Communications, provider Read more…

By Doug Black

Nvidia Claims 6000x Speed-Up for Stock Trading Backtest Benchmark

May 13, 2019

A stock trading backtesting algorithm used by hedge funds to simulate trading variants has received a massive, GPU-based performance boost, according to Nvidia, Read more…

By Doug Black

  • arrow
  • Click Here for More Headlines
  • arrow
Do NOT follow this link or you will be banned from the site!
Share This