v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
v8::internal::maglev::ValueNode Class Reference

#include <maglev-ir.h>

Inheritance diagram for v8::internal::maglev::ValueNode:
Collaboration diagram for v8::internal::maglev::ValueNode:

Classes

struct  LiveRange
 

Public Member Functions

ValueLocationresult ()
 
const ValueLocationresult () const
 
int use_count () const
 
bool is_used () const
 
bool unused_inputs_were_visited () const
 
void add_use ()
 
void remove_use ()
 
void mark_unused_inputs_visited ()
 
void SetHint (compiler::InstructionOperand hint)
 
void ClearHint ()
 
bool has_hint ()
 
template<typename RegisterT >
RegisterT GetRegisterHint ()
 
const compiler::InstructionOperandhint () const
 
bool is_loadable () const
 
bool is_spilled () const
 
void SetNoSpill ()
 
void SetConstantLocation ()
 
void LoadToRegister (MaglevAssembler *, Register)
 
void LoadToRegister (MaglevAssembler *, DoubleRegister)
 
void DoLoadToRegister (MaglevAssembler *, Register)
 
void DoLoadToRegister (MaglevAssembler *, DoubleRegister)
 
DirectHandle< ObjectReify (LocalIsolate *isolate) const
 
void Spill (compiler::AllocatedOperand operand)
 
compiler::AllocatedOperand spill_slot () const
 
compiler::InstructionOperand loadable_slot () const
 
void record_next_use (NodeIdT id, InputLocation *input_location)
 
bool has_valid_live_range () const
 
LiveRange live_range () const
 
NodeIdT current_next_use () const
 
void advance_next_use (NodeIdT use)
 
bool has_no_more_uses () const
 
constexpr bool use_double_register () const
 
constexpr bool is_tagged () const
 
constexpr bool decompresses_tagged_result () const
 
constexpr ValueRepresentation value_representation () const
 
constexpr MachineRepresentation GetMachineRepresentation () const
 
void InitializeRegisterData ()
 
void AddRegister (Register reg)
 
void AddRegister (DoubleRegister reg)
 
void RemoveRegister (Register reg)
 
void RemoveRegister (DoubleRegister reg)
 
template<typename T >
RegListBase< TClearRegisters ()
 
int num_registers () const
 
bool has_register () const
 
bool is_in_register (Register reg) const
 
bool is_in_register (DoubleRegister reg) const
 
template<typename T >
RegListBase< Tresult_registers ()
 
compiler::InstructionOperand allocation () const
 
template<>
RegList ClearRegisters ()
 
template<>
DoubleRegList ClearRegisters ()
 
- Public Member Functions inherited from v8::internal::maglev::Node
ValueLocationresult ()
 
- Public Member Functions inherited from v8::internal::maglev::NodeBase
constexpr Opcode opcode () const
 
constexpr OpProperties properties () const
 
void set_properties (OpProperties properties)
 
void set_input (int index, ValueNode *node)
 
template<class T >
constexpr bool Is () const
 
template<class T >
constexpr TCast ()
 
template<class T >
constexpr const TCast () const
 
template<class T >
constexpr TTryCast ()
 
template<class T >
constexpr const TTryCast () const
 
constexpr bool has_inputs () const
 
constexpr int input_count () const
 
constexpr Inputinput (int index)
 
constexpr const Inputinput (int index) const
 
std::optional< int32_t > TryGetInt32ConstantInput (int index)
 
constexpr auto begin ()
 
constexpr auto end ()
 
constexpr bool has_id () const
 
constexpr NodeIdT id () const
 
void set_id (NodeIdT id)
 
template<typename RegisterT >
uint8_t num_temporaries_needed () const
 
template<typename RegisterT >
RegListBase< RegisterT > & temporaries ()
 
RegListgeneral_temporaries ()
 
DoubleRegListdouble_temporaries ()
 
template<typename RegisterT >
void assign_temporaries (RegListBase< RegisterT > list)
 
template<typename Function >
void ForAllInputsInRegallocAssignmentOrder (Function &&f)
 
