HPC Coding: The Power of L(o)osing Control

By Tobias Weinzierl

August 16, 2018

Presented is a summary of the ISC18 workshop “The power of l(o)osing control,” which asked the question: “when does a re-implementation of mature simulation fragments with novel HPC paradigms pay off?”

Exascale roadmaps, exascale projects and exascale lobbyists ask, on-again-off-again, for a fundamental rewrite of major code building blocks. Otherwise, so they claim, codes will not scale up. Naturally, some exascale projects bombard computational scientists with new domain-specific or domain-tailored languages, compiler extensions, frameworks, libraries and programming paradigms. The projects receive, in return, rewrites of simulation codes that are significantly faster. After a while. Or they get nothing at all, as users of the all the splendid new ideas find out that the proposed is not a fit to their requirements, the wheel of exascale innovations has already turned once more, or the rewrites have been that little bit more complex and more time-consuming than anticipated so that a complete rewrite finally became unfeasible. For our methodological evangelist, developing frameworks, languages, libraries, whatever would be such a joy, if only there were no or at least competent users . . .

The ISC18 workshop “The power of l(o)osing control”, organised by Tobias Weinzierl, did ask “when does a re-implementation of mature simulation fragments with novel HPC paradigms pay off?” More precisely, the organiser did ask “where is the pain barrier where consortia are willing to rewrite major code parts?”, “to which degree are mature simulation codes willing to give up control of SIMDsation, task scheduling, data placement, and so forth?” and “what information (arithmetic intensity, affinity, dependencies) should new paradigms expect their user codes to provide explicitly to frameworks?” Some answers to these questions from the workshop are summarised below. Even more questions did arise however.

I’m so sick of rewriting my code every time a new exascale project comes around the corner.   The workshop kicked off with historical remarks by Tobias. When his software base underlying the H2020 FETHPC project ExaHyPE [1] was first developed as a heroic green-field approach, caches and careful memory usage used to be the non plus ultra. So the code was made to support extremely dynamic and adaptive meshes. Soon after, vectorisation and multicores became headliners on the center stage. This made the developers rewrite significant code parts into regular data structures fitting to parallel fors—just to learn afterwards that task-based parallelism is the new kid on the block everybody loves most. Today, the code tasks. But the developers didn’t win that much in terms of productivity, as they now have to think about proper task sizes, task priorities, mapping of tasks to MPI calls, and so forth. They feel being caught in a never-ending rewrite of core code parts as hardware and programming paradigms evolve. The code at no point had been future-proof.

We took away their scheduling ownership, now we have to get their data structures.   The actual workshop followed this introduction. It featured six talks. Nathan Ellingwood from Sandia pointed out that their Kokkos project [2] started from a few heroic research code endeavours, too. It had been after that that they started to roll their ideas out as general-purpose ecosystem for legacy codes. One of Kokkos’ key techniques to obtain scaling code goes one step beyond the rewrites Tobias did complain about: They do not only provide parallel programming constructs. They also encourage the user to model their codes explicitly in terms of abstract data structures.

Nathan’s talk pointed out that working, i.e., scaling HPC DSLs and frameworks rely on data structures plus execution patterns. Teaming them up allows middleware or runtimes to deliver performance by choosing the right data structure realisation plus concurrency for the right platform. If we only focus on parallel programming constructs, it is, to some degree, not surprising if rewrites fail to deliver.

Thomas Fahringer discussed the rationale and lessons learned through the AllScale project [3]. He opened his presentation with the statement “I don’t believe in MPI+X+Y”. And notably, he doesn’t believe in task-based programming as the silver bullet for scalability either. Going one step beyond Nathan’s talk, he proposed to re-specify all codes in terms of their data structures plus concurrency, too, but to ask a compiler to derive the tasks and parallel constructs from hereon. The abstraction of data access plus data structure is not realised within a library or runtime, but made part of the actual translator. It can then rely on many complex code optimisation techniques such as the fusion of various parallel code regions. As such, “giving up control” is not a flaw, problem or challenge. Thomas: “It is a design principle.”

