V8 Project
v8::internal::HCompareObjectEqAndBranch Class Reference

#include <hydrogen-instructions.h>

+ Inheritance diagram for v8::internal::HCompareObjectEqAndBranch:
+ Collaboration diagram for v8::internal::HCompareObjectEqAndBranch:

Public Member Functions

 DECLARE_INSTRUCTION_FACTORY_P2 (HCompareObjectEqAndBranch, HValue *, HValue *)
 
 DECLARE_INSTRUCTION_FACTORY_P4 (HCompareObjectEqAndBranch, HValue *, HValue *, HBasicBlock *, HBasicBlock *)
 
virtual bool KnownSuccessorBlock (HBasicBlock **block) OVERRIDE
 
int known_successor_index () const
 
void set_known_successor_index (int known_successor_index)
 
HValueleft () const
 
HValueright () const
 
virtual OStreamPrintDataTo (OStream &os) const OVERRIDE
 
virtual Representation RequiredInputRepresentation (int index) OVERRIDE
 
virtual Representation observed_input_representation (int index) OVERRIDE
 
- Public Member Functions inherited from v8::internal::HTemplateControlInstruction< 2, 2 >
int SuccessorCount () const OVERRIDE
 
HBasicBlockSuccessorAt (int i) const OVERRIDE
 
void SetSuccessorAt (int i, HBasicBlock *block) OVERRIDE
 
int OperandCount () const OVERRIDE
 
HValueOperandAt (int i) const OVERRIDE
 
- Public Member Functions inherited from v8::internal::HControlInstruction
HBasicBlockFirstSuccessor ()
 
HBasicBlockSecondSuccessor ()
 
void Not ()
 
- Public Member Functions inherited from v8::internal::HInstruction
HInstructionnext () const
 
HInstructionprevious () const
 
virtual OStreamPrintTo (OStream &os) const OVERRIDE
 
bool IsLinked () const
 
void Unlink ()
 
void InsertBefore (HInstruction *next)
 
template<class T >
TPrepend (T *instr)
 
void InsertAfter (HInstruction *previous)
 
template<class T >
TAppend (T *instr)
 
virtual HSourcePosition position () const OVERRIDE
 
bool has_position () const
 
void set_position (HSourcePosition position)
 
virtual HSourcePosition operand_position (int index) const OVERRIDE
 
void set_operand_position (Zone *zone, int index, HSourcePosition pos)
 
bool Dominates (HInstruction *other)
 
bool CanTruncateToSmi () const
 
bool CanTruncateToInt32 () const
 
virtual LInstructionCompileToLithium (LChunkBuilder *builder)=0
 
bool CanDeoptimize ()
 
virtual bool HasStackCheck ()
 
- Public Member Functions inherited from v8::internal::HValue
 STATIC_ASSERT (kLastFlag< kBitsPerInt)
 
virtual Opcode opcode () const =0
 
bool IsPhi () const
 
bool IsBitwiseBinaryShift ()
 
 HValue (HType type=HType::Tagged())
 
virtual ~HValue ()
 
HBasicBlock * block () const
 
void SetBlock (HBasicBlock *block)
 
Isolateisolate () const
 
int id () const
 
void set_id (int id)
 
HUseIterator uses () const
 
virtual bool EmitAtUses ()
 
Representation representation () const
 
void ChangeRepresentation (Representation r)
 
virtual void AssumeRepresentation (Representation r)
 
virtual Representation KnownOptimalRepresentation ()
 
HType type () const
 
void set_type (HType new_type)
 
virtual int RedefinedOperandIndex ()
 
bool IsInformativeDefinition ()
 
HValueRedefinedOperand ()
 
bool CanReplaceWithDummyUses ()
 
virtual int argument_delta () const
 
virtual bool IsPurelyInformativeDefinition ()
 
HValueActualValue ()
 
bool IsInteger32Constant ()
 
int32_t GetInteger32Constant ()
 
bool EqualsInteger32Constant (int32_t value)
 
bool IsDefinedAfter (HBasicBlock *other) const
 