void Print (std::ostream &os, MaglevGraphLabeller *, bool skip_targets=false) const
 
void Print () const
 
EagerDeoptInfoeager_deopt_info ()
 
LazyDeoptInfolazy_deopt_info ()
 
const RegisterSnapshotregister_snapshot () const
 
ExceptionHandlerInfoexception_handler_info ()
 
void set_register_snapshot (RegisterSnapshot snapshot)
 
void change_input (int index, ValueNode *node)
 
void change_representation (ValueRepresentation new_repr)
 
void set_opcode (Opcode new_opcode)
 
void CopyEagerDeoptInfoOf (NodeBase *other, Zone *zone)
 
void SetEagerDeoptInfo (Zone *zone, DeoptFrame deopt_frame, compiler::FeedbackSource feedback_to_update=compiler::FeedbackSource())
 
template<typename NodeT >
void OverwriteWith ()
 
void OverwriteWith (Opcode new_opcode, std::optional< OpProperties > maybe_new_properties=std::nullopt)
 
void OverwriteWithIdentityTo (ValueNode *node)
 
auto options () const
 
void ClearUnstableNodeAspects (KnownNodeAspects &)
 
void ClearElementsProperties (KnownNodeAspects &)
 
void set_owner (BasicBlock *block)
 
BasicBlockowner () const
 
void InitTemporaries ()
 
template<>
constexpr bool Is () const
 
template<>
constexpr bool Is () const
 
template<>
constexpr bool Is () const
 
template<>
constexpr bool Is () const
 
template<>
constexpr bool Is () const
 
template<>
constexpr bool Is () const
 
- Public Member Functions inherited from v8::internal::ZoneObject
void * operator new (size_t, Zone *)=delete
 
void * operator new (size_t size, void *ptr)
 
void operator delete (void *, size_t)
 
void operator delete (void *pointer, Zone *zone)=delete
 

Protected Types

using ReservedField = void
 
- Protected Types inherited from v8::internal::maglev::NodeBase
using ReservedField = InputCountField::Next<bool, 1>
 
template<class T , int size>
using NextBitField = ReservedField::Next<T, size>
 

Protected Member Functions

 ValueNode (uint64_t bitfield)
 
int FirstRegisterCode () const
 
NodeIdT start_id () const
 
- Protected Member Functions inherited from v8::internal::maglev::Node
 NodeBase (uint64_t bitfield)
 
- Protected Member Functions inherited from v8::internal::maglev::NodeBase
 NodeBase (uint64_t bitfield)
 
constexpr uint64_t bitfield () const
 
void set_bitfield (uint64_t new_bitfield)
 
constexpr Inputinput_base ()
 
constexpr const Inputinput_base () const
 
Inputlast_input ()
 
const Inputlast_input () const
 
Address last_input_address () const
 
void initialize_input_null (int index)
 
void reduce_input_count (int num=1)
 
void set_temporaries_needed (uint8_t value)
 
void set_double_temporaries_needed (uint8_t value)
 
void RequireSpecificTemporary (Register reg)
 
void RequireSpecificDoubleTemporary (DoubleRegister reg)
 

Protected Attributes

NodeIdT end_id_ = kInvalidNodeId
 
NodeIdT next_use_ = kInvalidNodeId
 
ValueLocation result_
 
union { 
 
   RegList   registers_with_result_ 
 
   DoubleRegList   double_registers_with_result_ 
 
};  
 
union { 
 
   NodeIdT *   last_uses_next_use_id_ 
 
   compiler::InstructionOperand   spill_ 
 
};  
 
compiler::InstructionOperand hint_
 
int use_count_
 

Private Types

using TaggedResultNeedsDecompressField = NodeBase::ReservedField
 

Additional Inherited Members

- Public Types inherited from v8::internal::maglev::NodeBase
enum class  InputAllocationPolicy { kFixedRegister , kArbitraryRegister , kAny }
 
- Static Public Member Functions inherited from v8::internal::maglev::Node
static constexpr bool participate_in_cse (Opcode op)
 
