comparison src/cpu/sparc/vm/stubGenerator_sparc.cpp @ 6725:da91efe96a93

6964458: Reimplement class meta-data storage to use native memory Summary: Remove PermGen, allocate meta-data in metaspace linked to class loaders, rewrite GC walking, rewrite and rename metadata to be C++ classes Reviewed-by: jmasa, stefank, never, coleenp, kvn, brutisso, mgerdin, dholmes, jrose, twisti, roland Contributed-by: jmasa <jon.masamitsu@oracle.com>, stefank <stefan.karlsson@oracle.com>, mgerdin <mikael.gerdin@oracle.com>, never <tom.rodriguez@oracle.com>
author coleenp
date Sat, 01 Sep 2012 13:25:18 -0400
parents 1d7922586cf6
children d8ce2825b193
comparison
equal deleted inserted replaced
6724:36d1d483d5d6 6725:da91efe96a93
1 /* 1 /*
2 * Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
26 #include "asm/assembler.hpp" 26 #include "asm/assembler.hpp"
27 #include "assembler_sparc.inline.hpp" 27 #include "assembler_sparc.inline.hpp"
28 #include "interpreter/interpreter.hpp" 28 #include "interpreter/interpreter.hpp"
29 #include "nativeInst_sparc.hpp" 29 #include "nativeInst_sparc.hpp"
30 #include "oops/instanceOop.hpp" 30 #include "oops/instanceOop.hpp"
31 #include "oops/methodOop.hpp" 31 #include "oops/method.hpp"
32 #include "oops/objArrayKlass.hpp" 32 #include "oops/objArrayKlass.hpp"
33 #include "oops/oop.inline.hpp" 33 #include "oops/oop.inline.hpp"
34 #include "prims/methodHandles.hpp" 34 #include "prims/methodHandles.hpp"
35 #include "runtime/frame.inline.hpp" 35 #include "runtime/frame.inline.hpp"
36 #include "runtime/handles.inline.hpp" 36 #include "runtime/handles.inline.hpp"
3014 __ delayed()->tst(length); 3014 __ delayed()->tst(length);
3015 __ br(Assembler::negative, false, Assembler::pn, L_failed); 3015 __ br(Assembler::negative, false, Assembler::pn, L_failed);
3016 3016
3017 BLOCK_COMMENT("arraycopy argument klass checks"); 3017 BLOCK_COMMENT("arraycopy argument klass checks");
3018 // get src->klass() 3018 // get src->klass()
3019 if (UseCompressedOops) { 3019 if (UseCompressedKlassPointers) {
3020 __ delayed()->nop(); // ??? not good 3020 __ delayed()->nop(); // ??? not good
3021 __ load_klass(src, G3_src_klass); 3021 __ load_klass(src, G3_src_klass);
3022 } else { 3022 } else {
3023 __ delayed()->ld_ptr(src, oopDesc::klass_offset_in_bytes(), G3_src_klass); 3023 __ delayed()->ld_ptr(src, oopDesc::klass_offset_in_bytes(), G3_src_klass);
3024 } 3024 }
3049 int lh_offset = in_bytes(Klass::layout_helper_offset()); 3049 int lh_offset = in_bytes(Klass::layout_helper_offset());
3050 3050
3051 // Load 32-bits signed value. Use br() instruction with it to check icc. 3051 // Load 32-bits signed value. Use br() instruction with it to check icc.
3052 __ lduw(G3_src_klass, lh_offset, G5_lh); 3052 __ lduw(G3_src_klass, lh_offset, G5_lh);
3053 3053
3054 if (UseCompressedOops) { 3054 if (UseCompressedKlassPointers) {
3055 __ load_klass(dst, G4_dst_klass); 3055 __ load_klass(dst, G4_dst_klass);
3056 } 3056 }
3057 // Handle objArrays completely differently... 3057 // Handle objArrays completely differently...
3058 juint objArray_lh = Klass::array_layout_helper(T_OBJECT); 3058 juint objArray_lh = Klass::array_layout_helper(T_OBJECT);
3059 __ set(objArray_lh, O5_temp); 3059 __ set(objArray_lh, O5_temp);
3060 __ cmp(G5_lh, O5_temp); 3060 __ cmp(G5_lh, O5_temp);
3061 __ br(Assembler::equal, false, Assembler::pt, L_objArray); 3061 __ br(Assembler::equal, false, Assembler::pt, L_objArray);
3062 if (UseCompressedOops) { 3062 if (UseCompressedKlassPointers) {
3063 __ delayed()->nop(); 3063 __ delayed()->nop();
3064 } else { 3064 } else {
3065 __ delayed()->ld_ptr(dst, oopDesc::klass_offset_in_bytes(), G4_dst_klass); 3065 __ delayed()->ld_ptr(dst, oopDesc::klass_offset_in_bytes(), G4_dst_klass);
3066 } 3066 }
3067 3067