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

Side by Side Diff: src/a64/full-codegen-a64.cc

Issue 206473002: Fix assertions wrt concurrent OSR. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 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 | « no previous file | test/mjsunit/assert-opt-and-deopt.js » ('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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 4850 matching lines...) Expand 10 before | Expand all | Expand 10 after
4861 4861
4862 switch (target_state) { 4862 switch (target_state) {
4863 case INTERRUPT: 4863 case INTERRUPT:
4864 // <decrement profiling counter> 4864 // <decrement profiling counter>
4865 // .. .. .. .. b.pl ok 4865 // .. .. .. .. b.pl ok
4866 // .. .. .. .. ldr x16, pc+<interrupt stub address> 4866 // .. .. .. .. ldr x16, pc+<interrupt stub address>
4867 // .. .. .. .. blr x16 4867 // .. .. .. .. blr x16
4868 // ... more instructions. 4868 // ... more instructions.
4869 // ok-label 4869 // ok-label
4870 // Jump offset is 6 instructions. 4870 // Jump offset is 6 instructions.
4871 ASSERT(Instruction::Cast(branch_address)
4872 ->IsNop(Assembler::INTERRUPT_CODE_NOP));
4873 patcher.b(6, pl); 4871 patcher.b(6, pl);
4874 break; 4872 break;
4875 case ON_STACK_REPLACEMENT: 4873 case ON_STACK_REPLACEMENT:
4876 case OSR_AFTER_STACK_CHECK: 4874 case OSR_AFTER_STACK_CHECK:
4877 // <decrement profiling counter> 4875 // <decrement profiling counter>
4878 // .. .. .. .. mov x0, x0 (NOP) 4876 // .. .. .. .. mov x0, x0 (NOP)
4879 // .. .. .. .. ldr x16, pc+<on-stack replacement address> 4877 // .. .. .. .. ldr x16, pc+<on-stack replacement address>
4880 // .. .. .. .. blr x16 4878 // .. .. .. .. blr x16
4881 ASSERT(Instruction::Cast(branch_address)->IsCondBranchImm());
4882 ASSERT(Instruction::Cast(branch_address)->ImmPCOffset() ==
4883 6 * kInstructionSize);
Yang 2014/03/20 13:33:05 Those assertions are bogus. We want to be able to
ulan 2014/03/20 13:50:46 Let's fix the asserts instead of removing them. =)
4884 patcher.nop(Assembler::INTERRUPT_CODE_NOP); 4879 patcher.nop(Assembler::INTERRUPT_CODE_NOP);
4885 break; 4880 break;
4886 } 4881 }
4887 4882
4888 // Replace the call address. 4883 // Replace the call address.
4889 Instruction* load = Instruction::Cast(pc)->preceding(2); 4884 Instruction* load = Instruction::Cast(pc)->preceding(2);
4890 Address interrupt_address_pointer = 4885 Address interrupt_address_pointer =
4891 reinterpret_cast<Address>(load) + load->ImmPCOffset(); 4886 reinterpret_cast<Address>(load) + load->ImmPCOffset();
4892 ASSERT((Memory::uint64_at(interrupt_address_pointer) == 4887 ASSERT((Memory::uint64_at(interrupt_address_pointer) ==
4893 reinterpret_cast<uint64_t>(unoptimized_code->GetIsolate() 4888 reinterpret_cast<uint64_t>(unoptimized_code->GetIsolate()
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
4972 return previous_; 4967 return previous_;
4973 } 4968 }
4974 4969
4975 4970
4976 #undef __ 4971 #undef __
4977 4972
4978 4973
4979 } } // namespace v8::internal 4974 } } // namespace v8::internal
4980 4975
4981 #endif // V8_TARGET_ARCH_A64 4976 #endif // V8_TARGET_ARCH_A64
OLDNEW
« no previous file with comments | « no previous file | test/mjsunit/assert-opt-and-deopt.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698