提交 e67f6784 编写于 作者: K kvn

6259129: (Escape Analysis) scalar replacement for not escaping objects

Summary: Use scalar replacement with EA to remove allocations for objects which do not escape the compiled method.
Reviewed-by: rasbold, never, jrose
上级 7cc53f2c
此差异已折叠。
......@@ -78,6 +78,15 @@ private:
Node* length,
const TypeFunc* slow_call_type,
address slow_call_address);
Node *value_from_mem(Node *mem, BasicType ft, const Type *ftype, const TypeOopPtr *adr_t, Node *alloc);
Node *value_from_mem_phi(Node *mem, BasicType ft, const Type *ftype, const TypeOopPtr *adr_t, Node *alloc, int level);
bool eliminate_allocate_node(AllocateNode *alloc);
bool can_eliminate_allocation(AllocateNode *alloc, GrowableArray <SafePointNode *>& safepoints);
bool scalar_replacement(AllocateNode *alloc, GrowableArray <SafePointNode *>& safepoints_done);
void process_users_of_allocation(AllocateNode *alloc);
void eliminate_card_mark(Node *cm);
bool eliminate_locking_node(AbstractLockNode *alock);
void expand_lock_node(LockNode *lock);
void expand_unlock_node(UnlockNode *unlock);
......
......@@ -439,6 +439,13 @@ public:
void add_users_to_worklist0( Node *n );
void add_users_to_worklist ( Node *n );
// Replace old node with new one.
void replace_node( Node *old, Node *nn ) {
add_users_to_worklist(old);
hash_delete(old);
subsume_node(old, nn);
}
#ifndef PRODUCT
protected:
// Sub-quadratic implementation of VerifyIterativeGVN.
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册