| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
| 2 // Rrdistribution and use in source and binary forms, with or without | 2 // Rrdistribution 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 // * Rrdistributions of source code must retain the above copyright | 6 // * Rrdistributions 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 // * Rrdistributions in binary form must reproduce the above | 8 // * Rrdistributions 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 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 86 // Call through to the actual stub | 86 // Call through to the actual stub |
| 87 __ Call(start, RelocInfo::EXTERNAL_REFERENCE); | 87 __ Call(start, RelocInfo::EXTERNAL_REFERENCE); |
| 88 | 88 |
| 89 __ addq(rsp, Immediate(kDoubleSize)); | 89 __ addq(rsp, Immediate(kDoubleSize)); |
| 90 | 90 |
| 91 // Make sure no registers have been unexpectedly clobbered | 91 // Make sure no registers have been unexpectedly clobbered |
| 92 for (--reg_num; reg_num >= 0; --reg_num) { | 92 for (--reg_num; reg_num >= 0; --reg_num) { |
| 93 Register reg = Register::from_code(reg_num); | 93 Register reg = Register::from_code(reg_num); |
| 94 if (!reg.is(rsp) && !reg.is(rbp) && !reg.is(destination_reg)) { | 94 if (!reg.is(rsp) && !reg.is(rbp) && !reg.is(destination_reg)) { |
| 95 __ cmpq(reg, MemOperand(rsp, 0)); | 95 __ cmpq(reg, MemOperand(rsp, 0)); |
| 96 __ Assert(equal, "register was clobbered"); | 96 __ Assert(equal, kRegisterWasClobbered); |
| 97 __ addq(rsp, Immediate(kPointerSize)); | 97 __ addq(rsp, Immediate(kPointerSize)); |
| 98 } | 98 } |
| 99 } | 99 } |
| 100 | 100 |
| 101 __ movq(rax, destination_reg); | 101 __ movq(rax, destination_reg); |
| 102 | 102 |
| 103 __ pop(rdi); | 103 __ pop(rdi); |
| 104 __ pop(rsi); | 104 __ pop(rsi); |
| 105 __ pop(rdx); | 105 __ pop(rdx); |
| 106 __ pop(rcx); | 106 __ pop(rcx); |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 | 140 |
| 141 for (size_t s = 0; s < sizeof(*source_registers); s++) { | 141 for (size_t s = 0; s < sizeof(*source_registers); s++) { |
| 142 for (size_t d = 0; d < sizeof(*dest_registers); d++) { | 142 for (size_t d = 0; d < sizeof(*dest_registers); d++) { |
| 143 RunAllTruncationTests( | 143 RunAllTruncationTests( |
| 144 MakeConvertDToIFuncTrampoline(isolate, | 144 MakeConvertDToIFuncTrampoline(isolate, |
| 145 source_registers[s], | 145 source_registers[s], |
| 146 dest_registers[d])); | 146 dest_registers[d])); |
| 147 } | 147 } |
| 148 } | 148 } |
| 149 } | 149 } |
| OLD | NEW |