static constexpr bool needs_epoch_check (Opcode op)
 
- Static Public Member Functions inherited from v8::internal::maglev::NodeBase
template<class Derived , typename... Args>
static Derived * New (Zone *zone, std::initializer_list< ValueNode * > inputs, Args &&... args)
 
template<class Derived , typename... Args>
static Derived * New (Zone *zone, size_t input_count, Args &&... args)
 
- Static Public Attributes inherited from v8::internal::maglev::NodeBase
template<class T >
static constexpr Opcode opcode_of = detail::opcode_of_helper<T>::value
 
static constexpr OpProperties kProperties
 
- Static Protected Attributes inherited from v8::internal::maglev::NodeBase
static constexpr int kMaxInputs = InputCountField::kMax
 

Detailed Description

Definition at line 2418 of file maglev-ir.h.

Member Typedef Documentation

◆ ReservedField

Definition at line 2423 of file maglev-ir.h.

◆ TaggedResultNeedsDecompressField

Constructor & Destructor Documentation

◆ ValueNode()

v8::internal::maglev::ValueNode::ValueNode ( uint64_t bitfield)
inlineexplicitprotected

Definition at line 2669 of file maglev-ir.h.

Here is the call graph for this function:

Member Function Documentation

◆ add_use()

void v8::internal::maglev::ValueNode::add_use ( )
inline

Definition at line 2436 of file maglev-ir.h.

Here is the caller graph for this function:

◆ AddRegister() [1/2]

void v8::internal::maglev::ValueNode::AddRegister ( DoubleRegister reg)
inline

Definition at line 2609 of file maglev-ir.h.

Here is the call graph for this function:

◆ AddRegister() [2/2]

void v8::internal::maglev::ValueNode::AddRegister ( Register reg)
inline

Definition at line 2605 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ advance_next_use()

void v8::internal::maglev::ValueNode::advance_next_use ( NodeIdT use)
inline

Definition at line 2538 of file maglev-ir.h.

Here is the call graph for this function:

◆ allocation()

compiler::InstructionOperand v8::internal::maglev::ValueNode::allocation ( ) const
inline

Definition at line 2658 of file maglev-ir.h.

Here is the call graph for this function:

◆ ClearHint()

void v8::internal::maglev::ValueNode::ClearHint ( )
inline

Definition at line 2455 of file maglev-ir.h.

◆ ClearRegisters() [1/3]

template<typename T >
RegListBase< T > v8::internal::maglev::ValueNode::ClearRegisters ( )
inline

◆ ClearRegisters() [2/3]

template<>
RegList v8::internal::maglev::ValueNode::ClearRegisters ( )
inline

Definition at line 2738 of file maglev-ir.h.

Here is the call graph for this function:

◆ ClearRegisters() [3/3]

template<>
DoubleRegList v8::internal::maglev::ValueNode::ClearRegisters ( )
inline

Definition at line 2744 of file maglev-ir.h.

Here is the call graph for this function:

◆ current_next_use()

NodeIdT v8::internal::maglev::ValueNode::current_next_use ( ) const
inline

Definition at line 2534 of file maglev-ir.h.

Here is the caller graph for this function:

◆ decompresses_tagged_result()

bool v8::internal::maglev::ValueNode::decompresses_tagged_result ( ) const
inlineconstexpr

Definition at line 2574 of file maglev-ir.h.

◆ DoLoadToRegister() [1/2]

void v8::internal::maglev::ValueNode::DoLoadToRegister ( MaglevAssembler * ,
DoubleRegister  )

◆ DoLoadToRegister() [2/2]

void v8::internal::maglev::ValueNode::DoLoadToRegister ( MaglevAssembler * ,
Register  )

◆ FirstRegisterCode()

int v8::internal::maglev::ValueNode::FirstRegisterCode ( ) const
inlineprotected

Definition at line 2682 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetMachineRepresentation()

MachineRepresentation v8::internal::maglev::ValueNode::GetMachineRepresentation ( ) const
inlineconstexpr

Definition at line 2581 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetRegisterHint()

