File: cpp-unit.cpp

package info (click to toggle)
binaryen 68-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 34,900 kB
  • sloc: cpp: 57,351; ansic: 3,562; python: 2,898; sh: 700; makefile: 6
file content (18 lines) | stat: -rw-r--r-- 318 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// test multiple uses of the threadPool

#include <assert.h>

#include <wasm.h>
#include <ir/cost.h>

using namespace wasm;

int main() 
{
  // Some optimizations assume that the cost of a get is zero, e.g. local-cse.
  GetLocal get;
  assert(CostAnalyzer(&get).cost == 0);

  std::cout << "Success.\n";
  return 0;
}