| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 4822 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4833 *context_length = 0; | 4833 *context_length = 0; |
| 4834 return previous_; | 4834 return previous_; |
| 4835 } | 4835 } |
| 4836 | 4836 |
| 4837 | 4837 |
| 4838 #undef __ | 4838 #undef __ |
| 4839 | 4839 |
| 4840 | 4840 |
| 4841 static const byte kJnsInstruction = 0x79; | 4841 static const byte kJnsInstruction = 0x79; |
| 4842 static const byte kJnsOffset = 0x1d; | 4842 static const byte kJnsOffset = 0x1d; |
| 4843 static const byte kCallInstruction = 0xe8; | |
| 4844 static const byte kNopByteOne = 0x66; | 4843 static const byte kNopByteOne = 0x66; |
| 4845 static const byte kNopByteTwo = 0x90; | 4844 static const byte kNopByteTwo = 0x90; |
| 4845 #ifdef DEBUG |
| 4846 static const byte kCallInstruction = 0xe8; |
| 4847 #endif |
| 4846 | 4848 |
| 4847 | 4849 |
| 4848 void BackEdgeTable::PatchAt(Code* unoptimized_code, | 4850 void BackEdgeTable::PatchAt(Code* unoptimized_code, |
| 4849 Address pc, | 4851 Address pc, |
| 4850 BackEdgeState target_state, | 4852 BackEdgeState target_state, |
| 4851 Code* replacement_code) { | 4853 Code* replacement_code) { |
| 4852 Address call_target_address = pc - kIntSize; | 4854 Address call_target_address = pc - kIntSize; |
| 4853 Address jns_instr_address = call_target_address - 3; | 4855 Address jns_instr_address = call_target_address - 3; |
| 4854 Address jns_offset_address = call_target_address - 2; | 4856 Address jns_offset_address = call_target_address - 2; |
| 4855 | 4857 |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4906 | 4908 |
| 4907 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), | 4909 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), |
| 4908 Assembler::target_address_at(call_target_address)); | 4910 Assembler::target_address_at(call_target_address)); |
| 4909 return OSR_AFTER_STACK_CHECK; | 4911 return OSR_AFTER_STACK_CHECK; |
| 4910 } | 4912 } |
| 4911 | 4913 |
| 4912 | 4914 |
| 4913 } } // namespace v8::internal | 4915 } } // namespace v8::internal |
| 4914 | 4916 |
| 4915 #endif // V8_TARGET_ARCH_X64 | 4917 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |