| OLD | NEW |
| 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 1059 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1070 b->Unuse(); | 1070 b->Unuse(); |
| 1071 } | 1071 } |
| 1072 | 1072 |
| 1073 | 1073 |
| 1074 Result VirtualFrame::CallLoadIC(RelocInfo::Mode mode) { | 1074 Result VirtualFrame::CallLoadIC(RelocInfo::Mode mode) { |
| 1075 // Name and receiver are on the top of the frame. Both are dropped. | 1075 // Name and receiver are on the top of the frame. Both are dropped. |
| 1076 // The IC expects name in rcx and receiver in rax. | 1076 // The IC expects name in rcx and receiver in rax. |
| 1077 Handle<Code> ic(Builtins::builtin(Builtins::LoadIC_Initialize)); | 1077 Handle<Code> ic(Builtins::builtin(Builtins::LoadIC_Initialize)); |
| 1078 Result name = Pop(); | 1078 Result name = Pop(); |
| 1079 Result receiver = Pop(); | 1079 Result receiver = Pop(); |
| 1080 PrepareForCall(0, 0); // One stack arg, not callee-dropped. | 1080 PrepareForCall(0, 0); |
| 1081 MoveResultsToRegisters(&name, &receiver, rcx, rax); | 1081 MoveResultsToRegisters(&name, &receiver, rcx, rax); |
| 1082 | 1082 |
| 1083 return RawCallCodeObject(ic, mode); | 1083 return RawCallCodeObject(ic, mode); |
| 1084 } | 1084 } |
| 1085 | 1085 |
| 1086 | 1086 |
| 1087 Result VirtualFrame::CallKeyedLoadIC(RelocInfo::Mode mode) { | 1087 Result VirtualFrame::CallKeyedLoadIC(RelocInfo::Mode mode) { |
| 1088 // Key and receiver are on top of the frame. The IC expects them on | 1088 // Key and receiver are on top of the frame. The IC expects them on |
| 1089 // the stack. It does not drop them. | 1089 // the stack. It does not drop them. |
| 1090 Handle<Code> ic(Builtins::builtin(Builtins::KeyedLoadIC_Initialize)); | 1090 Handle<Code> ic(Builtins::builtin(Builtins::KeyedLoadIC_Initialize)); |
| 1091 PrepareForCall(2, 0); // Two stack args, neither callee-dropped. | 1091 Result name = Pop(); |
| 1092 Result receiver = Pop(); |
| 1093 PrepareForCall(0, 0); |
| 1094 MoveResultsToRegisters(&name, &receiver, rax, rdx); |
| 1092 return RawCallCodeObject(ic, mode); | 1095 return RawCallCodeObject(ic, mode); |
| 1093 } | 1096 } |
| 1094 | 1097 |
| 1095 | 1098 |
| 1096 Result VirtualFrame::CallCommonStoreIC(Handle<Code> ic, | 1099 Result VirtualFrame::CallCommonStoreIC(Handle<Code> ic, |
| 1097 Result* value, | 1100 Result* value, |
| 1098 Result* key, | 1101 Result* key, |
| 1099 Result* receiver) { | 1102 Result* receiver) { |
| 1100 // The IC expects value in rax, key in rcx, and receiver in rdx. | 1103 // The IC expects value in rax, key in rcx, and receiver in rdx. |
| 1101 PrepareForCall(0, 0); | 1104 PrepareForCall(0, 0); |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1192 Adjust(kHandlerSize - 1); | 1195 Adjust(kHandlerSize - 1); |
| 1193 __ PushTryHandler(IN_JAVASCRIPT, type); | 1196 __ PushTryHandler(IN_JAVASCRIPT, type); |
| 1194 } | 1197 } |
| 1195 | 1198 |
| 1196 | 1199 |
| 1197 #undef __ | 1200 #undef __ |
| 1198 | 1201 |
| 1199 } } // namespace v8::internal | 1202 } } // namespace v8::internal |
| 1200 | 1203 |
| 1201 #endif // V8_TARGET_ARCH_X64 | 1204 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |