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

Side by Side Diff: src/compiler/simplified-lowering.cc

Issue 2495243002: [turbofan] Fix deoptimization of boolean bit constants. (Closed)
Patch Set: Created 4 years, 1 month 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/code-generator.cc ('k') | test/mjsunit/compiler/regress-664490.js » ('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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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/simplified-lowering.h" 5 #include "src/compiler/simplified-lowering.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "src/address-map.h" 9 #include "src/address-map.h"
10 #include "src/base/bits.h" 10 #include "src/base/bits.h"
(...skipping 1012 matching lines...) Expand 10 before | Expand all | Expand 10 after
1023 (*types)[i] = MachineType::Pointer(); 1023 (*types)[i] = MachineType::Pointer();
1024 } else { 1024 } else {
1025 MachineRepresentation rep = input_type->IsInhabited() 1025 MachineRepresentation rep = input_type->IsInhabited()
1026 ? input_info->representation() 1026 ? input_info->representation()
1027 : MachineRepresentation::kNone; 1027 : MachineRepresentation::kNone;
1028 MachineType machine_type(rep, DeoptValueSemanticOf(input_type)); 1028 MachineType machine_type(rep, DeoptValueSemanticOf(input_type));
1029 DCHECK(machine_type.representation() != 1029 DCHECK(machine_type.representation() !=
1030 MachineRepresentation::kWord32 || 1030 MachineRepresentation::kWord32 ||
1031 machine_type.semantic() == MachineSemantic::kInt32 || 1031 machine_type.semantic() == MachineSemantic::kInt32 ||
1032 machine_type.semantic() == MachineSemantic::kUint32); 1032 machine_type.semantic() == MachineSemantic::kUint32);
1033 DCHECK(machine_type.representation() != MachineRepresentation::kBit ||
1034 input_type->Is(Type::Boolean()));
1033 (*types)[i] = machine_type; 1035 (*types)[i] = machine_type;
1034 } 1036 }
1035 } 1037 }
1036 NodeProperties::ChangeOp(node, 1038 NodeProperties::ChangeOp(node,
1037 jsgraph_->common()->TypedObjectState(types)); 1039 jsgraph_->common()->TypedObjectState(types));
1038 } 1040 }
1039 SetOutput(node, MachineRepresentation::kTagged); 1041 SetOutput(node, MachineRepresentation::kTagged);
1040 } 1042 }
1041 1043
1042 const Operator* Int32Op(Node* node) { 1044 const Operator* Int32Op(Node* node) {
(...skipping 2362 matching lines...) Expand 10 before | Expand all | Expand 10 after
3405 isolate(), graph()->zone(), callable.descriptor(), 0, flags, 3407 isolate(), graph()->zone(), callable.descriptor(), 0, flags,
3406 Operator::kNoProperties); 3408 Operator::kNoProperties);
3407 to_number_operator_.set(common()->Call(desc)); 3409 to_number_operator_.set(common()->Call(desc));
3408 } 3410 }
3409 return to_number_operator_.get(); 3411 return to_number_operator_.get();
3410 } 3412 }
3411 3413
3412 } // namespace compiler 3414 } // namespace compiler
3413 } // namespace internal 3415 } // namespace internal
3414 } // namespace v8 3416 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/code-generator.cc ('k') | test/mjsunit/compiler/regress-664490.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698