Path: blob/main/contrib/llvm-project/clang/lib/Interpreter/Wasm.h
35233 views
//===------------------ Wasm.h - Wasm Interpreter ---------------*- C++ -*-===//1//2// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.3// See https://llvm.org/LICENSE.txt for license information.4// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception5//6//===----------------------------------------------------------------------===//7//8// This file implements interpreter support for code execution in WebAssembly.9//10//===----------------------------------------------------------------------===//1112#ifndef LLVM_CLANG_LIB_INTERPRETER_WASM_H13#define LLVM_CLANG_LIB_INTERPRETER_WASM_H1415#ifndef __EMSCRIPTEN__16#error "This requires emscripten."17#endif // __EMSCRIPTEN__1819#include "IncrementalExecutor.h"2021namespace clang {2223class WasmIncrementalExecutor : public IncrementalExecutor {24public:25WasmIncrementalExecutor(llvm::orc::ThreadSafeContext &TSC);2627llvm::Error addModule(PartialTranslationUnit &PTU) override;28llvm::Error removeModule(PartialTranslationUnit &PTU) override;29llvm::Error runCtors() const override;30llvm::Error cleanUp() override;3132~WasmIncrementalExecutor() override;33};3435} // namespace clang3637#endif // LLVM_CLANG_LIB_INTERPRETER_WASM_H383940