19 const int kCallInstructionSizeInWords = 3;
30 if (FLAG_zap_code_space) {
33 if (pointer !=
NULL) {
42 DeoptimizationInputData::cast(code->deoptimization_data());
43 int osr_offset = data->OsrPcOffset()->value();
51 DeoptimizationInputData::cast(code->deoptimization_data());
58 if (deopt_data->Pc(
i)->value() == -1)
continue;
59 Address call_address = code_start_address + deopt_data->Pc(
i)->value();
63 int call_size_in_bytes =
70 CodePatcher patcher(call_address, call_size_in_words);
73 call_address >= prev_call_address +
patch_size());
76 prev_call_address = call_address;
106 ExternalReference xref(&
function, ExternalReference::BUILTIN_CALL,
isolate_);
107 intptr_t handler =
reinterpret_cast<intptr_t
>(xref.address());
132 void Deoptimizer::EntryGenerator::Generate() {
141 const int kDoubleRegsSize =
149 __ CheckFor32DRegs(
ip);
162 const int kSavedRegistersAreaSize =
178 __ PrepareCallCFunction(6,
r5);
180 __ mov(
r1, Operand(type()));
184 __ mov(
r5, Operand(ExternalReference::isolate_address(isolate())));
188 AllowExternalCallThatCantCauseGC scope(masm());
189 __ CallCFunction(ExternalReference::new_deoptimizer_function(isolate()), 6);
210 __ vldr(
d0,
sp, src_offset);
211 __ vstr(
d0,
r1, dst_offset);
227 Label pop_loop_header;
228 __ b(&pop_loop_header);
233 __ bind(&pop_loop_header);
240 __ PrepareCallCFunction(1,
r1);
243 AllowExternalCallThatCantCauseGC scope(masm());
245 ExternalReference::compute_output_frames_function(isolate()), 1);
250 Label outer_push_loop, inner_push_loop,
251 outer_loop_header, inner_loop_header;
257 __ jmp(&outer_loop_header);
258 __ bind(&outer_push_loop);
262 __ jmp(&inner_loop_header);
263 __ bind(&inner_push_loop);
268 __ bind(&inner_loop_header);
269 __ cmp(
r3, Operand::Zero());
270 __ b(
ne, &inner_push_loop);
272 __ bind(&outer_loop_header);
274 __ b(
lt, &outer_push_loop);
277 __ CheckFor32DRegs(
ip);
286 __ vldr(reg,
r1, src_offset,
i < 16 ?
al :
ne);
310 __ InitializeRootRegister();
316 __ stop(
"Unreachable.");
325 int start = masm()->pc_offset();
337 SetFrameSlot(offset, value);
342 SetFrameSlot(offset, value);
347 DCHECK(FLAG_enable_ool_constant_pool);
348 SetFrameSlot(offset, value);
#define kScratchDoubleReg
static const int kInstrSize
void bkpt(uint32_t imm16)
int GetHandlerParameterCount() const
Address deoptimization_handler() const
void InvalidateRelocation()
byte * instruction_start()
byte * FindCodeAgeSequence()
virtual void GeneratePrologue()
static int output_offset()
static const int table_entry_size_
void CopyDoubleRegisters(FrameDescription *output_frame)
static Address GetDeoptimizationEntry(Isolate *isolate, int id, BailoutType type, GetEntryMode mode=ENSURE_ENTRY_CODE)
static int input_offset()
static void PatchCodeForDeoptimization(Isolate *isolate, Code *code)
static int output_count_offset()
void SetPlatformCompiledStubRegisters(FrameDescription *output_frame, CodeStubDescriptor *desc)
bool HasAlignmentPadding(JSFunction *function)
FrameDescription * input_
Isolate * isolate() const
void FillInputFrame(Address tos, JavaScriptFrame *frame)
static int frame_size_offset()
void SetCallerFp(unsigned offset, intptr_t value)
uint32_t GetFrameSize() const
static int continuation_offset()
static int frame_content_offset()
void SetCallerConstantPool(unsigned offset, intptr_t value)
static int state_offset()
static int registers_offset()
double GetDoubleRegister(unsigned n) const
static int double_registers_offset()
void SetRegister(unsigned n, intptr_t value)
void SetCallerPc(unsigned offset, intptr_t value)
void SetFrameSlot(unsigned offset, intptr_t value)
void SetDoubleRegister(unsigned n, double value)
static const int kFunctionOffset
void Call(Register target, Condition cond=al)
static int CallSizeNotPredictableCodeSize(Isolate *isolate, Address target, RelocInfo::Mode rmode, Condition cond=al)
static uint32_t & uint32_at(Address addr)
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
#define DCHECK(condition)
const RegList kJSCallerSaved
const RegList kCalleeSaved
const LowDwVfpRegister d0
const LowDwVfpRegister d13
const unsigned kNumberOfRegisters
static const int kNoCodeAgeSequenceLength
Debugger support for the V8 JavaScript engine.
static int NumAllocatableRegisters()
static DwVfpRegister from_code(int code)
static const int kMaxNumAllocatableRegisters
static const int kMaxNumRegisters
static const int kNumRegisters