futhark-0.16.3: An optimising compiler for a functional, array-oriented language.

Futhark.Analysis.CallGraph

Description

This module exports functionality for generating a call graph of an Futhark program.

Synopsis

# Documentation

data CallGraph Source #

The call graph is a mapping from a function name, i.e., the caller, to a set of the names of functions called *directly* (not transitively!) by the function.

We keep track separately of the functions called by constants.

buildCallGraph prog build the program's call graph.

Is the given function known to the call graph?

Does the first function call the second?

Is the function called in any of the constants?

All functions called by this function.

The set of all functions that are called noinline somewhere, or have a noinline attribute on their definition.