Richard Bower from Durham’s Institute of Computational Cosmology (ICC) seemed to be impressed by this idea. A team around him has written a major astrophysical SPH code from scratch. The new code SWIFT [4] expresses all of its data as small work items and formalises all work on these guys as tasks with dependencies. This green-field development allows their runtime to scale up. In a way, they seem also to rely on parallelism through parallel modelling of computations plus a formalisation of the used data structures. They just did it manually.

A controversial discussion broke off. How many data structures does a programming paradigm have to offer to allow scientists to write meaningful non-toy code? State-of-the-art physics combines all types of hierarchical meshes with FFTs, particle representations, and unstructured data sets. Or do sophisticated solutions always have to give the users the choice either to work with data structure specs plus tasks or solely parallel processing constructs? In this case, we would lose some of the academic purity of “giving up control”. Or do we need approaches where the user basically constructs her data structures? We did not find an answer, but it seems that thinking in tasks plus the data they work on is the right way to go: thinking only in terms of parallel fors or tasks doesn’t go far enough.

Garbage in, garbage out.   Michael Bader presented his Chameleon project [5] and added an interesting observation to this: In his work, compute nodes may steal tasks plus their data from other ranks upon demand. Michael was able to present impressive scalability. They show that stealing leverages MPI work imbalances. Coming back to the compiler vs. runtime, it seems that a conclusion whether work decomposition should be done statically or dynamically is nowhere near. There are so many great opportunities, if systems suddenly can freely distribute their tasks in a lightweight manner also beyond shared memory borders.

Richard’s endeavour computes proper work decompositions in regular intervals which can be issued by the user, while Thomas’ and Nathan’s tools take ownership of work distribution through abstract specifications of data structures. All approaches rely on the fact that the right level of concurrency is provided, and that proper heuristics—when does decomposition pay off, e.g.—do exist. As Daniel Weingaertner from the Universidade Federal do Paran`a in the audience pointed out: The art is exactly this, to hide technical details (load distribution but also tiny little parameters such as grain sizes or pinning) from the developer. And that’s where runtimes and compilers really can help. Otherwise, developers might provide garbage input data. Michael’s approach provided a useful additional dimension: His approach hinges on online performance measurements. If the conclusion holds that many compile-time, static tunings due to heuristics are doomed to fail with the complex machines we face today, his approach still will succeed. Exaggerated: There’s no such thing as garbage in (in terms of work decomposition), but there is garbage work distribution.

We use C/C++ to improve accessibility and then suffer from the language’s restrictions and syntactic overhead.   Any new programming model is worth developing if and only if there are users. And users have to be technically able to handle these models. Nathan’s, Richard’s, Thomas’ and Tobias’ approaches therefore all rely on C/C++. It seems that this language has finally become the ultimate to-be-used language. Bye, bye Fortran.

Harald Köstler kicked off his talk with “I have to say I’m surprised all people seem to use C++”. His refreshing talk was a tour de force through various studies on DSLs in HPC. They mainly orbit around stencil and multigrid codes. The ExaStencils/ExaSlang [6] project was one of them. Now, you might disagree with Harald that languages such as Scala or Lisp should be real candidates to program your next-generation-DSL—actually the majority of the audience first considered this to be a joke—but he made valid points: C++ templates are neither easy to maintain nor to use. Yet, most DSL extensions use generic meta programming. C++ itself is not a trivial, compact language. After all, it is way too generic to meet this goal. We consider it to be straightforward as we all are used to it, but how many young students bring along the right mastery of C++ already? Finally, just start to dream about opportunities that arise once you accept that you can use Just-In-Time compilation for example or stricter type checking. Indeed, Thomas had dropped an argument along these lines before: Compilers can contextualise code and tailor it to a situation. And if they fail due to a lack of information, they can at least let the user know that they’d prefer some more annotations, e.g. He admitted that compiling and understanding C++ was a painful exercise in AllScale. So maybe C++ is not the ultimate thing after all?

These computational scientists should be forced to rewrite everything from scratch from time to time anyway—this makes them tidy up their codes.  Richard and Tobias both gave talks on bigger pieces of software. While Tobias follows an incremental approach where core routines are replaced when new technologies emerge, Richard’s endeavour is a complete rewrite of well-established physics and algorithms with a task paradigm. With Tobias being unhappy about the zombie of rewrites—they never go away—it was natural to ask Richard: was it worth it?

This is a delicate question, as obviously it took his team quite a while to deliver the new code base. This is time “lost” for “actual” science. However, he came to the conclusion that it has been worth it nevertheless. It is easy to say this once your code is up and scaling, but Richard pointed out that there are two further success implications: His team has learned a lot about software. And his team has cleaned up the code.

Whenever one starts a complete rewrite, it is very human and convenient to sit down, and try to strip a code design off its historic ballast. Complete rewrites (triggering re-thinks) improve the code quality. It is however, as Richard pointed out, almost sad to recognise that interfaces then grow and become more complex again. You start with a neat, clean design and you end up again with a complex piece of code.

The Swiss army knife is just yet another framework.  The audience just started to digest Harald’s preferences for esoteric languages, when he confessed another thing: As far as he observes, most successful DSLs rely on fast and successful libraries under the hood. So the DSL’s job is not to come up with the performance. In most projects, it is its jobs to make the performance available to the user. Nathan had clarified before that Kokkos relies on BLAS et al., while Thomas’ talk did support this impression, too: His compiler also relies on libraries for performance-critical tasks. These observations relax the burden of scalability for DSLs.

In this context, Martin Kronbichler collected some ideas and lessons learned how to make a general-purpose library underlying many different codes perform. His work around deal.II [7] focuses on particular mesh types with “only” particular mesh entities and tensor-product styles, while deal.II provides manufactured data iterators and operators for popular operations. deal.II might not be a classic DSL, as it is very versatile. However, his work on purpose exploits particular characteristics and specialisations to get the whole thing fast.

Richard’s observation that their task system is tailored towards their particular application started some arguments around the question “what is a framework”? Many frameworks or libraries are probably not worth calling them that way, as they are effectively written for one particular purpose. Their programmers might claim that they are generic—they are computer scientists after all—but, at the end of the day, what they call frameworks simply realise plain functional decomposition. Different components in one piece of software do different things.

It was not clear among the workshop participants to which degree frameworks and DSLs had to be generic. Even the other way round, one might come to the conclusion that frameworks have to grow and evolve with their applications and deliver exactly the level of flexibility an actual project needs. Richard and Harald for example pointed out that they both look into structured vs. unstructured data structures or the decision when to store data as AoS or SoA. Some evergreens never disappear.

A few more implications from this project-framework co-design approach were discussed next: Richard clarified that starting from scratch is the easy part. The difficult part is to stop. Once a team has written component i itself—this will be the ultimate fit to the project— there is this temptation to write component i+1 as well. We did it for the mesh, why not also write our own load balancing? And the load balancing worked out really well (indeed it is an exact fit to our project though we are not really competitive with state-of-the-art libraries), wouldn’t it be clever to come up with our own few linear equation system solvers? And so forth . . . Perhaps the framework hasn’t been there in the first place. It grew and noone told it to stop. If this were the case, the term framework would describe a flaw rather than a cool computer science thing.

Come on, love me for the money.  Let’s forget about such heretic ideas and close the discussion with two observations. The first one was made by Richard and explicitly stated by Nathan: Their ecosystems started to flourish once they provided the right tools. Task graph plotters for task-based systems are an example. The best concept might be hard to digest if you don’t give developers the right tools that allow them to develop economically. The Kokkos and the deal.II team added the second mandatory ingredient for success: a reasonable user base and active engagement with that very base.

Both items highlight that continuous, long-term funding is essential for a successful introduction of (exascale) programming paradigms, runtimes, DSLs, compilers and frameworks. Consortia need the time and resources to build up a development ecosystem around any new programming concept and to equip them with the right tools. Establishing this does not materialise in immediate scientific output, and, at the same time, it has to start way before actual computational science can be made through a new paradigm. Well, finally there had been broad agreement among all workshop participants: The establishment of a community and ecosystem is something that requires resources, but it neither fits to standard projects of short and medium duration, nor to our project notion, which has to start from the computational challenge. In an ideal world, the ecosystem has to be there before to allow application specialists to assess it and to move into a mature environment to solve “their” problem. There should thus be more funding for the ecosystem not tied to particular application research questions.

About the Author

Tobias Weinzierl is Associate Professor at the Department of Computer Science at Durham University. His work orbits around novel algorithms and clever implementations for applications from scientific computing which employ state-of-the-art physics and mathematics. At the moment, his research focuses mainly on data flow/movement (minimisation), data structure (organisation) and programming paradigm challenges. He is particularly interested in dynamically adaptive multiscale methods based upon spacetrees that interact with multigrid solvers for elliptic and parabolic partial differential equations, that host particle systems with particles of varying cut-off radii or size, or carry Finite Volume-alike discretisations. He is involved in multiple scientific open source projects such as ExaHyPE [1] and Peano [8].

References
[1] ExaHyPE—an Exascale Hyperbolic PDE Engine. http://exahype.eu
[2] Kokkos—The C++ Performance Portability Programming Model. https://github.com/kokkos/kokkos/wiki
[3] AllScale—An Exascale Programming, Multi-objective Optimisation and Resilience Management Environment Based on Nested Recursive Parallelism. http://www.allscale.eu
[4] SWIFT—SPH With Inter-dependent Fine-grain Tasking. http://icc.dur.ac.uk/swift
[5] Chameleon—Eine Taskbasierte Programmierumgebung zur Entwicklung reaktiver HPC Anwendungen. http://www.chameleon-hpc.org
[6] Exastencils—Advanced Stencil-Code Engineering. http://www.exastencils.org
[7] deal.II—an open source finite element library. https://www.dealii.org
[8] Peano—a framework for dynamically adaptive Cartesian meshes. http://www.peanoframework.org

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!

Supercomputer Simulations Validate NASA Crash Testing

February 17, 2020

Car crash simulation is already a challenging supercomputing task, requiring pinpoint estimation of how hundreds of components interact with turbulent forces and human bodies. Spacecraft crash simulation is far more diff Read more…

By Oliver Peckham

What’s New in HPC Research: Quantum Clouds, Interatomic Models, Genetic Algorithms & More

February 14, 2020

In this bimonthly feature, HPCwire highlights newly published research in the high-performance computing community and related domains. From parallel programming to exascale to quantum computing, the details are here. Read more…

By Oliver Peckham

The Massive GPU Cloudburst Experiment Plays a Smaller, More Productive Encore

February 13, 2020

In November, researchers at the San Diego Supercomputer Center (SDSC) and the IceCube Particle Astrophysics Center (WIPAC) set out to break the internet – or at least, pull off the cloud HPC equivalent. As part of thei Read more…

By Oliver Peckham

ORNL Team Develops AI-based Cancer Text Mining Tool on Summit

February 13, 2020

A group of Oak Ridge National Laboratory researchers working on the Summit supercomputer has developed a new neural network tool for fast extraction of information from cancer pathology reports to speed research and clin Read more…

By John Russell

Nature Serves up Another Challenge to Quantum Computing?

February 13, 2020

Just when you thought it was safe to assume quantum computing – though distant – would eventually succumb to clever technology, another potentially confounding factor pops up. It’s the Heisenberg Limit (HL), close Read more…

By John Russell

AWS Solution Channel

Challenging the barriers to High Performance Computing in the Cloud

Cloud computing helps democratize High Performance Computing by placing powerful computational capabilities in the hands of more researchers, engineers, and organizations who may lack access to sufficient on-premises infrastructure. Read more…

IBM Accelerated Insights

Intelligent HPC – Keeping Hard Work at Bay(es)

Since the dawn of time, humans have looked for ways to make their lives easier. Over the centuries human ingenuity has given us inventions such as the wheel and simple machines – which help greatly with tasks that would otherwise be extremely laborious. Read more…

Researchers Enlist Three Supercomputers to Apply Deep Learning to Extreme Weather

February 12, 2020

When it comes to extreme weather, an errant forecast can have serious effects. While advance warning can give people time to prepare for the weather as it did with the polar vortex last year, the absence of accurate adva Read more…

By Oliver Peckham

The Massive GPU Cloudburst Experiment Plays a Smaller, More Productive Encore

February 13, 2020

In November, researchers at the San Diego Supercomputer Center (SDSC) and the IceCube Particle Astrophysics Center (WIPAC) set out to break the internet – or Read more…

By Oliver Peckham

Eni to Retake Industry HPC Crown with Launch of HPC5

February 12, 2020

With the launch of its Dell-built HPC5 system, Italian energy company Eni regains its position atop the industrial supercomputing leaderboard. At 52-petaflops p Read more…

By Tiffany Trader

Trump Budget Proposal Again Slashes Science Spending

February 11, 2020

President Donald Trump’s FY2021 U.S. Budget, submitted to Congress this week, again slashes science spending. It’s a $4.8 trillion statement of priorities, Read more…

By John Russell

Policy: Republicans Eye Bigger Science Budgets; NSF Celebrates 70th, Names Idea Machine Winners

February 5, 2020

It’s a busy week for science policy. Yesterday, the National Science Foundation announced winners of its 2026 Idea Machine contest seeking directions for futu Read more…

By John Russell

Fujitsu A64FX Supercomputer to Be Deployed at Nagoya University This Summer

February 3, 2020

Japanese tech giant Fujitsu announced today that it will supply Nagoya University Information Technology Center with the first commercial supercomputer powered Read more…

By Tiffany Trader

Intel Stopping Nervana Development to Focus on Habana AI Chips

February 3, 2020

Just two months after acquiring Israeli AI chip start-up Habana Labs for $2 billion, Intel is stopping development of its existing Nervana neural network proces Read more…

By John Russell

Lise Supercomputer, Part of HLRN-IV, Begins Operations

January 29, 2020

The second phase of the build-out of HLRN-IV – the planned 16 peak-petaflops supercomputer serving the North-German Supercomputing Alliance (HLRN) – is unde Read more…

By Staff report

IBM Debuts IC922 Power Server for AI Inferencing and Data Management

January 28, 2020

IBM today launched a Power9-based inference server – the IC922 – that features up to six Nvidia T4 GPUs, PCIe Gen 4 and OpenCAPI connectivity, and can accom Read more…

By John Russell

Julia Programming’s Dramatic Rise in HPC and Elsewhere

January 14, 2020

Back in 2012 a paper by four computer scientists including Alan Edelman of MIT introduced Julia, A Fast Dynamic Language for Technical Computing. At the time, t Read more…

By John Russell

Cray, Fujitsu Both Bringing Fujitsu A64FX-based Supercomputers to Market in 2020

November 12, 2019

The number of top-tier HPC systems makers has shrunk due to a steady march of M&A activity, but there is increased diversity and choice of processing compon Read more…

By Tiffany Trader

SC19: IBM Changes Its HPC-AI Game Plan

November 25, 2019

It’s probably fair to say IBM is known for big bets. Summit supercomputer – a big win. Red Hat acquisition – looking like a big win. OpenPOWER and Power processors – jury’s out? At SC19, long-time IBMer Dave Turek sketched out a different kind of bet for Big Blue – a small ball strategy, if you’ll forgive the baseball analogy... Read more…

By John Russell

Intel Debuts New GPU – Ponte Vecchio – and Outlines Aspirations for oneAPI

November 17, 2019

Intel today revealed a few more details about its forthcoming Xe line of GPUs – the top SKU is named Ponte Vecchio and will be used in Aurora, the first plann Read more…

By John Russell

Dell Ramps Up HPC Testing of AMD Rome Processors

October 21, 2019

Dell Technologies is wading deeper into the AMD-based systems market with a growing evaluation program for the latest Epyc (Rome) microprocessors from AMD. In a Read more…

By John Russell

IBM Unveils Latest Achievements in AI Hardware

December 13, 2019

“The increased capabilities of contemporary AI models provide unprecedented recognition accuracy, but often at the expense of larger computational and energet Read more…

By Oliver Peckham

SC19: Welcome to Denver

November 17, 2019

A significant swath of the HPC community has come to Denver for SC19, which began today (Sunday) with a rich technical program. As is customary, the ribbon cutt Read more…

By Tiffany Trader

D-Wave’s Path to 5000 Qubits; Google’s Quantum Supremacy Claim

September 24, 2019

On the heels of IBM’s quantum news last week come two more quantum items. D-Wave Systems today announced the name of its forthcoming 5000-qubit system, Advantage (yes the name choice isn’t serendipity), at its user conference being held this week in Newport, RI. Read more…

By John Russell

Leading Solution Providers

SC 2019 Virtual Booth Video Tour

AMD
AMD
ASROCK RACK
ASROCK RACK
AWS
AWS
CEJN
CJEN
CRAY
CRAY
DDN
DDN
DELL EMC
DELL EMC
IBM
IBM
MELLANOX
MELLANOX
ONE STOP SYSTEMS
ONE STOP SYSTEMS
PANASAS
PANASAS
SIX NINES IT
SIX NINES IT
VERNE GLOBAL
VERNE GLOBAL
WEKAIO
WEKAIO

Jensen Huang’s SC19 – Fast Cars, a Strong Arm, and Aiming for the Cloud(s)

November 20, 2019

We’ve come to expect Nvidia CEO Jensen Huang’s annual SC keynote to contain stunning graphics and lively bravado (with plenty of examples) in support of GPU Read more…

By John Russell

Fujitsu A64FX Supercomputer to Be Deployed at Nagoya University This Summer

February 3, 2020

Japanese tech giant Fujitsu announced today that it will supply Nagoya University Information Technology Center with the first commercial supercomputer powered Read more…

By Tiffany Trader

51,000 Cloud GPUs Converge to Power Neutrino Discovery at the South Pole

November 22, 2019

At the dead center of the South Pole, thousands of sensors spanning a cubic kilometer are buried thousands of meters beneath the ice. The sensors are part of Ic Read more…

By Oliver Peckham

Top500: US Maintains Performance Lead; Arm Tops Green500

November 18, 2019

The 54th Top500, revealed today at SC19, is a familiar list: the U.S. Summit (ORNL) and Sierra (LLNL) machines, offering 148.6 and 94.6 petaflops respectively, Read more…

By Tiffany Trader

Azure Cloud First with AMD Epyc Rome Processors

November 6, 2019

At Ignite 2019 this week, Microsoft's Azure cloud team and AMD announced an expansion of their partnership that began in 2017 when Azure debuted Epyc-backed instances for storage workloads. The fourth-generation Azure D-series and E-series virtual machines previewed at the Rome launch in August are now generally available. Read more…

By Tiffany Trader

Intel’s New Hyderabad Design Center Targets Exascale Era Technologies

December 3, 2019

Intel's Raja Koduri was in India this week to help launch a new 300,000 square foot design and engineering center in Hyderabad, which will focus on advanced com Read more…

By Tiffany Trader

In Memoriam: Steve Tuecke, Globus Co-founder

November 4, 2019

HPCwire is deeply saddened to report that Steve Tuecke, longtime scientist at Argonne National Lab and University of Chicago, has passed away at age 52. Tuecke Read more…

By Tiffany Trader

Cray Debuts ClusterStor E1000 Finishing Remake of Portfolio for ‘Exascale Era’

October 30, 2019

Cray, now owned by HPE, today introduced the ClusterStor E1000 storage platform, which leverages Cray software and mixes hard disk drives (HDD) and flash memory Read more…

By John Russell

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