chromium/v8/src/compiler/linkage.cc

// Copyright 2014 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/compiler/linkage.h"

#include "src/codegen/assembler-inl.h"
#include "src/codegen/macro-assembler.h"
#include "src/codegen/optimized-compilation-info.h"
#include "src/compiler/frame.h"
#include "src/compiler/globals.h"
#include "src/compiler/osr.h"
#include "src/compiler/pipeline.h"

#if V8_ENABLE_WEBASSEMBLY
#include "src/compiler/wasm-compiler-definitions.h"
#endif

namespace v8 {
namespace internal {
namespace compiler {

namespace {

// Offsets from callee to caller frame, in slots.
constexpr int kFirstCallerSlotOffset =;
constexpr int kNoCallerSlotOffset =;

inline LinkageLocation regloc(Register reg, MachineType type) {}

inline LinkageLocation regloc(DoubleRegister reg, MachineType type) {}

}  // namespace


std::ostream& operator<<(std::ostream& os, const CallDescriptor::Kind& k) {}


std::ostream& operator<<(std::ostream& os, const CallDescriptor& d) {}

MachineSignature* CallDescriptor::GetMachineSignature(Zone* zone) const {}

int CallDescriptor::GetStackParameterDelta(
    CallDescriptor const* tail_caller) const {}

int CallDescriptor::GetOffsetToFirstUnusedStackSlot() const {}

int CallDescriptor::GetOffsetToReturns() const {}

uint32_t CallDescriptor::GetTaggedParameterSlots() const {}

bool CallDescriptor::CanTailCall(const CallDescriptor* callee) const {}

// TODO(jkummerow, sigurds): Arguably frame size calculation should be
// keyed on code/frame type, not on CallDescriptor kind. Think about a
// good way to organize this logic.
int CallDescriptor::CalculateFixedFrameSize(CodeKind code_kind) const {}

EncodedCSignature CallDescriptor::ToEncodedCSignature() const {}

void CallDescriptor::ComputeParamCounts() const {}

#if V8_ENABLE_WEBASSEMBLY
namespace {
CallDescriptor* ReplaceTypeInCallDescriptorWith(
    Zone* zone, const CallDescriptor* call_descriptor, size_t num_replacements,
    MachineType from, MachineType to) {}
}  // namespace

CallDescriptor* GetI32WasmCallDescriptor(
    Zone* zone, const CallDescriptor* call_descriptor) {}
#endif

CallDescriptor* Linkage::ComputeIncoming(Zone* zone,
                                         OptimizedCompilationInfo* info) {}


// static
bool Linkage::NeedsFrameStateInput(Runtime::FunctionId function) {}

CallDescriptor* Linkage::GetRuntimeCallDescriptor(
    Zone* zone, Runtime::FunctionId function_id, int js_parameter_count,
    Operator::Properties properties, CallDescriptor::Flags flags,
    LazyDeoptOnThrow lazy_deopt_on_throw) {}

CallDescriptor* Linkage::GetCEntryStubCallDescriptor(
    Zone* zone, int return_count, int js_parameter_count,
    const char* debug_name, Operator::Properties properties,
    CallDescriptor::Flags flags, StackArgumentOrder stack_order) {}

CallDescriptor* Linkage::GetJSCallDescriptor(Zone* zone, bool is_osr,
                                             int js_parameter_count,
                                             CallDescriptor::Flags flags,
                                             Operator::Properties properties) {}

// TODO(turbofan): cache call descriptors for code stub calls.
// TODO(jgruber): Clean up stack parameter count handling. The descriptor
// already knows the formal stack parameter count and ideally only additional
// stack parameters should be passed into this method. All call-sites should
// be audited for correctness (e.g. many used to assume a stack parameter count
// of 0).
CallDescriptor* Linkage::GetStubCallDescriptor(
    Zone* zone, const CallInterfaceDescriptor& descriptor,
    int stack_parameter_count, CallDescriptor::Flags flags,
    Operator::Properties properties, StubCallMode stub_mode) {}

// static
CallDescriptor* Linkage::GetBytecodeDispatchCallDescriptor(
    Zone* zone, const CallInterfaceDescriptor& descriptor,
    int stack_parameter_count) {}

LinkageLocation Linkage::GetOsrValueLocation(int index) const {}

namespace {
inline bool IsTaggedReg(const LinkageLocation& loc, Register reg) {}
}  // namespace

bool Linkage::ParameterHasSecondaryLocation(int index) const {}

LinkageLocation Linkage::GetParameterSecondaryLocation(int index) const {}


}  // namespace compiler
}  // namespace internal
}  // namespace v8