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

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

Issue 173561: Reverting 2768. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 3 months 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 | Annotate | Revision Log
« no previous file with comments | « src/ia32/codegen-ia32-inl.h ('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-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 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 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 177
178 // Generate code for checking access rights - used for security checks 178 // Generate code for checking access rights - used for security checks
179 // on access to global objects across environments. The holder register 179 // on access to global objects across environments. The holder register
180 // is left untouched, but the scratch register is clobbered. 180 // is left untouched, but the scratch register is clobbered.
181 void CheckAccessGlobalProxy(Register holder_reg, 181 void CheckAccessGlobalProxy(Register holder_reg,
182 Register scratch, 182 Register scratch,
183 Label* miss); 183 Label* miss);
184 184
185 185
186 // --------------------------------------------------------------------------- 186 // ---------------------------------------------------------------------------
187 // Allocation support
188
189 // Allocate an object in new space. If the new space is exhausted control
190 // continues at the gc_required label. The allocated object is returned in
191 // result and end of the new object is returned in result_end. The register
192 // scratch can be passed as no_reg in which case an additional object
193 // reference will be added to the reloc info. The returned pointers in result
194 // and result_end have not yet been tagged as heap objects. If
195 // result_contains_top_on_entry is true the contnt of result is known to be
196 // the allocation top on entry (could be result_end from a previous call to
197 // AllocateObjectInNewSpace). If result_contains_top_on_entry is true scratch
198 // should be no_reg as it is never used.
199 void AllocateObjectInNewSpace(int object_size,
200 Register result,
201 Register result_end,
202 Register scratch,
203 Label* gc_required,
204 bool result_contains_top_on_entry);
205
206 void AllocateObjectInNewSpace(int header_size,
207 ScaleFactor element_size,
208 Register element_count,
209 Register result,
210 Register result_end,
211 Register scratch,
212 Label* gc_required,
213 bool result_contains_top_on_entry);
214
215 void AllocateObjectInNewSpace(Register object_size,
216 Register result,
217 Register result_end,
218 Register scratch,
219 Label* gc_required,
220 bool result_contains_top_on_entry);
221
222 // Undo allocation in new space. The object passed and objects allocated after
223 // it will no longer be allocated. Make sure that no pointers are left to the
224 // object(s) no longer allocated as they would be invalid when allocation is
225 // un-done.
226 void UndoAllocationInNewSpace(Register object);
227
228 // ---------------------------------------------------------------------------
229 // Support functions. 187 // Support functions.
230 188
231 // Check if result is zero and op is negative. 189 // Check if result is zero and op is negative.
232 void NegativeZeroTest(Register result, Register op, Label* then_label); 190 void NegativeZeroTest(Register result, Register op, Label* then_label);
233 191
234 // Check if result is zero and op is negative in code using jump targets. 192 // Check if result is zero and op is negative in code using jump targets.
235 void NegativeZeroTest(CodeGenerator* cgen, 193 void NegativeZeroTest(CodeGenerator* cgen,
236 Register result, 194 Register result,
237 Register op, 195 Register op,
238 JumpTarget* then_target); 196 JumpTarget* then_target);
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
338 Label* done, 296 Label* done,
339 InvokeFlag flag); 297 InvokeFlag flag);
340 298
341 // Get the code for the given builtin. Returns if able to resolve 299 // Get the code for the given builtin. Returns if able to resolve
342 // the function in the 'resolved' flag. 300 // the function in the 'resolved' flag.
343 Handle<Code> ResolveBuiltin(Builtins::JavaScript id, bool* resolved); 301 Handle<Code> ResolveBuiltin(Builtins::JavaScript id, bool* resolved);
344 302
345 // Activation support. 303 // Activation support.
346 void EnterFrame(StackFrame::Type type); 304 void EnterFrame(StackFrame::Type type);
347 void LeaveFrame(StackFrame::Type type); 305 void LeaveFrame(StackFrame::Type type);
348
349 // Allocation support helpers.
350 void LoadAllocationTopHelper(Register result,
351 Register result_end,
352 Register scratch,
353 bool result_contains_top_on_entry);
354 void UpdateAllocationTopHelper(Register result_end, Register scratch);
355 }; 306 };
356 307
357 308
358 // The code patcher is used to patch (typically) small parts of code e.g. for 309 // The code patcher is used to patch (typically) small parts of code e.g. for
359 // debugging and other types of instrumentation. When using the code patcher 310 // debugging and other types of instrumentation. When using the code patcher
360 // the exact number of bytes specified must be emitted. Is not legal to emit 311 // the exact number of bytes specified must be emitted. Is not legal to emit
361 // relocation information. If any of these constraints are violated it causes 312 // relocation information. If any of these constraints are violated it causes
362 // an assertion. 313 // an assertion.
363 class CodePatcher { 314 class CodePatcher {
364 public: 315 public:
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
411 } \ 362 } \
412 masm-> 363 masm->
413 #else 364 #else
414 #define ACCESS_MASM(masm) masm-> 365 #define ACCESS_MASM(masm) masm->
415 #endif 366 #endif
416 367
417 368
418 } } // namespace v8::internal 369 } } // namespace v8::internal
419 370
420 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_ 371 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_
OLDNEW
« no previous file with comments | « src/ia32/codegen-ia32-inl.h ('k') | src/ia32/macro-assembler-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698