liftoff-compiler.h 949 Bytes
Newer Older
1 2 3 4 5 6 7
// Copyright 2018 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef V8_WASM_BASELINE_LIFTOFF_COMPILER_H_
#define V8_WASM_BASELINE_LIFTOFF_COMPILER_H_

8
#include "src/base/macros.h"
9 10 11

namespace v8 {
namespace internal {
12 13 14

class Counters;

15 16
namespace wasm {

17
struct CompilationEnv;
18
struct FunctionBody;
19
class WasmCompilationUnit;
20
struct WasmFeatures;
21

22 23 24
class LiftoffCompilationUnit final {
 public:
  explicit LiftoffCompilationUnit(WasmCompilationUnit* wasm_unit)
25
      : wasm_unit_(wasm_unit) {}
26

27 28
  bool ExecuteCompilation(CompilationEnv*, const FunctionBody&, Counters*,
                          WasmFeatures* detected);
29 30 31

 private:
  WasmCompilationUnit* const wasm_unit_;
32

33 34 35 36 37 38 39 40
  DISALLOW_COPY_AND_ASSIGN(LiftoffCompilationUnit);
};

}  // namespace wasm
}  // namespace internal
}  // namespace v8

#endif  // V8_WASM_BASELINE_LIFTOFF_COMPILER_H_