Green Marl: A DSL for Easy and Efficient Graph Analysis Sungpack - - PowerPoint PPT Presentation

green marl a dsl for easy and efficient graph analysis
SMART_READER_LITE
LIVE PREVIEW

Green Marl: A DSL for Easy and Efficient Graph Analysis Sungpack - - PowerPoint PPT Presentation

Green Marl: A DSL for Easy and Efficient Graph Analysis Sungpack Hong, Hassan Chafi, Eric Sedlar, Kunle Olukotun Presented By Albert Kim Goal Tough to write parallel graph algorithms Current graph processing frameworks force user to


slide-1
SLIDE 1

Green‐Marl: A DSL for Easy and Efficient Graph Analysis

Sungpack Hong, Hassan Chafi, Eric Sedlar, Kunle Olukotun

Presented By Albert Kim

slide-2
SLIDE 2

Goal

  • Tough to write parallel graph algorithms
  • Current graph processing frameworks force

user to rewrite their program Want a Domain Specific Language (DSL)

  • Easy to express graph algorithms
  • Expose data‐level parallelism
  • Can compile to various backends
slide-3
SLIDE 3

Sample Code

slide-4
SLIDE 4

Scope of Language

  • Graph is ordered pair of nodes and edges

– G = (N, E)

  • Each node/edge has some properties
  • Given graph and set of properties (G, ),

compute:

– A scalar – A new set of properties for each node/edge – A subgraph of original graph

slide-5
SLIDE 5

Data Structures

  • Five primitives

– Bool, Int, Long, Float, and Double

  • Collection types

– Set (unique and unordered) – Order (unique and ordered) – Sequence (not unique and ordered)

  • Special semantics when dealing with

collections in sequential/parallel context

slide-6
SLIDE 6

Data Structures (Sample)

slide-7
SLIDE 7

Operations on Collections

slide-8
SLIDE 8

Iteration/Traversal

slide-9
SLIDE 9

BFS Traversal Figure

slide-10
SLIDE 10

Parallelism in Green‐Marl

  • Inspired by OpenMP
  • Follows OpenMP’s memory consistency model

– Writing to same shared variable in concurrently may cause conflicts

slide-11
SLIDE 11

Reductions

slide-12
SLIDE 12

Overall Structure

slide-13
SLIDE 13

Compiler Optimizations: Loop Fusion

slide-14
SLIDE 14

Compiler Optimizations: Hoisting Definitions

slide-15
SLIDE 15

Compiler Optimizations: Set‐Graph Loop Fusion

slide-16
SLIDE 16

Evaluation (LOC)

slide-17
SLIDE 17

Evaluation (BC)

slide-18
SLIDE 18

Evaluation (Vertex Cover)

slide-19
SLIDE 19

My Impressions

  • Syntax is galling
slide-20
SLIDE 20

My Impressions

  • Have to deal with semantics of collections
slide-21
SLIDE 21

My Impressions

  • Have to deal with semantics of iterations

– Uses OpenMP’s weak memory consistency model – Should make it impossible to share variables

  • Have to deal with parallel workflow of

iterations

– BFS: each level is parallel – DFS: sequential – Not data‐level parallelism

slide-22
SLIDE 22

Overall Impressions

  • Like:

– Idea of DSL – Easy way to process graph (BFS traversal) – Expose data‐level parallelism (necessary) – Compiler optimizations – Portable backend – Global view: easy to work on global variables

  • Dislike: Green‐Marl’s DSL
  • Want: Higher‐Level DSL