| Index: src/liveedit.h
|
| diff --git a/src/liveedit.h b/src/liveedit.h
|
| index d8e2a1375b52b862ea8ba23a611163378a6192c2..c2e7502d1a5177808a506b3619b0efe846236286 100644
|
| --- a/src/liveedit.h
|
| +++ b/src/liveedit.h
|
| @@ -83,8 +83,15 @@ class LiveEdit : AllStatic {
|
|
|
| static void WrapSharedFunctionInfos(Handle<JSArray> array);
|
|
|
| + // Replaces function code. The function mustn't be running anywhere on stack.
|
| + // The only exception is when stack_manipulation data is provided.
|
| + // The stack manipulations are performed in this method. It is expected that
|
| + // as a result the function gets restarted.
|
| + // \param stack_manipulation_data possibly null handle to stack manipulations
|
| + // that are to be performed
|
| static Object* ReplaceFunctionCode(Handle<JSArray> new_compile_info_array,
|
| - Handle<JSArray> shared_info_array);
|
| + Handle<JSArray> shared_info_array,
|
| + Handle<ByteArray> stack_manipulation_data);
|
|
|
| // Updates script field in FunctionSharedInfo.
|
| static void SetFunctionScript(Handle<JSValue> function_wrapper,
|
| @@ -106,22 +113,20 @@ class LiveEdit : AllStatic {
|
| Handle<JSValue> orig_function_shared,
|
| Handle<JSValue> subst_function_shared);
|
|
|
| - // Checks listed functions on stack and return array with corresponding
|
| - // FunctionPatchabilityStatus statuses; extra array element may
|
| - // contain general error message. Modifies the current stack and
|
| - // has restart the lowest found frames and drops all other frames above
|
| - // if possible and if do_drop is true.
|
| - static Handle<JSArray> CheckAndDropActivations(
|
| - Handle<JSArray> shared_info_array, bool do_drop);
|
| -
|
| - // A copy of this is in liveedit-debugger.js.
|
| - enum FunctionPatchabilityStatus {
|
| - FUNCTION_AVAILABLE_FOR_PATCH = 1,
|
| - FUNCTION_BLOCKED_ON_ACTIVE_STACK = 2,
|
| - FUNCTION_BLOCKED_ON_OTHER_STACK = 3,
|
| - FUNCTION_BLOCKED_UNDER_NATIVE_CODE = 4,
|
| - FUNCTION_REPLACED_ON_ACTIVE_STACK = 5
|
| - };
|
| + // Checks the listed functions against the current stacks and plans
|
| + // possible stack manipulations: all frames running listed functions
|
| + // must be removed (dropped) from stack.
|
| + // \param shared_info_array contains array of wrapped shared function
|
| + // infos or undefined elements
|
| + // \return array-packed StackManipulationInfo structure
|
| + static Handle<JSArray> CheckActivations(Handle<JSArray> shared_info_array);
|
| +
|
| + // Returns whether the frame is paused at function restarter code.
|
| + static bool IsAtFrameResetPatch(const JavaScriptFrame*);
|
| +
|
| + // Returns pointer to entry of function restarted code (the code must
|
| + // be patched).
|
| + static Address GetRestarterPatchEntryPoint(Code* code);
|
|
|
| // Compares 2 strings line-by-line and returns diff in form of array of
|
| // triplets (pos1, pos1_end, pos2_end) describing list of diff chunks.
|
| @@ -167,4 +172,4 @@ class Comparator {
|
|
|
| } } // namespace v8::internal
|
|
|
| -#endif /* V*_LIVEEDIT_H_ */
|
| +#endif /* V8_LIVEEDIT_H_ */
|
|
|