void SetOperandAt (int index, HValue *value)
 
void DeleteAndReplaceWith (HValue *other)
 
void ReplaceAllUsesWith (HValue *other)
 
bool HasNoUses () const
 
bool HasOneUse () const
 
bool HasMultipleUses () const
 
int UseCount () const
 
void Kill ()
 
int flags () const
 
void SetFlag (Flag f)
 
void ClearFlag (Flag f)
 
bool CheckFlag (Flag f) const
 
void CopyFlag (Flag f, HValue *other)
 
bool CheckUsesForFlag (Flag f) const
 
bool CheckUsesForFlag (Flag f, HValue **value) const
 
bool HasAtLeastOneUseWithFlagAndNoneWithout (Flag f) const
 
GVNFlagSet ChangesFlags () const
 
GVNFlagSet DependsOnFlags () const
 
void SetChangesFlag (GVNFlag f)
 
void SetDependsOnFlag (GVNFlag f)
 
void ClearChangesFlag (GVNFlag f)
 
void ClearDependsOnFlag (GVNFlag f)
 
bool CheckChangesFlag (GVNFlag f) const
 
bool CheckDependsOnFlag (GVNFlag f) const
 
void SetAllSideEffects ()
 
void ClearAllSideEffects ()
 
bool HasSideEffects () const
 
bool HasObservableSideEffects () const
 
GVNFlagSet SideEffectFlags () const
 
GVNFlagSet ObservableChangesFlags () const
 
Range * range () const
 
bool HasRange () const
 
void AddNewRange (Range *r, Zone *zone)
 
void RemoveLastAddedRange ()
 
void ComputeInitialRange (Zone *zone)
 
virtual bool HasEscapingOperandAt (int index)
 
virtual bool HasOutOfBoundsAccess (int size)
 
virtual void InferRepresentation (HInferRepresentationPhase *h_infer)
 
virtual HValueCanonicalize ()
 
bool Equals (HValue *other)
 
virtual intptr_t Hashcode ()
 
virtual void FinalizeUniqueness ()
 
const char * Mnemonic () const
 
bool HasMonomorphicJSObjectType ()
 
virtual Handle< MapGetMonomorphicJSObjectMap ()
 
bool UpdateInferredType ()
 
virtual HType CalculateInferredType ()
 
virtual bool HandleSideEffectDominator (GVNFlag side_effect, HValue *dominator)
 
bool CannotBeEliminated () const
 
virtual bool TryDecompose (DecompositionResult *decomposition)
 
bool ToStringCanBeObserved () const
 
bool ToNumberCanBeObserved () const
 
MinusZeroMode GetMinusZeroMode ()
 
- Public Member Functions inherited from v8::internal::ZoneObject
 INLINE (void *operator new(size_t size, Zone *zone))
 
void operator delete (void *, size_t)
 
void operator delete (void *pointer, Zone *zone)
 

Static Public Attributes

static const int kNoKnownSuccessorIndex = -1
 
- Static Public Attributes inherited from v8::internal::HValue
static const int kNoNumber = -1
 
static const int kNoRedefinedOperand = -1
 

Private Member Functions

 HCompareObjectEqAndBranch (HValue *left, HValue *right, HBasicBlock *true_target=NULL, HBasicBlock *false_target=NULL)
 

Private Attributes

int known_successor_index_
 

Additional Inherited Members

- Public Types inherited from v8::internal::HValue
enum  Flag {
  kFlexibleRepresentation , kCannotBeTagged , kUseGVN , kTrackSideEffectDominators ,
  kCanOverflow , kBailoutOnMinusZero , kCanBeDivByZero , kLeftCanBeMinInt ,
  kLeftCanBeNegative , kLeftCanBePositive , kAllowUndefinedAsNaN , kIsArguments ,
  kTruncatingToInt32 , kAllUsesTruncatingToInt32 , kTruncatingToSmi , kAllUsesTruncatingToSmi ,
  kIsDead , kUint32 , kHasNoObservableSideEffects , kCantBeReplaced ,
  kIsLive , kEndsLiveRange = kIsLive , kLastFlag = kIsLive
}
 
