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

Unified Diff: src/compiler/simplified-lowering.cc

Issue 2177193002: [Turbofan] Too-strong CHECK during optimization. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix nit. Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-crbug-630952.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/simplified-lowering.cc
diff --git a/src/compiler/simplified-lowering.cc b/src/compiler/simplified-lowering.cc
index d1bea0a1194920b70402adef806b733f141fd42f..c2e8e97e2329ed479ec99704d2a8b2fec076a593 100644
--- a/src/compiler/simplified-lowering.cc
+++ b/src/compiler/simplified-lowering.cc
@@ -128,54 +128,6 @@ void ChangeToPureOp(Node* node, const Operator* new_op) {
#ifdef DEBUG
// Helpers for monotonicity checking.
-bool MachineRepresentationIsSubtype(MachineRepresentation r1,
- MachineRepresentation r2) {
- switch (r1) {
- case MachineRepresentation::kNone:
- return true;
- case MachineRepresentation::kBit:
- return r2 == MachineRepresentation::kBit ||
- r2 == MachineRepresentation::kTagged;
- case MachineRepresentation::kWord8:
- return r2 == MachineRepresentation::kWord8 ||
- r2 == MachineRepresentation::kWord16 ||
- r2 == MachineRepresentation::kWord32 ||
- r2 == MachineRepresentation::kWord64 ||
- r2 == MachineRepresentation::kFloat32 ||
- r2 == MachineRepresentation::kFloat64 ||
- r2 == MachineRepresentation::kTagged;
- case MachineRepresentation::kWord16:
- return r2 == MachineRepresentation::kWord16 ||
- r2 == MachineRepresentation::kWord32 ||
- r2 == MachineRepresentation::kWord64 ||
- r2 == MachineRepresentation::kFloat32 ||
- r2 == MachineRepresentation::kFloat64 ||
- r2 == MachineRepresentation::kTagged;
- case MachineRepresentation::kWord32:
- return r2 == MachineRepresentation::kWord32 ||
- r2 == MachineRepresentation::kWord64 ||
- r2 == MachineRepresentation::kFloat64 ||
- r2 == MachineRepresentation::kTagged;
- case MachineRepresentation::kWord64:
- return r2 == MachineRepresentation::kWord64;
- case MachineRepresentation::kFloat32:
- return r2 == MachineRepresentation::kFloat32 ||
- r2 == MachineRepresentation::kFloat64 ||
- r2 == MachineRepresentation::kTagged;
- case MachineRepresentation::kFloat64:
- return r2 == MachineRepresentation::kFloat64 ||
- r2 == MachineRepresentation::kTagged;
- case MachineRepresentation::kSimd128:
- return r2 == MachineRepresentation::kSimd128 ||
- r2 == MachineRepresentation::kTagged;
- case MachineRepresentation::kTagged:
- return r2 == MachineRepresentation::kTagged;
- }
- UNREACHABLE();
- return false;
-}
-
-
class InputUseInfos {
public:
explicit InputUseInfos(Zone* zone) : input_use_infos_(zone) {}
@@ -194,9 +146,7 @@ class InputUseInfos {
ZoneVector<UseInfo> input_use_infos_;
static bool IsUseLessGeneral(UseInfo use1, UseInfo use2) {
- return MachineRepresentationIsSubtype(use1.representation(),
- use2.representation()) &&
- use1.truncation().IsLessGeneralThan(use2.truncation());
+ return use1.truncation().IsLessGeneralThan(use2.truncation());
}
};
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-crbug-630952.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698