@@ -108,8 +108,10 @@ const Type* ConvD2INode::Value(PhaseGVN* phase) const {
108108// ------------------------------Ideal------------------------------------------
109109// If converting to an int type, skip any rounding nodes
110110Node *ConvD2INode::Ideal (PhaseGVN *phase, bool can_reshape) {
111- if ( in (1 )->Opcode () == Op_RoundDouble )
112- set_req (1 ,in (1 )->in (1 ));
111+ if (in (1 )->Opcode () == Op_RoundDouble) {
112+ set_req (1 , in (1 )->in (1 ));
113+ return this ;
114+ }
113115 return NULL ;
114116}
115117
@@ -142,8 +144,10 @@ Node* ConvD2LNode::Identity(PhaseGVN* phase) {
142144// ------------------------------Ideal------------------------------------------
143145// If converting to an int type, skip any rounding nodes
144146Node *ConvD2LNode::Ideal (PhaseGVN *phase, bool can_reshape) {
145- if ( in (1 )->Opcode () == Op_RoundDouble )
146- set_req (1 ,in (1 )->in (1 ));
147+ if (in (1 )->Opcode () == Op_RoundDouble) {
148+ set_req (1 , in (1 )->in (1 ));
149+ return this ;
150+ }
147151 return NULL ;
148152}
149153
@@ -179,8 +183,10 @@ Node* ConvF2INode::Identity(PhaseGVN* phase) {
179183// ------------------------------Ideal------------------------------------------
180184// If converting to an int type, skip any rounding nodes
181185Node *ConvF2INode::Ideal (PhaseGVN *phase, bool can_reshape) {
182- if ( in (1 )->Opcode () == Op_RoundFloat )
183- set_req (1 ,in (1 )->in (1 ));
186+ if (in (1 )->Opcode () == Op_RoundFloat) {
187+ set_req (1 , in (1 )->in (1 ));
188+ return this ;
189+ }
184190 return NULL ;
185191}
186192
@@ -206,8 +212,10 @@ Node* ConvF2LNode::Identity(PhaseGVN* phase) {
206212// ------------------------------Ideal------------------------------------------
207213// If converting to an int type, skip any rounding nodes
208214Node *ConvF2LNode::Ideal (PhaseGVN *phase, bool can_reshape) {
209- if ( in (1 )->Opcode () == Op_RoundFloat )
210- set_req (1 ,in (1 )->in (1 ));
215+ if (in (1 )->Opcode () == Op_RoundFloat) {
216+ set_req (1 , in (1 )->in (1 ));
217+ return this ;
218+ }
211219 return NULL ;
212220}
213221
0 commit comments