enum  Opcode { kPhi }
 
- Static Public Member Functions inherited from v8::internal::HValue
static HValuecast (HValue *value)
 
- Protected Member Functions inherited from v8::internal::HTemplateControlInstruction< 2, 2 >
void InternalSetOperandAt (int i, HValue *value) OVERRIDE
 
- Protected Member Functions inherited from v8::internal::HInstruction
 HInstruction (HType type=HType::Tagged())
 
virtual void DeleteFromGraph () OVERRIDE
 
- Protected Member Functions inherited from v8::internal::HValue
virtual bool DataEquals (HValue *other)
 
bool ToStringOrToNumberCanBeObserved () const
 
virtual Representation RepresentationFromInputs ()
 
virtual Representation RepresentationFromUses ()
 
Representation RepresentationFromUseRequirements ()
 
bool HasNonSmiUse ()
 
virtual void UpdateRepresentation (Representation new_rep, HInferRepresentationPhase *h_infer, const char *reason)
 
void AddDependantsToWorklist (HInferRepresentationPhase *h_infer)
 
virtual void RepresentationChanged (Representation to)
 
virtual Range * InferRange (Zone *zone)
 
void clear_block ()
 
void set_representation (Representation r)
 
HUseListNodeRemoveUse (HValue *value, int index)
 
void RegisterUse (int index, HValue *new_value)
 
- Static Protected Member Functions inherited from v8::internal::HValue
static GVNFlagSet AllFlagSet ()
 
static GVNFlagSet AllSideEffectsFlagSet ()
 
static GVNFlagSet AllObservableSideEffectsFlagSet ()
 
- Protected Attributes inherited from v8::internal::HValue
HBasicBlock * block_
 
int id_
 
Representation representation_
 
HType type_
 
HUseListNodeuse_list_
 
Range * range_
 
int flags_
 
GVNFlagSet changes_flags_
 
GVNFlagSet depends_on_flags_
 

Detailed Description

Definition at line 4388 of file hydrogen-instructions.h.

Constructor & Destructor Documentation

◆ HCompareObjectEqAndBranch()

v8::internal::HCompareObjectEqAndBranch::HCompareObjectEqAndBranch ( HValue left,
HValue right,
HBasicBlock true_target = NULL,
HBasicBlock false_target = NULL 
)
inlineprivate

Definition at line 4418 of file hydrogen-instructions.h.

References left(), right(), v8::internal::HValue::SetOperandAt(), and v8::internal::HTemplateControlInstruction< 2, 2 >::SetSuccessorAt().

+ Here is the call graph for this function:

Member Function Documentation

◆ DECLARE_INSTRUCTION_FACTORY_P2()

v8::internal::HCompareObjectEqAndBranch::DECLARE_INSTRUCTION_FACTORY_P2 ( HCompareObjectEqAndBranch  ,
HValue ,
HValue  
)

◆ DECLARE_INSTRUCTION_FACTORY_P4()

v8::internal::HCompareObjectEqAndBranch::DECLARE_INSTRUCTION_FACTORY_P4 ( HCompareObjectEqAndBranch  ,
HValue ,
HValue ,
HBasicBlock ,
HBasicBlock  
)

◆ known_successor_index()

int v8::internal::HCompareObjectEqAndBranch::known_successor_index ( ) const
inline

Definition at line 4397 of file hydrogen-instructions.h.

4397 { return known_successor_index_; }

References known_successor_index_.

Referenced by set_known_successor_index().

+ Here is the caller graph for this function:

◆ KnownSuccessorBlock()

bool v8::internal::HCompareObjectEqAndBranch::KnownSuccessorBlock ( HBasicBlock **  block)
virtual

Reimplemented from v8::internal::HControlInstruction.

Definition at line 3209 of file hydrogen-instructions.cc.

