Repository logo

Infoscience

  • English
  • French
Log In
Logo EPFL, École polytechnique fédérale de Lausanne

Infoscience

  • English
  • French
Log In
  1. Home
  2. Academic and Research Output
  3. Journal articles
  4. Spiral in Scala: Towards the Systematic Construction of Generators for Performance Libraries
 
research article

Spiral in Scala: Towards the Systematic Construction of Generators for Performance Libraries

Ofenbeck, Georg
•
Rompf, Tiark  
•
Stojanov, Alen
Show more
2014
ACM SIGPLAN Notices

Program generators for high performance libraries are an appealing solution to the recurring problem of porting and optimizing code with every new processor generation, but only few such generators exist to date. This is due to not only the difficulty of the design, but also of the actual implementation, which often results in an ad-hoc collection of standalone programs and scripts that are hard to extend, maintain, or reuse. In this paper we ask whether and which programming language concepts and features are needed to enable a more systematic construction of such generators. The systematic approach we advocate extrapolates from existing generators: a) describing the problem and algorithmic knowledge using one, or several, domain-specific languages (DSLs), b) expressing optimizations and choices as rewrite rules on DSL programs, c) designing data structures that can be configured to control the type of code that is generated and the data representation used, and d) using autotuning to select the best-performing alternative. As a case study, we implement a small, but representative subset of Spiral in Scala using the Lightweight Modular Staging (LMS) framework. The first main contribution of this paper is the realization of c) using type classes to abstract over staging decisions, i.e. which pieces of a computation are performed immediately and for which pieces code is generated. Specifically, we abstract over different complex data representations jointly with different code representations including generating loops versus unrolled code with scalar replacement-a crucial and usually tedious performance transformation. The second main contribution is to provide full support for a) and d) within the LMS framework: we extend LMS to support translation between different DSLs and autotuning through search.

  • Details
  • Metrics
Type
research article
DOI
10.1145/2517208.2517228
Web of Science ID

WOS:000338625500015

Author(s)
Ofenbeck, Georg
Rompf, Tiark  
Stojanov, Alen
Odersky, Martin  
Pueschel, Markus
Date Issued

2014

Publisher

Assoc Computing Machinery

Published in
ACM SIGPLAN Notices
Volume

49

Issue

3

Start page

125

End page

134

Subjects

Synthesis

•

Abstraction over Staging

•

Selective Precomputation

•

Scalar Replacement

•

Data Representation

Editorial or Peer reviewed

REVIEWED

Written at

EPFL

EPFL units
LAMP1  
Available on Infoscience
August 29, 2014
Use this identifier to reference this record
https://infoscience.epfl.ch/handle/20.500.14299/106099
Logo EPFL, École polytechnique fédérale de Lausanne
  • Contact
  • infoscience@epfl.ch

  • Follow us on Facebook
  • Follow us on Instagram
  • Follow us on LinkedIn
  • Follow us on X
  • Follow us on Youtube
AccessibilityLegal noticePrivacy policyCookie settingsEnd User AgreementGet helpFeedback

Infoscience is a service managed and provided by the Library and IT Services of EPFL. © EPFL, tous droits réservés