Mercurial > hg > truffle
comparison src/share/vm/gc_implementation/parNew/parNewGeneration.hpp @ 1665:a93a9eda13f7
6962947: shared TaskQueue statistics
Reviewed-by: tonyp, ysr
author | jcoomes |
---|---|
date | Fri, 16 Jul 2010 21:33:21 -0700 |
parents | c18cbe5936b8 |
children | 94251661de76 |
comparison
equal
deleted
inserted
replaced
1657:1a1ce2076047 | 1665:a93a9eda13f7 |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2001, 2009, Oracle and/or its affiliates. All rights reserved. | 2 * Copyright (c) 2001, 2010, 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. |
31 | 31 |
32 // It would be better if these types could be kept local to the .cpp file, | 32 // It would be better if these types could be kept local to the .cpp file, |
33 // but they must be here to allow ParScanClosure::do_oop_work to be defined | 33 // but they must be here to allow ParScanClosure::do_oop_work to be defined |
34 // in genOopClosures.inline.hpp. | 34 // in genOopClosures.inline.hpp. |
35 | 35 |
36 typedef OopTaskQueue ObjToScanQueue; | 36 typedef Padded<OopTaskQueue> ObjToScanQueue; |
37 typedef OopTaskQueueSet ObjToScanQueueSet; | 37 typedef GenericTaskQueueSet<ObjToScanQueue> ObjToScanQueueSet; |
38 | 38 |
39 // Enable this to get push/pop/steal stats. | 39 // Enable this to get push/pop/steal stats. |
40 const int PAR_STATS_ENABLED = 0; | 40 const int PAR_STATS_ENABLED = 0; |
41 | 41 |
42 class ParKeepAliveClosure: public DefNewGeneration::KeepAliveClosure { | 42 class ParKeepAliveClosure: public DefNewGeneration::KeepAliveClosure { |
302 friend class ParNewRefProcTaskExecutor; | 302 friend class ParNewRefProcTaskExecutor; |
303 friend class ParScanThreadStateSet; | 303 friend class ParScanThreadStateSet; |
304 friend class ParEvacuateFollowersClosure; | 304 friend class ParEvacuateFollowersClosure; |
305 | 305 |
306 private: | 306 private: |
307 // XXX use a global constant instead of 64! | |
308 struct ObjToScanQueuePadded { | |
309 ObjToScanQueue work_queue; | |
310 char pad[64 - sizeof(ObjToScanQueue)]; // prevent false sharing | |
311 }; | |
312 | |
313 // The per-worker-thread work queues | 307 // The per-worker-thread work queues |
314 ObjToScanQueueSet* _task_queues; | 308 ObjToScanQueueSet* _task_queues; |
315 | 309 |
316 // Per-worker-thread local overflow stacks | 310 // Per-worker-thread local overflow stacks |
317 GrowableArray<oop>** _overflow_stacks; | 311 GrowableArray<oop>** _overflow_stacks; |