3209  {
3212  return true;
3213  }
3214  if (FLAG_fold_constants && left()->IsConstant() && right()->IsConstant()) {
3215  *block = HConstant::cast(left())->DataEquals(HConstant::cast(right()))
3217  return true;
3218  }
3219  *block = NULL;
3220  return false;
3221 }
HBasicBlock * block() const
enable harmony numeric enable harmony object literal extensions Optimize object Array DOM strings and string trace pretenuring decisions of HAllocate instructions Enables optimizations which favor memory size over execution speed maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining trace the tracking of allocation sites deoptimize every n garbage collections perform array bounds checks elimination analyze liveness of environment slots and zap dead values flushes the cache of optimized code for closures on every GC allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes enable context specialization in TurboFan execution budget before interrupt is triggered max percentage of megamorphic generic ICs to allow optimization enable use of SAHF instruction if enable use of VFP3 instructions if available enable use of NEON instructions if enable use of SDIV and UDIV instructions if enable use of MLS instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of d16 d31 registers on ARM this requires VFP3 force all emitted branches to be in long enable alignment of csp to bytes on platforms which prefer the register to always be NULL

References NULL.

◆ left()

HValue* v8::internal::HCompareObjectEqAndBranch::left ( ) const
inline

Definition at line 4402 of file hydrogen-instructions.h.

4402 { return OperandAt(0); }

References v8::internal::HTemplateControlInstruction< 2, 2 >::OperandAt().

Referenced by v8::internal::HCheckTable::Copy(), HCompareObjectEqAndBranch(), and v8::internal::HCheckTable::ReduceCompareObjectEqAndBranch().

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

◆ observed_input_representation()

virtual Representation v8::internal::HCompareObjectEqAndBranch::observed_input_representation ( int  index)
inlinevirtual

Reimplemented from v8::internal::HValue.

Definition at line 4411 of file hydrogen-instructions.h.

4411  {
4412  return Representation::Tagged();
4413  }
static Representation Tagged()

References v8::internal::Representation::Tagged().

+ Here is the call graph for this function:

◆ PrintDataTo()

OStream & v8::internal::HCompareObjectEqAndBranch::PrintDataTo ( OStream os) const
virtual

Reimplemented from v8::internal::HControlInstruction.

Definition at line 3203 of file hydrogen-instructions.cc.

3203  { // NOLINT
3204  os << NameOf(left()) << " " << NameOf(right());
3206 }
virtual OStream & PrintDataTo(OStream &os) const OVERRIDE

◆ RequiredInputRepresentation()

virtual Representation v8::internal::HCompareObjectEqAndBranch::RequiredInputRepresentation ( int  index)
inlinevirtual

Implements v8::internal::HValue.

Definition at line 4407 of file hydrogen-instructions.h.

4407  {
4408  return Representation::Tagged();
4409  }

References v8::internal::Representation::Tagged().

+ Here is the call graph for this function:

◆ right()

HValue* v8::internal::HCompareObjectEqAndBranch::right ( ) const
inline

Definition at line 4403 of file hydrogen-instructions.h.

4403 { return OperandAt(1); }

References v8::internal::HTemplateControlInstruction< 2, 2 >::OperandAt().

Referenced by v8::internal::HCheckTable::Copy(), HCompareObjectEqAndBranch(), and v8::internal::HCheckTable::ReduceCompareObjectEqAndBranch().

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

◆ set_known_successor_index()

void v8::internal::HCompareObjectEqAndBranch::set_known_successor_index ( int  known_successor_index)
inline

Definition at line 4398 of file hydrogen-instructions.h.

4398  {
4400  }

References known_successor_index(), and known_successor_index_.

Referenced by v8::internal::HCheckTable::ReduceCompareObjectEqAndBranch().

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

Member Data Documentation

◆ kNoKnownSuccessorIndex

const int v8::internal::HCompareObjectEqAndBranch::kNoKnownSuccessorIndex = -1
static

Definition at line 4396 of file hydrogen-instructions.h.

◆ known_successor_index_

int v8::internal::HCompareObjectEqAndBranch::known_successor_index_
private

Definition at line 4429 of file hydrogen-instructions.h.

Referenced by known_successor_index(), and set_known_successor_index().


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