hotspot/src/share/vm/opto/superword.cpp
changeset 3906 6767b0c66883
parent 3904 007a45522a7f
child 4428 d1617f46285d
--- a/hotspot/src/share/vm/opto/superword.cpp	Mon Sep 14 12:14:20 2009 -0700
+++ b/hotspot/src/share/vm/opto/superword.cpp	Tue Sep 15 11:09:34 2009 -0700
@@ -473,6 +473,12 @@
 // Can s1 and s2 be in a pack with s1 immediately preceding s2 and
 // s1 aligned at "align"
 bool SuperWord::stmts_can_pack(Node* s1, Node* s2, int align) {
+
+  // Do not use superword for non-primitives
+  if((s1->is_Mem() && !is_java_primitive(s1->as_Mem()->memory_type())) ||
+     (s2->is_Mem() && !is_java_primitive(s2->as_Mem()->memory_type())))
+    return false;
+
   if (isomorphic(s1, s2)) {
     if (independent(s1, s2)) {
       if (!exists_at(s1, 0) && !exists_at(s2, 1)) {