Mercurial > hg > graal-compiler
comparison src/cpu/x86/vm/templateTable_x86_64.cpp @ 2100:b1a2afa37ec4
7003271: Hotspot should track cumulative Java heap bytes allocated on a per-thread basis
Summary: Track allocated bytes in Thread's, update on TLAB retirement and direct allocation in Eden and tenured, add JNI methods for ThreadMXBean.
Reviewed-by: coleenp, kvn, dholmes, ysr
author | phh |
---|---|
date | Fri, 07 Jan 2011 10:42:32 -0500 |
parents | 0fc262af204f |
children | bb8e3b66bde6 |
comparison
equal
deleted
inserted
replaced
2097:039eb4201e06 | 2100:b1a2afa37ec4 |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved. | 2 * Copyright (c) 2003, 2011, 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. |
3264 } | 3264 } |
3265 __ cmpxchgptr(rbx, Address(RtopAddr, 0)); | 3265 __ cmpxchgptr(rbx, Address(RtopAddr, 0)); |
3266 | 3266 |
3267 // if someone beat us on the allocation, try again, otherwise continue | 3267 // if someone beat us on the allocation, try again, otherwise continue |
3268 __ jcc(Assembler::notEqual, retry); | 3268 __ jcc(Assembler::notEqual, retry); |
3269 | |
3270 __ incr_allocated_bytes(r15_thread, rdx, 0); | |
3269 } | 3271 } |
3270 | 3272 |
3271 if (UseTLAB || Universe::heap()->supports_inline_contig_alloc()) { | 3273 if (UseTLAB || Universe::heap()->supports_inline_contig_alloc()) { |
3272 // The object is initialized before the header. If the object size is | 3274 // The object is initialized before the header. If the object size is |
3273 // zero, go directly to the header initialization. | 3275 // zero, go directly to the header initialization. |