# HG changeset patch # User Doug Simon # Date 1347994486 -7200 # Node ID 58d9297b8575f094f0dfeb7e8ba76cccef5eee31 # Parent b74402a7079baff1ed62350d079496aa15956fcf mark word of new object is initialized by value loaded from the hub if biased locking is enabled diff -r b74402a7079b -r 58d9297b8575 graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/snippets/NewObjectSnippets.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/snippets/NewObjectSnippets.java Tue Sep 18 16:59:24 2012 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/snippets/NewObjectSnippets.java Tue Sep 18 20:54:46 2012 +0200 @@ -160,15 +160,10 @@ private static final int MAX_UNROLLED_OBJECT_ZEROING_SIZE = 10 * wordSize(); /** - * Setting this to false causes (as yet inexplicable) crashes on lusearch. - */ - private static final boolean USE_COMPILE_TIME_PROTOTYPE_MARK_WORD = true; - - /** * Formats some allocated memory with an object header zeroes out the rest. */ private static void formatObject(Object hub, int size, Word memory, Word compileTimePrototypeMarkWord, boolean fillContents) { - Word prototypeMarkWord = USE_COMPILE_TIME_PROTOTYPE_MARK_WORD ? compileTimePrototypeMarkWord : loadWordFromObject(hub, prototypeMarkWordOffset()); + Word prototypeMarkWord = useBiasedLocking() ? loadWordFromObject(hub, prototypeMarkWordOffset()) : compileTimePrototypeMarkWord; storeObject(memory, 0, markOffset(), prototypeMarkWord); storeObject(memory, 0, hubOffset(), hub); if (fillContents) {