// Copyright 2023 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_PARALLEL_MOVE_H_ #define V8_WASM_BASELINE_PARALLEL_MOVE_H_ #include "src/wasm/baseline/liftoff-assembler.h" #include "src/wasm/baseline/liftoff-register.h" #include "src/wasm/wasm-value.h" namespace v8::internal::wasm { // ParallelMove is a utility class that encodes multiple moves from registers to // registers (`RegisterMove`), constants to registers (`RegisterLoad` with // `LoadKind::kConstant`), or stack slots to registers (other // `RegisterLoad`s). // It can handle cyclic moves, e.g., swaps between registers. // The moves are typically prepared/encoded into an instance via the high-level // entry point `Transfer`, which takes two Wasm value stack configurations // (`VarState`) as input. // Code is actually emitted to the underlying `LiftoffAssembler` only at the // end via `Execute` or implicitly in the destructor. class ParallelMove { … }; } // namespace v8::internal::wasm #endif // V8_WASM_BASELINE_PARALLEL_MOVE_H_