OLD | NEW |
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 2148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2159 // in AAPCS64. If the stub is moved (perhaps during a GC), we could end up | 2159 // in AAPCS64. If the stub is moved (perhaps during a GC), we could end up |
2160 // returning to dead code. | 2160 // returning to dead code. |
2161 // TODO(jbramley): Whilst this is the only analysis that makes sense, I can't | 2161 // TODO(jbramley): Whilst this is the only analysis that makes sense, I can't |
2162 // find any comment to confirm this, and I don't hit any crashes whatever | 2162 // find any comment to confirm this, and I don't hit any crashes whatever |
2163 // this function returns. The anaylsis should be properly confirmed. | 2163 // this function returns. The anaylsis should be properly confirmed. |
2164 return true; | 2164 return true; |
2165 } | 2165 } |
2166 | 2166 |
2167 | 2167 |
2168 bool CEntryStub::IsPregenerated() { | 2168 bool CEntryStub::IsPregenerated() { |
2169 // TODO(jbramley): We should pregenerate kSaveFPRegs too, once we support it. | 2169 return result_size_ == 1; |
2170 return (save_doubles_ == kDontSaveFPRegs) && (result_size_ == 1); | |
2171 } | 2170 } |
2172 | 2171 |
2173 | 2172 |
2174 void CEntryStub::GenerateAheadOfTime(Isolate* isolate) { | 2173 void CEntryStub::GenerateAheadOfTime(Isolate* isolate) { |
2175 CEntryStub stub(1, kDontSaveFPRegs); | 2174 CEntryStub stub(1, kDontSaveFPRegs); |
2176 stub.GetCode(isolate)->set_is_pregenerated(true); | 2175 stub.GetCode(isolate)->set_is_pregenerated(true); |
2177 // TODO(jbramley): We should generate kSaveFPRegs here too, but it is not yet | 2176 CEntryStub stub_fp(1, kSaveFPRegs); |
2178 // implemented by CEntryStub because it is only used by Lithium. | 2177 stub_fp.GetCode(isolate)->set_is_pregenerated(true); |
2179 } | 2178 } |
2180 | 2179 |
2181 | 2180 |
2182 void CEntryStub::GenerateCore(MacroAssembler* masm, | 2181 void CEntryStub::GenerateCore(MacroAssembler* masm, |
2183 Label* throw_normal, | 2182 Label* throw_normal, |
2184 Label* throw_termination, | 2183 Label* throw_termination, |
2185 Label* throw_out_of_memory, | 2184 Label* throw_out_of_memory, |
2186 bool do_gc, | 2185 bool do_gc, |
2187 bool always_allocate) { | 2186 bool always_allocate) { |
2188 // x0 : Result parameter for PerformGC, if do_gc is true. | 2187 // x0 : Result parameter for PerformGC, if do_gc is true. |
(...skipping 4716 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6905 __ Bind(&fast_elements_case); | 6904 __ Bind(&fast_elements_case); |
6906 GenerateCase(masm, FAST_ELEMENTS); | 6905 GenerateCase(masm, FAST_ELEMENTS); |
6907 } | 6906 } |
6908 | 6907 |
6909 | 6908 |
6910 #undef __ | 6909 #undef __ |
6911 | 6910 |
6912 } } // namespace v8::internal | 6911 } } // namespace v8::internal |
6913 | 6912 |
6914 #endif // V8_TARGET_ARCH_A64 | 6913 #endif // V8_TARGET_ARCH_A64 |
OLD | NEW |