mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-20 11:04:34 +02:00
8022783: Nashorn test fails with: assert(!def_outside->member(r))
Enables private copies of inputs for recent spill copies as well Reviewed-by: kvn, twisti
This commit is contained in:
parent
0e8081e57b
commit
3838ed7b68
2 changed files with 5 additions and 21 deletions
|
@ -536,12 +536,6 @@ bool InstructForm::rematerialize(FormDict &globals, RegisterForm *registers ) {
|
||||||
if( data_type != Form::none )
|
if( data_type != Form::none )
|
||||||
rematerialize = true;
|
rematerialize = true;
|
||||||
|
|
||||||
// Ugly: until a better fix is implemented, disable rematerialization for
|
|
||||||
// negD nodes because they are proved to be problematic.
|
|
||||||
if (is_ideal_negD()) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Constants
|
// Constants
|
||||||
if( _components.count() == 1 && _components[0]->is(Component::USE_DEF) )
|
if( _components.count() == 1 && _components[0]->is(Component::USE_DEF) )
|
||||||
rematerialize = true;
|
rematerialize = true;
|
||||||
|
|
|
@ -51,15 +51,6 @@
|
||||||
|
|
||||||
static const char out_of_nodes[] = "out of nodes during split";
|
static const char out_of_nodes[] = "out of nodes during split";
|
||||||
|
|
||||||
static bool contains_no_live_range_input(const Node* def) {
|
|
||||||
for (uint i = 1; i < def->req(); ++i) {
|
|
||||||
if (def->in(i) != NULL && def->in_RegMask(i).is_NotEmpty()) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
//------------------------------get_spillcopy_wide-----------------------------
|
//------------------------------get_spillcopy_wide-----------------------------
|
||||||
// Get a SpillCopy node with wide-enough masks. Use the 'wide-mask', the
|
// Get a SpillCopy node with wide-enough masks. Use the 'wide-mask', the
|
||||||
// wide ideal-register spill-mask if possible. If the 'wide-mask' does
|
// wide ideal-register spill-mask if possible. If the 'wide-mask' does
|
||||||
|
@ -326,12 +317,11 @@ Node *PhaseChaitin::split_Rematerialize( Node *def, Block *b, uint insidx, uint
|
||||||
if( def->req() > 1 ) {
|
if( def->req() > 1 ) {
|
||||||
for( uint i = 1; i < def->req(); i++ ) {
|
for( uint i = 1; i < def->req(); i++ ) {
|
||||||
Node *in = def->in(i);
|
Node *in = def->in(i);
|
||||||
// Check for single-def (LRG cannot redefined)
|
|
||||||
uint lidx = _lrg_map.live_range_id(in);
|
uint lidx = _lrg_map.live_range_id(in);
|
||||||
if (lidx >= _lrg_map.max_lrg_id()) {
|
// We do not need this for live ranges that are only defined once.
|
||||||
continue; // Value is a recent spill-copy
|
// However, this is not true for spill copies that are added in this
|
||||||
}
|
// Split() pass, since they might get coalesced later on in this pass.
|
||||||
if (lrgs(lidx).is_singledef()) {
|
if (lidx < _lrg_map.max_lrg_id() && lrgs(lidx).is_singledef()) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1327,7 +1317,7 @@ uint PhaseChaitin::Split(uint maxlrg, ResourceArea* split_arena) {
|
||||||
Node *def = Reaches[pidx][slidx];
|
Node *def = Reaches[pidx][slidx];
|
||||||
assert( def, "must have reaching def" );
|
assert( def, "must have reaching def" );
|
||||||
// If input up/down sense and reg-pressure DISagree
|
// If input up/down sense and reg-pressure DISagree
|
||||||
if (def->rematerialize() && contains_no_live_range_input(def)) {
|
if (def->rematerialize()) {
|
||||||
// Place the rematerialized node above any MSCs created during
|
// Place the rematerialized node above any MSCs created during
|
||||||
// phi node splitting. end_idx points at the insertion point
|
// phi node splitting. end_idx points at the insertion point
|
||||||
// so look at the node before it.
|
// so look at the node before it.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue