equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2002, 2015, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2002, 2018, 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. |
80 |
80 |
81 // PLAB's never allocate the last aligned_header_size |
81 // PLAB's never allocate the last aligned_header_size |
82 // so they can always fill with an array. |
82 // so they can always fill with an array. |
83 HeapWord* tlab_end = end() + filler_header_size; |
83 HeapWord* tlab_end = end() + filler_header_size; |
84 typeArrayOop filler_oop = (typeArrayOop) top(); |
84 typeArrayOop filler_oop = (typeArrayOop) top(); |
85 filler_oop->set_mark(markOopDesc::prototype()); |
85 filler_oop->set_mark_raw(markOopDesc::prototype()); |
86 filler_oop->set_klass(Universe::intArrayKlassObj()); |
86 filler_oop->set_klass(Universe::intArrayKlassObj()); |
87 const size_t array_length = |
87 const size_t array_length = |
88 pointer_delta(tlab_end, top()) - typeArrayOopDesc::header_size(T_INT); |
88 pointer_delta(tlab_end, top()) - typeArrayOopDesc::header_size(T_INT); |
89 assert( (array_length * (HeapWordSize/sizeof(jint))) < (size_t)max_jint, "array too big in PSPromotionLAB"); |
89 assert( (array_length * (HeapWordSize/sizeof(jint))) < (size_t)max_jint, "array too big in PSPromotionLAB"); |
90 filler_oop->set_length((int)(array_length * (HeapWordSize/sizeof(jint)))); |
90 filler_oop->set_length((int)(array_length * (HeapWordSize/sizeof(jint)))); |