# HG changeset patch # User twisti # Date 1297423073 28800 # Node ID 752682831ac6b3f14f037780090b270d7a0cdcb8 # Parent cc62dbe71e6a0130e665a97af2d757c3b40f5380 7018673: Zero: 6953144, 6990754 and 7009756 made some changes which broke Zero Reviewed-by: kvn, chrisphi, twisti diff -r cc62dbe71e6a -r 752682831ac6 hotspot/src/os_cpu/linux_zero/vm/atomic_linux_zero.inline.hpp --- a/hotspot/src/os_cpu/linux_zero/vm/atomic_linux_zero.inline.hpp Thu Feb 10 19:34:48 2011 -0800 +++ b/hotspot/src/os_cpu/linux_zero/vm/atomic_linux_zero.inline.hpp Fri Feb 11 03:17:53 2011 -0800 @@ -1,6 +1,6 @@ /* - * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright 2007, 2008 Red Hat, Inc. + * Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright 2007, 2008, 2011 Red Hat, Inc. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -300,4 +300,18 @@ (intptr_t) compare_value); } +inline jlong Atomic::load(volatile jlong* src) { + volatile jlong dest; + os::atomic_copy64(src, &dest); + return dest; +} + +inline void Atomic::store(jlong store_value, jlong* dest) { + os::atomic_copy64((volatile jlong*)&store_value, (volatile jlong*)dest); +} + +inline void Atomic::store(jlong store_value, volatile jlong* dest) { + os::atomic_copy64((volatile jlong*)&store_value, dest); +} + #endif // OS_CPU_LINUX_ZERO_VM_ATOMIC_LINUX_ZERO_INLINE_HPP diff -r cc62dbe71e6a -r 752682831ac6 hotspot/src/share/vm/compiler/compileBroker.cpp --- a/hotspot/src/share/vm/compiler/compileBroker.cpp Thu Feb 10 19:34:48 2011 -0800 +++ b/hotspot/src/share/vm/compiler/compileBroker.cpp Fri Feb 11 03:17:53 2011 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -768,7 +768,9 @@ // Initialize the compilation queue void CompileBroker::init_compiler_threads(int c1_compiler_count, int c2_compiler_count) { EXCEPTION_MARK; +#ifndef ZERO assert(c2_compiler_count > 0 || c1_compiler_count > 0, "No compilers?"); +#endif // !ZERO if (c2_compiler_count > 0) { _c2_method_queue = new CompileQueue("C2MethodQueue", MethodCompileQueue_lock); } diff -r cc62dbe71e6a -r 752682831ac6 hotspot/src/share/vm/interpreter/bytecodeInterpreter.cpp --- a/hotspot/src/share/vm/interpreter/bytecodeInterpreter.cpp Thu Feb 10 19:34:48 2011 -0800 +++ b/hotspot/src/share/vm/interpreter/bytecodeInterpreter.cpp Fri Feb 11 03:17:53 2011 -0800 @@ -1936,7 +1936,7 @@ constantPoolOop constants = istate->method()->constants(); if (!constants->tag_at(index).is_unresolved_klass()) { // Make sure klass is initialized and doesn't have a finalizer - oop entry = (klassOop) *constants->obj_at_addr(index); + oop entry = constants->slot_at(index).get_oop(); assert(entry->is_klass(), "Should be resolved klass"); klassOop k_entry = (klassOop) entry; assert(k_entry->klass_part()->oop_is_instance(), "Should be instanceKlass"); @@ -2026,7 +2026,7 @@ if (METHOD->constants()->tag_at(index).is_unresolved_klass()) { CALL_VM(InterpreterRuntime::quicken_io_cc(THREAD), handle_exception); } - klassOop klassOf = (klassOop) *(METHOD->constants()->obj_at_addr(index)); + klassOop klassOf = (klassOop) METHOD->constants()->slot_at(index).get_oop(); klassOop objKlassOop = STACK_OBJECT(-1)->klass(); //ebx // // Check for compatibilty. This check must not GC!! @@ -2061,7 +2061,7 @@ if (METHOD->constants()->tag_at(index).is_unresolved_klass()) { CALL_VM(InterpreterRuntime::quicken_io_cc(THREAD), handle_exception); } - klassOop klassOf = (klassOop) *(METHOD->constants()->obj_at_addr(index)); + klassOop klassOf = (klassOop) METHOD->constants()->slot_at(index).get_oop(); klassOop objKlassOop = STACK_OBJECT(-1)->klass(); // // Check for compatibilty. This check must not GC!! diff -r cc62dbe71e6a -r 752682831ac6 hotspot/src/share/vm/oops/methodOop.cpp --- a/hotspot/src/share/vm/oops/methodOop.cpp Thu Feb 10 19:34:48 2011 -0800 +++ b/hotspot/src/share/vm/oops/methodOop.cpp Fri Feb 11 03:17:53 2011 -0800 @@ -934,7 +934,7 @@ assert(m->signature() == signature, ""); assert(m->is_method_handle_invoke(), ""); #ifdef CC_INTERP - ResultTypeFinder rtf(signature()); + ResultTypeFinder rtf(signature); m->set_result_index(rtf.type()); #endif m->compute_size_of_parameters(THREAD);