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

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

Issue 6880010: Merge (7265, 7271] from bleeding_edge to experimental/gc branch.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/gc/
Patch Set: '' Created 9 years, 8 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
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 471 matching lines...) Expand 10 before | Expand all | Expand 10 after
482 482
483 // Tail call a code stub (jump) and return the code object called. Try to 483 // Tail call a code stub (jump) and return the code object called. Try to
484 // generate the code if necessary. Do not perform a GC but instead return 484 // generate the code if necessary. Do not perform a GC but instead return
485 // a retry after GC failure. 485 // a retry after GC failure.
486 MUST_USE_RESULT MaybeObject* TryTailCallStub(CodeStub* stub); 486 MUST_USE_RESULT MaybeObject* TryTailCallStub(CodeStub* stub);
487 487
488 // Return from a code stub after popping its arguments. 488 // Return from a code stub after popping its arguments.
489 void StubReturn(int argc); 489 void StubReturn(int argc);
490 490
491 // Call a runtime routine. 491 // Call a runtime routine.
492 void CallRuntime(Runtime::Function* f, int num_arguments); 492 void CallRuntime(const Runtime::Function* f, int num_arguments);
493 void CallRuntimeSaveDoubles(Runtime::FunctionId id); 493 void CallRuntimeSaveDoubles(Runtime::FunctionId id);
494 494
495 // Call a runtime function, returning the CodeStub object called. 495 // Call a runtime function, returning the CodeStub object called.
496 // Try to generate the stub code if necessary. Do not perform a GC 496 // Try to generate the stub code if necessary. Do not perform a GC
497 // but instead return a retry after GC failure. 497 // but instead return a retry after GC failure.
498 MUST_USE_RESULT MaybeObject* TryCallRuntime(Runtime::Function* f, 498 MUST_USE_RESULT MaybeObject* TryCallRuntime(const Runtime::Function* f,
499 int num_arguments); 499 int num_arguments);
500 500
501 // Convenience function: Same as above, but takes the fid instead. 501 // Convenience function: Same as above, but takes the fid instead.
502 void CallRuntime(Runtime::FunctionId id, int num_arguments); 502 void CallRuntime(Runtime::FunctionId id, int num_arguments);
503 503
504 // Convenience function: Same as above, but takes the fid instead. 504 // Convenience function: Same as above, but takes the fid instead.
505 MUST_USE_RESULT MaybeObject* TryCallRuntime(Runtime::FunctionId id, 505 MUST_USE_RESULT MaybeObject* TryCallRuntime(Runtime::FunctionId id,
506 int num_arguments); 506 int num_arguments);
507 507
508 // Convenience function: call an external reference. 508 // Convenience function: call an external reference.
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
710 // The mask isn't really an address. We load it as an external reference in 710 // The mask isn't really an address. We load it as an external reference in
711 // case the size of the new space is different between the snapshot maker 711 // case the size of the new space is different between the snapshot maker
712 // and the running system. 712 // and the running system.
713 and_(Operand(scratch), Immediate(ExternalReference::new_space_mask())); 713 and_(Operand(scratch), Immediate(ExternalReference::new_space_mask()));
714 cmp(Operand(scratch), Immediate(ExternalReference::new_space_start())); 714 cmp(Operand(scratch), Immediate(ExternalReference::new_space_start()));
715 j(cc, branch); 715 j(cc, branch);
716 } else { 716 } else {
717 int32_t new_space_start = reinterpret_cast<int32_t>( 717 int32_t new_space_start = reinterpret_cast<int32_t>(
718 ExternalReference::new_space_start().address()); 718 ExternalReference::new_space_start().address());
719 lea(scratch, Operand(object, -new_space_start)); 719 lea(scratch, Operand(object, -new_space_start));
720 and_(scratch, Heap::NewSpaceMask()); 720 and_(scratch, HEAP->NewSpaceMask());
721 j(cc, branch); 721 j(cc, branch);
722 } 722 }
723 } 723 }
724 724
725 725
726 // The code patcher is used to patch (typically) small parts of code e.g. for 726 // The code patcher is used to patch (typically) small parts of code e.g. for
727 // debugging and other types of instrumentation. When using the code patcher 727 // debugging and other types of instrumentation. When using the code patcher
728 // the exact number of bytes specified must be emitted. Is not legal to emit 728 // the exact number of bytes specified must be emitted. Is not legal to emit
729 // relocation information. If any of these constraints are violated it causes 729 // relocation information. If any of these constraints are violated it causes
730 // an assertion. 730 // an assertion.
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
804 } \ 804 } \
805 masm-> 805 masm->
806 #else 806 #else
807 #define ACCESS_MASM(masm) masm-> 807 #define ACCESS_MASM(masm) masm->
808 #endif 808 #endif
809 809
810 810
811 } } // namespace v8::internal 811 } } // namespace v8::internal
812 812
813 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_ 813 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698