template<typename RegisterT >
RegisterT v8::internal::maglev::ValueNode::GetRegisterHint ( )
inline

Definition at line 2460 of file maglev-ir.h.

◆ has_hint()

bool v8::internal::maglev::ValueNode::has_hint ( )
inline

Definition at line 2457 of file maglev-ir.h.

◆ has_no_more_uses()

bool v8::internal::maglev::ValueNode::has_no_more_uses ( ) const
inline

Definition at line 2540 of file maglev-ir.h.

◆ has_register()

bool v8::internal::maglev::ValueNode::has_register ( ) const
inline

Definition at line 2632 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ has_valid_live_range()

bool v8::internal::maglev::ValueNode::has_valid_live_range ( ) const
inline

Definition at line 2532 of file maglev-ir.h.

Here is the caller graph for this function:

◆ hint()

const compiler::InstructionOperand & v8::internal::maglev::ValueNode::hint ( ) const
inline

Definition at line 2466 of file maglev-ir.h.

Here is the caller graph for this function:

◆ InitializeRegisterData()

void v8::internal::maglev::ValueNode::InitializeRegisterData ( )
inline

Definition at line 2597 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_in_register() [1/2]

bool v8::internal::maglev::ValueNode::is_in_register ( DoubleRegister reg) const
inline

Definition at line 2642 of file maglev-ir.h.

Here is the call graph for this function:

◆ is_in_register() [2/2]

bool v8::internal::maglev::ValueNode::is_in_register ( Register reg) const
inline

Definition at line 2638 of file maglev-ir.h.

Here is the call graph for this function:

◆ is_loadable()

bool v8::internal::maglev::ValueNode::is_loadable ( ) const
inline

Definition at line 2471 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_spilled()

bool v8::internal::maglev::ValueNode::is_spilled ( ) const
inline

Definition at line 2476 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_tagged()

bool v8::internal::maglev::ValueNode::is_tagged ( ) const
inlineconstexpr

Definition at line 2546 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_used()

bool v8::internal::maglev::ValueNode::is_used ( ) const
inline

Definition at line 2434 of file maglev-ir.h.

Here is the caller graph for this function:

◆ live_range()

LiveRange v8::internal::maglev::ValueNode::live_range ( ) const
inline

Definition at line 2533 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ loadable_slot()

compiler::InstructionOperand v8::internal::maglev::ValueNode::loadable_slot ( ) const
inline

Definition at line 2510 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ LoadToRegister() [1/2]

void v8::internal::maglev::ValueNode::LoadToRegister ( MaglevAssembler * ,
DoubleRegister  )

◆ LoadToRegister() [2/2]

void v8::internal::maglev::ValueNode::LoadToRegister ( MaglevAssembler * ,
Register  )

◆ mark_unused_inputs_visited()

void v8::internal::maglev::ValueNode::mark_unused_inputs_visited ( )
inline

Definition at line 2448 of file maglev-ir.h.

◆ num_registers()

int v8::internal::maglev::ValueNode::num_registers ( ) const
inline

Definition at line 2626 of file maglev-ir.h.

Here is the call graph for this function:

◆ record_next_use()

void v8::internal::maglev::ValueNode::record_next_use ( NodeIdT id,
InputLocation * input_location )
inline

Definition at line 2516 of file maglev-ir.h.

Here is the call graph for this function:

◆ Reify()

DirectHandle< Object > v8::internal::maglev::ValueNode::Reify ( LocalIsolate * isolate) const

Definition at line 860 of file maglev-ir.cc.

Here is the call graph for this function:

◆ remove_use()

void v8::internal::maglev::ValueNode::remove_use ( )
inline

Definition at line 2441 of file maglev-ir.h.

Here is the caller graph for this function:

◆ RemoveRegister() [1/2]

void v8::internal::maglev::ValueNode::RemoveRegister ( DoubleRegister reg)
inline

Definition at line 2618 of file maglev-ir.h.

Here is the call graph for this function:

◆ RemoveRegister() [2/2]

