%PDF- <> %âãÏÓ endobj 2 0 obj <> endobj 3 0 obj <>/ExtGState<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI] >>/Annots[ 28 0 R 29 0 R] /MediaBox[ 0 0 595.5 842.25] /Contents 4 0 R/Group<>/Tabs/S>> endobj ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµùÕ5sLOšuY>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<> endobj 2 0 obj<>endobj 2 0 obj<>es 3 0 R>> endobj 2 0 obj<> ox[ 0.000000 0.000000 609.600000 935.600000]/Fi endobj 3 0 obj<> endobj 7 1 obj<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI]>>/Subtype/Form>> stream
// Copyright 2015 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. #include "src/wasm/wasm-opcodes.h" #include <array> #include "src/codegen/signature.h" #include "src/wasm/wasm-features.h" #include "src/wasm/wasm-module.h" #include "src/wasm/wasm-opcodes-inl.h" namespace v8 { namespace internal { namespace wasm { std::ostream& operator<<(std::ostream& os, const FunctionSig& sig) { if (sig.return_count() == 0) os << "v"; for (auto ret : sig.returns()) { os << ret.short_name(); } os << "_"; if (sig.parameter_count() == 0) os << "v"; for (auto param : sig.parameters()) { os << param.short_name(); } return os; } // TODO(7748): Once we have a story for JS interaction of structs/arrays, this // function should become independent of module. Remove 'module' parameter in // this function as well as all transitive callees that no longer need it // (In essence, revert // https://chromium-review.googlesource.com/c/v8/v8/+/2413251). bool IsJSCompatibleSignature(const FunctionSig* sig, const WasmModule* module, const WasmFeatures& enabled_features) { for (auto type : sig->all()) { // TODO(7748): Allow structs, arrays, and rtts when their JS-interaction is // decided on. if (type == kWasmS128 || type.is_rtt() || (type.has_index() && !module->has_signature(type.ref_index()))) { return false; } } return true; } // Define constexpr arrays. constexpr uint8_t LoadType::kLoadSizeLog2[]; constexpr ValueType LoadType::kValueType[]; constexpr MachineType LoadType::kMemType[]; constexpr uint8_t StoreType::kStoreSizeLog2[]; constexpr ValueType StoreType::kValueType[]; constexpr MachineRepresentation StoreType::kMemRep[]; } // namespace wasm } // namespace internal } // namespace v8