Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(555)

Side by Side Diff: src/ia32/macro-assembler-ia32.h

Issue 341082: Reverting 3174. Aka reapplying 3150, 3151 and 3159. Aka api accessor (Closed)
Patch Set: Created 11 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/ia32/frames-ia32.cc ('k') | src/ia32/macro-assembler-ia32.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2009 the V8 project authors. All rights reserved. 1 // Copyright 2006-2009 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 70
71 // --------------------------------------------------------------------------- 71 // ---------------------------------------------------------------------------
72 // Activation frames 72 // Activation frames
73 73
74 void EnterInternalFrame() { EnterFrame(StackFrame::INTERNAL); } 74 void EnterInternalFrame() { EnterFrame(StackFrame::INTERNAL); }
75 void LeaveInternalFrame() { LeaveFrame(StackFrame::INTERNAL); } 75 void LeaveInternalFrame() { LeaveFrame(StackFrame::INTERNAL); }
76 76
77 void EnterConstructFrame() { EnterFrame(StackFrame::CONSTRUCT); } 77 void EnterConstructFrame() { EnterFrame(StackFrame::CONSTRUCT); }
78 void LeaveConstructFrame() { LeaveFrame(StackFrame::CONSTRUCT); } 78 void LeaveConstructFrame() { LeaveFrame(StackFrame::CONSTRUCT); }
79 79
80 // Enter specific kind of exit frame; either EXIT or 80 // Enter specific kind of exit frame; either in normal or debug mode.
81 // EXIT_DEBUG. Expects the number of arguments in register eax and 81 // Expects the number of arguments in register eax and
82 // sets up the number of arguments in register edi and the pointer 82 // sets up the number of arguments in register edi and the pointer
83 // to the first argument in register esi. 83 // to the first argument in register esi.
84 void EnterExitFrame(StackFrame::Type type); 84 void EnterExitFrame(ExitFrame::Mode mode);
85
86 void EnterApiExitFrame(ExitFrame::Mode mode, int stack_space, int argc);
85 87
86 // Leave the current exit frame. Expects the return value in 88 // Leave the current exit frame. Expects the return value in
87 // register eax:edx (untouched) and the pointer to the first 89 // register eax:edx (untouched) and the pointer to the first
88 // argument in register esi. 90 // argument in register esi.
89 void LeaveExitFrame(StackFrame::Type type); 91 void LeaveExitFrame(ExitFrame::Mode mode);
90 92
91 93
92 // --------------------------------------------------------------------------- 94 // ---------------------------------------------------------------------------
93 // JavaScript invokes 95 // JavaScript invokes
94 96
95 // Invoke the JavaScript function code by either calling or jumping. 97 // Invoke the JavaScript function code by either calling or jumping.
96 void InvokeCode(const Operand& code, 98 void InvokeCode(const Operand& code,
97 const ParameterCount& expected, 99 const ParameterCount& expected,
98 const ParameterCount& actual, 100 const ParameterCount& actual,
99 InvokeFlag flag); 101 InvokeFlag flag);
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 // Convenience function: Same as above, but takes the fid instead. 264 // Convenience function: Same as above, but takes the fid instead.
263 void CallRuntime(Runtime::FunctionId id, int num_arguments); 265 void CallRuntime(Runtime::FunctionId id, int num_arguments);
264 266
265 // Tail call of a runtime routine (jump). 267 // Tail call of a runtime routine (jump).
266 // Like JumpToRuntime, but also takes care of passing the number 268 // Like JumpToRuntime, but also takes care of passing the number
267 // of arguments. 269 // of arguments.
268 void TailCallRuntime(const ExternalReference& ext, 270 void TailCallRuntime(const ExternalReference& ext,
269 int num_arguments, 271 int num_arguments,
270 int result_size); 272 int result_size);
271 273
274 void PushHandleScope(Register scratch);
275 void PopHandleScope(Register scratch);
276
272 // Jump to a runtime routine. 277 // Jump to a runtime routine.
273 void JumpToRuntime(const ExternalReference& ext); 278 void JumpToRuntime(const ExternalReference& ext);
274 279
275 280
276 // --------------------------------------------------------------------------- 281 // ---------------------------------------------------------------------------
277 // Utilities 282 // Utilities
278 283
279 void Ret(); 284 void Ret();
280 285
281 struct Unresolved { 286 struct Unresolved {
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
339 // returns the builtin code object for IllegalFunction, and sets the 344 // returns the builtin code object for IllegalFunction, and sets the
340 // output parameter "resolved" to false. Code that uses the return value 345 // output parameter "resolved" to false. Code that uses the return value
341 // should then add the address and the builtin name to the list of fixups 346 // should then add the address and the builtin name to the list of fixups
342 // called unresolved_, which is fixed up by the bootstrapper. 347 // called unresolved_, which is fixed up by the bootstrapper.
343 Handle<Code> ResolveBuiltin(Builtins::JavaScript id, bool* resolved); 348 Handle<Code> ResolveBuiltin(Builtins::JavaScript id, bool* resolved);
344 349
345 // Activation support. 350 // Activation support.
346 void EnterFrame(StackFrame::Type type); 351 void EnterFrame(StackFrame::Type type);
347 void LeaveFrame(StackFrame::Type type); 352 void LeaveFrame(StackFrame::Type type);
348 353
354 void EnterExitFramePrologue(ExitFrame::Mode mode);
355 void EnterExitFrameEpilogue(ExitFrame::Mode mode, int argc);
356
349 // Allocation support helpers. 357 // Allocation support helpers.
350 void LoadAllocationTopHelper(Register result, 358 void LoadAllocationTopHelper(Register result,
351 Register result_end, 359 Register result_end,
352 Register scratch, 360 Register scratch,
353 AllocationFlags flags); 361 AllocationFlags flags);
354 void UpdateAllocationTopHelper(Register result_end, Register scratch); 362 void UpdateAllocationTopHelper(Register result_end, Register scratch);
355 }; 363 };
356 364
357 365
358 // The code patcher is used to patch (typically) small parts of code e.g. for 366 // The code patcher is used to patch (typically) small parts of code e.g. for
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
411 } \ 419 } \
412 masm-> 420 masm->
413 #else 421 #else
414 #define ACCESS_MASM(masm) masm-> 422 #define ACCESS_MASM(masm) masm->
415 #endif 423 #endif
416 424
417 425
418 } } // namespace v8::internal 426 } } // namespace v8::internal
419 427
420 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_ 428 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_
OLDNEW
« no previous file with comments | « src/ia32/frames-ia32.cc ('k') | src/ia32/macro-assembler-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698