@@ -93,14 +93,8 @@ void PhaseMacroExpand::migrate_outs(Node *old, Node *target) {
93
93
assert (old->outcnt () == 0 , " all uses must be deleted" );
94
94
}
95
95
96
- Node* PhaseMacroExpand::opt_bits_test (Node* ctrl, Node* region, int edge, Node* word, int mask, int bits, bool return_fast_path) {
97
- Node* cmp;
98
- if (mask != 0 ) {
99
- Node* and_node = transform_later (new AndXNode (word, MakeConX (mask)));
100
- cmp = transform_later (new CmpXNode (and_node, MakeConX (bits)));
101
- } else {
102
- cmp = word;
103
- }
96
+ Node* PhaseMacroExpand::opt_bits_test (Node* ctrl, Node* region, int edge, Node* word) {
97
+ Node* cmp = word;
104
98
Node* bol = transform_later (new BoolNode (cmp, BoolTest::ne));
105
99
IfNode* iff = new IfNode ( ctrl, bol, PROB_MIN, COUNT_UNKNOWN );
106
100
transform_later (iff);
@@ -111,13 +105,8 @@ Node* PhaseMacroExpand::opt_bits_test(Node* ctrl, Node* region, int edge, Node*
111
105
// Fast path not-taken, i.e. slow path
112
106
Node *slow_taken = transform_later (new IfTrueNode (iff));
113
107
114
- if (return_fast_path) {
115
- region->init_req (edge, slow_taken); // Capture slow-control
116
- return fast_taken;
117
- } else {
118
108
region->init_req (edge, fast_taken); // Capture fast-control
119
109
return slow_taken;
120
- }
121
110
}
122
111
123
112
// --------------------copy_predefined_input_for_runtime_call--------------------
@@ -2220,7 +2209,7 @@ void PhaseMacroExpand::expand_lock_node(LockNode *lock) {
2220
2209
mem_phi = new PhiNode ( region, Type::MEMORY, TypeRawPtr::BOTTOM);
2221
2210
2222
2211
// Optimize test; set region slot 2
2223
- slow_path = opt_bits_test (ctrl, region, 2 , flock, 0 , 0 );
2212
+ slow_path = opt_bits_test (ctrl, region, 2 , flock);
2224
2213
mem_phi->init_req (2 , mem);
2225
2214
2226
2215
// Make slow path call
@@ -2281,7 +2270,7 @@ void PhaseMacroExpand::expand_unlock_node(UnlockNode *unlock) {
2281
2270
FastUnlockNode *funlock = new FastUnlockNode ( ctrl, obj, box );
2282
2271
funlock = transform_later ( funlock )->as_FastUnlock ();
2283
2272
// Optimize test; set region slot 2
2284
- Node *slow_path = opt_bits_test (ctrl, region, 2 , funlock, 0 , 0 );
2273
+ Node *slow_path = opt_bits_test (ctrl, region, 2 , funlock);
2285
2274
Node *thread = transform_later (new ThreadLocalNode ());
2286
2275
2287
2276
CallNode *call = make_slow_call ((CallNode *) unlock, OptoRuntime::complete_monitor_exit_Type (),
0 commit comments