changeset 22750:a1e5249702a3

Don't try to save full vector registers in emitSaveRegisters.
author Roland Schatz <roland.schatz@oracle.com>
date Fri, 02 Oct 2015 15:23:31 +0200
parents dfb01e333fc5
children a39f84c77092
files graal/com.oracle.graal.hotspot.amd64/src/com/oracle/graal/hotspot/amd64/AMD64HotSpotLIRGenerator.java
diffstat 1 files changed, 12 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.hotspot.amd64/src/com/oracle/graal/hotspot/amd64/AMD64HotSpotLIRGenerator.java	Thu Oct 01 14:32:39 2015 -0700
+++ b/graal/com.oracle.graal.hotspot.amd64/src/com/oracle/graal/hotspot/amd64/AMD64HotSpotLIRGenerator.java	Fri Oct 02 15:23:31 2015 +0200
@@ -338,6 +338,18 @@
     }
 
     /**
+     * Allocate a stack slot for saving a register.
+     */
+    protected StackSlotValue allocateSaveRegisterLocation(Register register) {
+        PlatformKind kind = target().arch.getLargestStorableKind(register.getRegisterCategory());
+        if (kind.getVectorLength() > 1) {
+            // we don't use vector registers, so there is no need to save them
+            kind = AMD64Kind.DOUBLE;
+        }
+        return getResult().getFrameMapBuilder().allocateSpillSlot(LIRKind.value(kind));
+    }
+
+    /**
      * Adds a node to the graph that saves all allocatable registers to the stack.
      *
      * @param supportsRemove determines if registers can be pruned