JDK-6877254 : Server vm crashes with "no branches off of store slice" when run with CMS and UseSuperWord (default)
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: hs16
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: solaris
  • CPU: generic
  • Submitted: 2009-08-29
  • Updated: 2011-03-08
  • Resolved: 2011-03-08
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7 Other
6u21Fixed 7Fixed hs17Fixed
Related Reports
Relates :  
Relates :  
Description
Fastdebug server jvm (both 32bit and 64bit) run with -XX:+UseConcMarkSweepGC crashes with:

#  Internal Error (/export0/BUILD_AREA/jdk6_18/hotspot/src/share/vm/opto/superword.cpp:465), pid=5023, tid=26
#  Error: assert(out == prev || prev == 0,"no branches off of store slice")
#

The failure is reproduced on:
- solaris-i586, solaris-amd64
- solaris-sparc, solaris-sparcv9

No failure in case UseSuperWord is disabled (note, UseSuperWord is enabled by default).

The following testcase could be used to reproduce the failure:

======= Tester.java =======

public class Tester {
    static byte var_1;
    static String var_2 = "";
    static byte var_3;
    static float var_4 = 0;

    public static void main(String[] args)
    {   
        int i = 0;

        for (String var_tmp = var_2; i < 11; var_1 = 0, i++)
        {   
            var_2 = var_2;
            var_4 *= (var_4 *= (var_3 = 0));
        }

        System.out.println("var_1 = " + var_1);
        System.out.println("var_2 = " + var_2);
        System.out.println("var_3 = " + var_3);
        System.out.println("var_4 = " + var_4);
    }
}

Comments
EVALUATION http://hg.openjdk.java.net/jdk7/hotspot-comp/hotspot/rev/685e959d09ea
14-09-2009

EVALUATION Bug 6636138 actually reported two problems: one is the memory edge problem, another one is the same problem as this one, i.e. the storeP node is optimized away, leaving a storeCM with a mergemem node as its storeOop. In the fix of 6636138, I just have a point fix to the storeOop problem (thus incomplete): + } else if( out->is_MergeMem() && prev && + prev->Opcode() == Op_StoreCM && out == prev->in(MemNode::OopStore)) { + // Oop store is a MergeMem! This should not happen. Temporarily remove the assertion + // for this case because it could not be superwordized anyway. } else { assert(out == prev || prev == NULL, "no branches off of store slice"); } I have opened bug 6816756 to remove useless pre/post barriers which could also solve this problem.
31-08-2009

WORK AROUND run with -XX:-UseSuperWord
29-08-2009