< prev index next >

src/hotspot/share/opto/castnode.cpp

Print this page

        

*** 460,469 **** --- 460,486 ---- if (t == Type::TOP) return Type::TOP; if (t->base() == Type::RawPtr && t->singleton()) { uintptr_t bits = (uintptr_t) t->is_rawptr()->get_con(); return TypeX::make(bits); } + + PhaseIterGVN* igvn = phase->is_IterGVN(); + if (igvn != NULL && (t->is_zero_type() || !TypePtr::NULL_PTR->higher_equal(t))) { + for (DUIterator_Fast imax, i = fast_outs(imax); i < imax; i++) { + Node* u = fast_out(i); + if (u->Opcode() == Op_OrL) { + for (DUIterator_Fast jmax, j = u->fast_outs(jmax); j < jmax; j++) { + Node* cmp = u->fast_out(j); + if (cmp->Opcode() == Op_CmpL) { + // Give CmpL a chance to get optimized + igvn->_worklist.push(cmp); + } + } + } + } + } + return CastP2XNode::bottom_type(); } Node *CastP2XNode::Ideal(PhaseGVN *phase, bool can_reshape) { return (in(0) && remove_dead_region(phase, can_reshape)) ? this : NULL;
< prev index next >