28 #include "../include/v8stdint.h"
65 const char* arg_opt) {
84 for (
int i = 0; i < str.
length(); i++) {
100 if (function_size > 0) {
116 symbol_table_(vector_compare),
121 void CompleteParserRecorder::LogSymbol(
int start,
125 Key key = { is_ascii, literal_bytes };
126 HashMap::Entry* entry = symbol_table_.
Lookup(&key, hash,
true);
127 int id =
static_cast<int>(
reinterpret_cast<intptr_t
>(entry->value));
134 entry->value =
reinterpret_cast<void*
>(id);
135 Vector<Key> symbol = symbol_keys_.
AddBlock(1, key);
136 entry->key = &symbol[0];
145 int symbol_size = symbol_store_.
size();
146 int padding =
sizeof(unsigned) - (symbol_size %
sizeof(
unsigned));
148 symbol_size += padding;
150 + (symbol_size /
sizeof(unsigned));
156 if (function_size > 0) {
168 void CompleteParserRecorder::WriteNumber(
int number) {
171 int mask = (1 << 28) - 1;
172 for (
int i = 28; i > 0; i -= 7) {
174 symbol_store_.
Add(static_cast<byte>(number >> i) | 0x80u);
179 symbol_store_.
Add(static_cast<byte>(number));
static const unsigned kMagicNumber
Vector< T > SubVector(int from, int to)
#define ASSERT(condition)
virtual Vector< unsigned > ExtractData()
virtual void LogMessage(int start, int end, const char *message, const char *argument_opt)
Collector< unsigned > function_store_
FunctionLoggingParserRecorder()
static const int kSymbolCountOffset
static const int kVersionOffset
Vector< T > AddBlock(int size, T initial_value)
STATIC_ASSERT((FixedDoubleArray::kHeaderSize &kDoubleAlignmentMask)==0)
void WriteString(Vector< const char > str)
static const int kMessageEndPos
static const int kMessageStartPos
static const int kSizeOffset
static const int kMessageTextPos
static const int kMessageArgCountPos
static const int kFunctionsSizeOffset
Entry * Lookup(void *key, uint32_t hash, bool insert, AllocationPolicy allocator=AllocationPolicy())
unsigned preamble_[PreparseDataConstants::kHeaderSize]
static Vector< T > New(int length)
Vector< const char > CStrVector(const char *data)
virtual Vector< unsigned > ExtractData()
static const int kHasErrorOffset
static const unsigned kCurrentVersion
static Vector< T > cast(Vector< S > input)
static const unsigned char kNumberTerminator
#define ASSERT_EQ(v1, v2)
activate correct semantics for inheriting readonliness enable harmony semantics for typeof enable harmony enable harmony proxies enable all harmony harmony_scoping harmony_proxies harmony_scoping tracks arrays with only smi values automatically unbox arrays of doubles use crankshaft use hydrogen range analysis use hydrogen global value numbering use function inlining maximum number of AST nodes considered for a single inlining loop invariant code motion print statistics for hydrogen trace generated IR for specified phases trace register allocator trace range analysis trace representation types environment for every instruction put a break point before deoptimizing polymorphic inlining perform array bounds checks elimination trace on stack replacement optimize closures functions with arguments object optimize functions containing for in loops profiler considers IC stability primitive functions trigger their own optimization re try self optimization if it failed insert an interrupt check at function exit execution budget before interrupt is triggered call count before self optimization self_optimization count_based_interrupts weighted_back_edges trace_opt emit comments in code disassembly enable use of SSE3 instructions if available enable use of CMOV instruction if available enable use of SAHF instruction if enable use of VFP3 instructions if available this implies enabling ARMv7 enable use of ARMv7 instructions if enable use of MIPS FPU instructions if NULL
activate correct semantics for inheriting readonliness enable harmony semantics for typeof enable harmony enable harmony proxies enable all harmony harmony_scoping harmony_proxies harmony_scoping true
void WriteTo(Vector< T > destination)
static const int kHeaderSize
static const int kMagicOffset