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

Side by Side Diff: src/compiler/x64/code-generator-x64.cc

Issue 2900683002: [compiler] Delay allocation of code-embedded heap numbers. (Closed)
Patch Set: Fix rebase. Created 3 years, 6 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
« no previous file with comments | « src/compiler/ia32/code-generator-ia32.cc ('k') | src/deoptimizer.cc » ('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 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/compiler/code-generator.h" 5 #include "src/compiler/code-generator.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "src/compilation-info.h" 9 #include "src/compilation-info.h"
10 #include "src/compiler/code-generator-impl.h" 10 #include "src/compiler/code-generator-impl.h"
(...skipping 3002 matching lines...) Expand 10 before | Expand all | Expand 10 after
3013 } 3013 }
3014 case Constant::kInt64: 3014 case Constant::kInt64:
3015 if (RelocInfo::IsWasmPtrReference(src.rmode())) { 3015 if (RelocInfo::IsWasmPtrReference(src.rmode())) {
3016 __ movq(dst, src.ToInt64(), src.rmode()); 3016 __ movq(dst, src.ToInt64(), src.rmode());
3017 } else { 3017 } else {
3018 DCHECK(!RelocInfo::IsWasmSizeReference(src.rmode())); 3018 DCHECK(!RelocInfo::IsWasmSizeReference(src.rmode()));
3019 __ Set(dst, src.ToInt64()); 3019 __ Set(dst, src.ToInt64());
3020 } 3020 }
3021 break; 3021 break;
3022 case Constant::kFloat32: 3022 case Constant::kFloat32:
3023 __ Move(dst, 3023 __ MoveNumber(dst, src.ToFloat32());
3024 isolate()->factory()->NewNumber(src.ToFloat32(), TENURED));
3025 break; 3024 break;
3026 case Constant::kFloat64: 3025 case Constant::kFloat64:
3027 __ Move(dst, 3026 __ MoveNumber(dst, src.ToFloat64());
3028 isolate()->factory()->NewNumber(src.ToFloat64(), TENURED));
3029 break; 3027 break;
3030 case Constant::kExternalReference: 3028 case Constant::kExternalReference:
3031 __ Move(dst, src.ToExternalReference()); 3029 __ Move(dst, src.ToExternalReference());
3032 break; 3030 break;
3033 case Constant::kHeapObject: { 3031 case Constant::kHeapObject: {
3034 Handle<HeapObject> src_object = src.ToHeapObject(); 3032 Handle<HeapObject> src_object = src.ToHeapObject();
3035 Heap::RootListIndex index; 3033 Heap::RootListIndex index;
3036 if (IsMaterializableFromRoot(src_object, &index)) { 3034 if (IsMaterializableFromRoot(src_object, &index)) {
3037 __ LoadRoot(dst, index); 3035 __ LoadRoot(dst, index);
3038 } else { 3036 } else {
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
3214 int padding_size = last_lazy_deopt_pc_ + space_needed - current_pc; 3212 int padding_size = last_lazy_deopt_pc_ + space_needed - current_pc;
3215 __ Nop(padding_size); 3213 __ Nop(padding_size);
3216 } 3214 }
3217 } 3215 }
3218 3216
3219 #undef __ 3217 #undef __
3220 3218
3221 } // namespace compiler 3219 } // namespace compiler
3222 } // namespace internal 3220 } // namespace internal
3223 } // namespace v8 3221 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/ia32/code-generator-ia32.cc ('k') | src/deoptimizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698