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

Side by Side Diff: test/unittests/compiler/common-operator-unittest.cc

Issue 1123213002: [turbofan] Connect non-terminating loops via Terminate. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 7 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/verifier.cc ('k') | test/unittests/compiler/control-reducer-unittest.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 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 <limits> 5 #include <limits>
6 6
7 #include "src/compiler/common-operator.h" 7 #include "src/compiler/common-operator.h"
8 #include "src/compiler/opcodes.h" 8 #include "src/compiler/opcodes.h"
9 #include "src/compiler/operator.h" 9 #include "src/compiler/operator.h"
10 #include "src/compiler/operator-properties.h" 10 #include "src/compiler/operator-properties.h"
(...skipping 30 matching lines...) Expand all
41 41
42 const SharedOperator kSharedOperators[] = { 42 const SharedOperator kSharedOperators[] = {
43 #define SHARED(Name, properties, value_input_count, effect_input_count, \ 43 #define SHARED(Name, properties, value_input_count, effect_input_count, \
44 control_input_count, value_output_count, effect_output_count, \ 44 control_input_count, value_output_count, effect_output_count, \
45 control_output_count) \ 45 control_output_count) \
46 { \ 46 { \
47 &CommonOperatorBuilder::Name, IrOpcode::k##Name, properties, \ 47 &CommonOperatorBuilder::Name, IrOpcode::k##Name, properties, \
48 value_input_count, effect_input_count, control_input_count, \ 48 value_input_count, effect_input_count, control_input_count, \
49 value_output_count, effect_output_count, control_output_count \ 49 value_output_count, effect_output_count, control_output_count \
50 } 50 }
51 SHARED(Always, Operator::kPure, 0, 0, 0, 1, 0, 0),
52 SHARED(Dead, Operator::kFoldable, 0, 0, 0, 0, 0, 1), 51 SHARED(Dead, Operator::kFoldable, 0, 0, 0, 0, 0, 1),
53 SHARED(End, Operator::kKontrol, 0, 0, 1, 0, 0, 0), 52 SHARED(End, Operator::kKontrol, 0, 0, 1, 0, 0, 0),
54 SHARED(IfTrue, Operator::kKontrol, 0, 0, 1, 0, 0, 1), 53 SHARED(IfTrue, Operator::kKontrol, 0, 0, 1, 0, 0, 1),
55 SHARED(IfFalse, Operator::kKontrol, 0, 0, 1, 0, 0, 1), 54 SHARED(IfFalse, Operator::kKontrol, 0, 0, 1, 0, 0, 1),
56 SHARED(IfSuccess, Operator::kKontrol, 0, 0, 1, 0, 0, 1), 55 SHARED(IfSuccess, Operator::kKontrol, 0, 0, 1, 0, 0, 1),
57 SHARED(IfException, Operator::kKontrol, 0, 0, 1, 1, 0, 1), 56 SHARED(IfException, Operator::kKontrol, 0, 0, 1, 1, 0, 1),
58 SHARED(Throw, Operator::kKontrol, 1, 1, 1, 0, 0, 1), 57 SHARED(Throw, Operator::kKontrol, 1, 1, 1, 0, 0, 1),
59 SHARED(Return, Operator::kNoThrow, 1, 1, 1, 0, 0, 1) 58 SHARED(Return, Operator::kNoThrow, 1, 1, 1, 0, 0, 1),
59 SHARED(Terminate, Operator::kNoThrow, 0, 1, 1, 0, 0, 1)
60 #undef SHARED 60 #undef SHARED
61 }; 61 };
62 62
63 63
64 class CommonSharedOperatorTest 64 class CommonSharedOperatorTest
65 : public TestWithZone, 65 : public TestWithZone,
66 public ::testing::WithParamInterface<SharedOperator> {}; 66 public ::testing::WithParamInterface<SharedOperator> {};
67 67
68 } // namespace 68 } // namespace
69 69
(...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after
339 EXPECT_EQ(arguments + 1, OperatorProperties::GetTotalInputCount(op)); 339 EXPECT_EQ(arguments + 1, OperatorProperties::GetTotalInputCount(op));
340 EXPECT_EQ(0, op->ControlOutputCount()); 340 EXPECT_EQ(0, op->ControlOutputCount());
341 EXPECT_EQ(0, op->EffectOutputCount()); 341 EXPECT_EQ(0, op->EffectOutputCount());
342 EXPECT_EQ(1, op->ValueOutputCount()); 342 EXPECT_EQ(1, op->ValueOutputCount());
343 } 343 }
344 } 344 }
345 345
346 } // namespace compiler 346 } // namespace compiler
347 } // namespace internal 347 } // namespace internal
348 } // namespace v8 348 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/verifier.cc ('k') | test/unittests/compiler/control-reducer-unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698