v8  3.25.30(node0.11.13)
V8 is Google's open source JavaScript engine
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
hydrogen-instructions.cc File Reference
#include "v8.h"
#include "double.h"
#include "factory.h"
#include "hydrogen-infer-representation.h"
#include "property-details-inl.h"
Include dependency graph for hydrogen-instructions.cc:

Go to the source code of this file.

Namespaces

 v8
 
 v8::internal
 

Macros

#define DEFINE_COMPILE(type)
 
#define MAKE_CASE(type)   case k##type: return #type;
 
#define PRINT_DO(Type)
 
#define IMMORTAL_IMMOVABLE_ROOT(name)   object_.IsKnownGlobal(heap->name()) ||
 
#define INTERNALIZED_STRING(name, value)   object_.IsKnownGlobal(heap->name()) ||
 
#define STRING_TYPE(NAME, size, name, Name)   object_.IsKnownGlobal(heap->name##_map()) ||
 
#define H_CONSTANT_INT(val)   HConstant::New(zone, context, static_cast<int32_t>(val))
 
#define H_CONSTANT_DOUBLE(val)   HConstant::New(zone, context, static_cast<double>(val))
 
#define DEFINE_NEW_H_SIMPLE_ARITHMETIC_INSTR(HInstr, op)
 
#define DEFINE_NEW_H_BITWISE_INSTR(HInstr, result)
 

Functions

bool ConstantIsObject (HConstant *constant, Isolate *isolate)
 
 DEFINE_NEW_H_BITWISE_INSTR (HSar, c_left->NumberValueAsInteger32() >>(c_right->NumberValueAsInteger32()&0x1f)) DEFINE_NEW_H_BITWISE_INSTR(HShl
 
c_left NumberValueAsInteger32 ()<< (c_right-> NumberValueAsInteger32()&0x1f)) HInstruction *HShr::New(Zone *zone, HValue *context, HValue *left, HValue *right)
 

Macro Definition Documentation

#define DEFINE_COMPILE (   type)
Value:
LInstruction* H##type::CompileToLithium(LChunkBuilder* builder) { \
return builder->Do##type(this); \
}

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

#define DEFINE_NEW_H_BITWISE_INSTR (   HInstr,
  result 
)
Value:
HInstruction* HInstr::New( \
Zone* zone, HValue* context, HValue* left, HValue* right) { \
if (FLAG_fold_constants && left->IsConstant() && right->IsConstant()) { \
HConstant* c_left = HConstant::cast(left); \
HConstant* c_right = HConstant::cast(right); \
if ((c_left->HasNumberValue() && c_right->HasNumberValue())) { \
return H_CONSTANT_INT(result); \
} \
} \
return new(zone) HInstr(context, left, right); \
}
#define H_CONSTANT_INT(val)

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

#define DEFINE_NEW_H_SIMPLE_ARITHMETIC_INSTR (   HInstr,
  op 
)
Value:
HInstruction* HInstr::New( \
Zone* zone, HValue* context, HValue* left, HValue* right) { \
if (FLAG_fold_constants && left->IsConstant() && right->IsConstant()) { \
HConstant* c_left = HConstant::cast(left); \
HConstant* c_right = HConstant::cast(right); \
if ((c_left->HasNumberValue() && c_right->HasNumberValue())) { \
double double_res = c_left->DoubleValue() op c_right->DoubleValue(); \
if (IsInt32Double(double_res)) { \
return H_CONSTANT_INT(double_res); \
} \
return H_CONSTANT_DOUBLE(double_res); \
} \
} \
return new(zone) HInstr(context, left, right); \
}
#define H_CONSTANT_INT(val)
#define H_CONSTANT_DOUBLE(val)

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

#define H_CONSTANT_DOUBLE (   val)    HConstant::New(zone, context, static_cast<double>(val))

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

Referenced by v8::internal::NumberValueAsInteger32().

#define H_CONSTANT_INT (   val)    HConstant::New(zone, context, static_cast<int32_t>(val))

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

Referenced by v8::internal::NumberValueAsInteger32().

#define IMMORTAL_IMMOVABLE_ROOT (   name)    object_.IsKnownGlobal(heap->name()) ||
#define INTERNALIZED_STRING (   name,
  value 
)    object_.IsKnownGlobal(heap->name()) ||
#define MAKE_CASE (   type)    case k##type: return #type;

Referenced by HValue::Mnemonic().

#define PRINT_DO (   Type)
Value:
if (changes_flags.Contains(k##Type)) { \
if (add_comma) stream->Add(","); \
add_comma = true; \
stream->Add(#Type); \
}
TypeImpl< ZoneTypeConfig > Type
enable upcoming ES6 features enable harmony block scoping enable harmony enable harmony proxies enable harmony generators enable harmony numeric enable harmony string enable harmony math functions harmony_scoping harmony_symbols harmony_collections harmony_iteration harmony_strings harmony_scoping harmony_maths true

Referenced by HValue::PrintChangesTo().

#define STRING_TYPE (   NAME,
  size,
  name,
  Name 
)    object_.IsKnownGlobal(heap->name##_map()) ||