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

Side by Side Diff: src/assembler.cc

Issue 261953002: Fix for 3303 MultithreadedParallelIsolates has a race condition. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed ICache arm simulator issue. Created 6 years, 7 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/assembler.h ('k') | src/codegen.h » ('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 (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 706 matching lines...) Expand 10 before | Expand all | Expand 10 after
717 rinfo_.pc_ = code->instruction_start(); 717 rinfo_.pc_ = code->instruction_start();
718 rinfo_.data_ = 0; 718 rinfo_.data_ = 0;
719 // Relocation info is read backwards. 719 // Relocation info is read backwards.
720 pos_ = code->relocation_start() + code->relocation_size(); 720 pos_ = code->relocation_start() + code->relocation_size();
721 end_ = code->relocation_start(); 721 end_ = code->relocation_start();
722 done_ = false; 722 done_ = false;
723 mode_mask_ = mode_mask; 723 mode_mask_ = mode_mask;
724 last_id_ = 0; 724 last_id_ = 0;
725 last_position_ = 0; 725 last_position_ = 0;
726 byte* sequence = code->FindCodeAgeSequence(); 726 byte* sequence = code->FindCodeAgeSequence();
727 if (sequence != NULL && !Code::IsYoungSequence(sequence)) { 727 // We get the isolate from the map, because at serialization time
728 // the code pointer has been cloned and isn't really in heap space.
729 Isolate* isolate = code->map()->GetIsolate();
730 if (sequence != NULL && !Code::IsYoungSequence(isolate, sequence)) {
728 code_age_sequence_ = sequence; 731 code_age_sequence_ = sequence;
729 } else { 732 } else {
730 code_age_sequence_ = NULL; 733 code_age_sequence_ = NULL;
731 } 734 }
732 if (mode_mask_ == 0) pos_ = end_; 735 if (mode_mask_ == 0) pos_ = end_;
733 next(); 736 next();
734 } 737 }
735 738
736 739
737 RelocIterator::RelocIterator(const CodeDesc& desc, int mode_mask) { 740 RelocIterator::RelocIterator(const CodeDesc& desc, int mode_mask) {
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
849 PrintF(out, " (deoptimization bailout %d)", id); 852 PrintF(out, " (deoptimization bailout %d)", id);
850 } 853 }
851 } 854 }
852 855
853 PrintF(out, "\n"); 856 PrintF(out, "\n");
854 } 857 }
855 #endif // ENABLE_DISASSEMBLER 858 #endif // ENABLE_DISASSEMBLER
856 859
857 860
858 #ifdef VERIFY_HEAP 861 #ifdef VERIFY_HEAP
859 void RelocInfo::Verify() { 862 void RelocInfo::Verify(Isolate* isolate) {
860 switch (rmode_) { 863 switch (rmode_) {
861 case EMBEDDED_OBJECT: 864 case EMBEDDED_OBJECT:
862 Object::VerifyPointer(target_object()); 865 Object::VerifyPointer(target_object());
863 break; 866 break;
864 case CELL: 867 case CELL:
865 Object::VerifyPointer(target_cell()); 868 Object::VerifyPointer(target_cell());
866 break; 869 break;
867 case DEBUG_BREAK: 870 case DEBUG_BREAK:
868 case CONSTRUCT_CALL: 871 case CONSTRUCT_CALL:
869 case CODE_TARGET_WITH_ID: 872 case CODE_TARGET_WITH_ID:
870 case CODE_TARGET: { 873 case CODE_TARGET: {
871 // convert inline target address to code object 874 // convert inline target address to code object
872 Address addr = target_address(); 875 Address addr = target_address();
873 CHECK(addr != NULL); 876 CHECK(addr != NULL);
874 // Check that we can find the right code object. 877 // Check that we can find the right code object.
875 Code* code = Code::GetCodeFromTargetAddress(addr); 878 Code* code = Code::GetCodeFromTargetAddress(addr);
876 Object* found = code->GetIsolate()->FindCodeObject(addr); 879 Object* found = isolate->FindCodeObject(addr);
877 CHECK(found->IsCode()); 880 CHECK(found->IsCode());
878 CHECK(code->address() == HeapObject::cast(found)->address()); 881 CHECK(code->address() == HeapObject::cast(found)->address());
879 break; 882 break;
880 } 883 }
881 case RUNTIME_ENTRY: 884 case RUNTIME_ENTRY:
882 case JS_RETURN: 885 case JS_RETURN:
883 case COMMENT: 886 case COMMENT:
884 case POSITION: 887 case POSITION:
885 case STATEMENT_POSITION: 888 case STATEMENT_POSITION:
886 case EXTERNAL_REFERENCE: 889 case EXTERNAL_REFERENCE:
887 case INTERNAL_REFERENCE: 890 case INTERNAL_REFERENCE:
888 case CONST_POOL: 891 case CONST_POOL:
889 case VENEER_POOL: 892 case VENEER_POOL:
890 case DEBUG_BREAK_SLOT: 893 case DEBUG_BREAK_SLOT:
891 case NONE32: 894 case NONE32:
892 case NONE64: 895 case NONE64:
893 break; 896 break;
894 case NUMBER_OF_MODES: 897 case NUMBER_OF_MODES:
895 UNREACHABLE(); 898 UNREACHABLE();
896 break; 899 break;
897 case CODE_AGE_SEQUENCE: 900 case CODE_AGE_SEQUENCE:
898 ASSERT(Code::IsYoungSequence(pc_) || code_age_stub()->IsCode()); 901 ASSERT(Code::IsYoungSequence(isolate, pc_) || code_age_stub()->IsCode());
899 break; 902 break;
900 } 903 }
901 } 904 }
902 #endif // VERIFY_HEAP 905 #endif // VERIFY_HEAP
903 906
904 907
905 // ----------------------------------------------------------------------------- 908 // -----------------------------------------------------------------------------
906 // Implementation of ExternalReference 909 // Implementation of ExternalReference
907 910
908 void ExternalReference::SetUp() { 911 void ExternalReference::SetUp() {
(...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after
1639 r2 = r2 - ad; 1642 r2 = r2 - ad;
1640 } 1643 }
1641 delta = ad - r2; 1644 delta = ad - r2;
1642 } while (q1 < delta || (q1 == delta && r1 == 0)); 1645 } while (q1 < delta || (q1 == delta && r1 == 0));
1643 int32_t mul = static_cast<int32_t>(q2 + 1); 1646 int32_t mul = static_cast<int32_t>(q2 + 1);
1644 multiplier_ = (d < 0) ? -mul : mul; 1647 multiplier_ = (d < 0) ? -mul : mul;
1645 shift_ = p - 32; 1648 shift_ = p - 32;
1646 } 1649 }
1647 1650
1648 } } // namespace v8::internal 1651 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/assembler.h ('k') | src/codegen.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698