summaryrefslogtreecommitdiff
path: root/test/binaryen.js/inlining-options.js.txt
blob: 91d3604499fc0f9fefc2101290f89e368697d6e1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
// beginning a Binaryen API trace
#include <math.h>
#include <map>
#include "binaryen-c.h"
int main() {
  std::map<size_t, BinaryenType> types;
  std::map<size_t, BinaryenExpressionRef> expressions;
  std::map<size_t, BinaryenFunctionRef> functions;
  std::map<size_t, BinaryenGlobalRef> globals;
  std::map<size_t, BinaryenEventRef> events;
  std::map<size_t, BinaryenExportRef> exports;
  std::map<size_t, RelooperBlockRef> relooperBlocks;
  std::map<size_t, ExpressionRunnerRef> expressionRunners;
  BinaryenModuleRef the_module = NULL;
  RelooperRef the_relooper = NULL;
  BinaryenGetAlwaysInlineMaxSize();
// alwaysInlineMaxSize=2
  BinaryenSetAlwaysInlineMaxSize(11);
  BinaryenGetAlwaysInlineMaxSize();
  BinaryenGetFlexibleInlineMaxSize();
// flexibleInlineMaxSize=20
  BinaryenSetFlexibleInlineMaxSize(22);
  BinaryenGetFlexibleInlineMaxSize();
  BinaryenGetOneCallerInlineMaxSize();
// oneCallerInlineMaxSize=15
  BinaryenSetOneCallerInlineMaxSize(33);
  BinaryenGetOneCallerInlineMaxSize();
  return 0;
}
// ending a Binaryen API trace