equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2007, 2014, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2007, 2015, 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. |
193 // In either case, each scanned reference must be scanned precisely |
193 // In either case, each scanned reference must be scanned precisely |
194 // once so as to avoid cloning of a young referent. For efficiency, |
194 // once so as to avoid cloning of a young referent. For efficiency, |
195 // our closures depend on this property and do not protect against |
195 // our closures depend on this property and do not protect against |
196 // double scans. |
196 // double scans. |
197 |
197 |
198 uintptr_t cur_chunk_index = addr_to_chunk_index(chunk_mr.start()); |
198 uintptr_t start_chunk_index = addr_to_chunk_index(chunk_mr.start()); |
199 cur_chunk_index = cur_chunk_index - lowest_non_clean_base_chunk_index; |
199 assert(start_chunk_index >= lowest_non_clean_base_chunk_index, "Bounds error."); |
|
200 uintptr_t cur_chunk_index = start_chunk_index - lowest_non_clean_base_chunk_index; |
200 |
201 |
201 NOISY(tty->print_cr("===========================================================================");) |
202 NOISY(tty->print_cr("===========================================================================");) |
202 NOISY(tty->print_cr(" process_chunk_boundary: Called with [" PTR_FORMAT "," PTR_FORMAT ")", |
203 NOISY(tty->print_cr(" process_chunk_boundary: Called with [" PTR_FORMAT "," PTR_FORMAT ")", |
203 chunk_mr.start(), chunk_mr.end());) |
204 chunk_mr.start(), chunk_mr.end());) |
204 |
205 |
240 } |
241 } |
241 } |
242 } |
242 if (first_dirty_card != NULL) { |
243 if (first_dirty_card != NULL) { |
243 NOISY(tty->print_cr(" LNC: Found a dirty card at " PTR_FORMAT " in current chunk", |
244 NOISY(tty->print_cr(" LNC: Found a dirty card at " PTR_FORMAT " in current chunk", |
244 first_dirty_card);) |
245 first_dirty_card);) |
245 assert(0 <= cur_chunk_index && cur_chunk_index < lowest_non_clean_chunk_size, |
246 assert(cur_chunk_index < lowest_non_clean_chunk_size, "Bounds error."); |
246 "Bounds error."); |
|
247 assert(lowest_non_clean[cur_chunk_index] == NULL, |
247 assert(lowest_non_clean[cur_chunk_index] == NULL, |
248 "Write exactly once : value should be stable hereafter for this round"); |
248 "Write exactly once : value should be stable hereafter for this round"); |
249 lowest_non_clean[cur_chunk_index] = first_dirty_card; |
249 lowest_non_clean[cur_chunk_index] = first_dirty_card; |
250 } NOISY(else { |
250 } NOISY(else { |
251 tty->print_cr(" LNC: Found no dirty card in current chunk; leaving LNC entry NULL"); |
251 tty->print_cr(" LNC: Found no dirty card in current chunk; leaving LNC entry NULL"); |