void v8::internal::maglev::ValueNode::RemoveRegister ( Register reg)
inline

Definition at line 2614 of file maglev-ir.h.

Here is the call graph for this function:

◆ result() [1/2]

ValueLocation & v8::internal::maglev::ValueNode::result ( )
inline

Definition at line 2426 of file maglev-ir.h.

Here is the caller graph for this function:

◆ result() [2/2]

const ValueLocation & v8::internal::maglev::ValueNode::result ( ) const
inline

Definition at line 2427 of file maglev-ir.h.

◆ result_registers()

template<typename T >
RegListBase< T > v8::internal::maglev::ValueNode::result_registers ( )
inline

Definition at line 2648 of file maglev-ir.h.

Here is the call graph for this function:

◆ SetConstantLocation()

void v8::internal::maglev::ValueNode::SetConstantLocation ( )

Definition at line 492 of file maglev-ir.cc.

Here is the call graph for this function:

◆ SetHint()

void v8::internal::maglev::ValueNode::SetHint ( compiler::InstructionOperand hint)

Definition at line 466 of file maglev-ir.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetNoSpill()

void v8::internal::maglev::ValueNode::SetNoSpill ( )

Definition at line 484 of file maglev-ir.cc.

Here is the call graph for this function:

◆ Spill()

void v8::internal::maglev::ValueNode::Spill ( compiler::AllocatedOperand operand)
inline

Definition at line 2491 of file maglev-ir.h.

Here is the call graph for this function:

◆ spill_slot()

compiler::AllocatedOperand v8::internal::maglev::ValueNode::spill_slot ( ) const
inline

Definition at line 2505 of file maglev-ir.h.

Here is the call graph for this function:

◆ start_id()

NodeIdT v8::internal::maglev::ValueNode::start_id ( ) const
inlineprotected

Definition at line 2690 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ unused_inputs_were_visited()

bool v8::internal::maglev::ValueNode::unused_inputs_were_visited ( ) const
inline

Definition at line 2435 of file maglev-ir.h.

Here is the caller graph for this function:

◆ use_count()

int v8::internal::maglev::ValueNode::use_count ( ) const
inline

Definition at line 2429 of file maglev-ir.h.

Here is the call graph for this function:

◆ use_double_register()

bool v8::internal::maglev::ValueNode::use_double_register ( ) const
inlineconstexpr

Definition at line 2542 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ value_representation()

ValueRepresentation v8::internal::maglev::ValueNode::value_representation ( ) const
inlineconstexpr

Definition at line 2577 of file maglev-ir.h.

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ [union]

◆ [union]

◆ double_registers_with_result_

DoubleRegList v8::internal::maglev::ValueNode::double_registers_with_result_

Definition at line 2697 of file maglev-ir.h.

◆ end_id_

NodeIdT v8::internal::maglev::ValueNode::end_id_ = kInvalidNodeId
protected

Definition at line 2692 of file maglev-ir.h.

◆ hint_

compiler::InstructionOperand v8::internal::maglev::ValueNode::hint_
protected

Definition at line 2706 of file maglev-ir.h.

◆ last_uses_next_use_id_

NodeIdT* v8::internal::maglev::ValueNode::last_uses_next_use_id_

Definition at line 2703 of file maglev-ir.h.

◆ next_use_

NodeIdT v8::internal::maglev::ValueNode::next_use_ = kInvalidNodeId
protected

Definition at line 2693 of file maglev-ir.h.

◆ registers_with_result_

RegList v8::internal::maglev::ValueNode::registers_with_result_

Definition at line 2696 of file maglev-ir.h.

◆ result_

ValueLocation v8::internal::maglev::ValueNode::result_
protected

Definition at line 2694 of file maglev-ir.h.

◆ spill_

compiler::InstructionOperand v8::internal::maglev::ValueNode::spill_

Definition at line 2704 of file maglev-ir.h.

◆ use_count_

int v8::internal::maglev::ValueNode::use_count_
protected

Definition at line 2708 of file maglev-ir.h.


The documentation for this class was generated from the following files: