|
FAUST compiler
0.9.9.6b8
|
The sharing analysis of tree t is the annotation of all its subtrees t' with their number of occurences in t. More...
#include <string.h>#include <stdlib.h>#include <stdio.h>#include "shlysis.hh"#include "compatibility.hh"
Go to the source code of this file.
Functions | |
| Tree | shprkey (Tree t) |
| Create a specific property key for the sharing count of subtrees of t. More... | |
| int | shcount (Tree key, Tree t) |
| Return the value of sharing count or 0. More... | |
| static void | annotate (Tree k, Tree t, barrier foo) |
| Recursively increment the occurences count of t and its subtrees. More... | |
| static bool | nobarrier (const Tree &t) |
| Tree | shlysis (Tree t, barrier foo) |
| Do a sharing analysis : annotates all the subtrees of t with there occurences. More... | |
| Tree | shlysis (Tree t) |
| Do a sharing analysis : annotates all the subtrees of t with there occurences. More... | |
The sharing analysis of tree t is the annotation of all its subtrees t' with their number of occurences in t.
As this annotation of t' depends of a context (the tree t for which t' is a subtree) a specific property key unique to each sharing analysis must be generated.
Definition in file shlysis.cpp.
Recursively increment the occurences count of t and its subtrees.
Definition at line 129 of file shlysis.cpp.
References CTree::arity(), CTree::branch(), isRec(), setProperty(), shcount(), and tree().
Referenced by shlysis().


|
static |
Definition at line 99 of file shlysis.cpp.
Referenced by shlysis().

Return the value of sharing count or 0.
Definition at line 81 of file shlysis.cpp.
References Node::getInt(), getProperty(), and CTree::node().
Referenced by annotate().


Do a sharing analysis : annotates all the subtrees of t with there occurences.
Definition at line 105 of file shlysis.cpp.
References annotate(), and shprkey().

Do a sharing analysis : annotates all the subtrees of t with there occurences.
Definition at line 117 of file shlysis.cpp.
References annotate(), nobarrier(), and shprkey().

Create a specific property key for the sharing count of subtrees of t.
Definition at line 69 of file shlysis.cpp.
References name(), tree(), and unique().
Referenced by ScalarCompiler::sharingAnalysis(), DocCompiler::sharingAnalysis(), and shlysis().


1.8.7