equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2001, 2014, 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. |
45 inline HeapRegion* |
45 inline HeapRegion* |
46 G1CollectedHeap::heap_region_containing_raw(const T addr) const { |
46 G1CollectedHeap::heap_region_containing_raw(const T addr) const { |
47 assert(addr != NULL, "invariant"); |
47 assert(addr != NULL, "invariant"); |
48 assert(_g1_reserved.contains((const void*) addr), |
48 assert(_g1_reserved.contains((const void*) addr), |
49 err_msg("Address "PTR_FORMAT" is outside of the heap ranging from ["PTR_FORMAT" to "PTR_FORMAT")", |
49 err_msg("Address "PTR_FORMAT" is outside of the heap ranging from ["PTR_FORMAT" to "PTR_FORMAT")", |
50 (void*)addr, _g1_reserved.start(), _g1_reserved.end())); |
50 p2i((void*)addr), p2i(_g1_reserved.start()), p2i(_g1_reserved.end()))); |
51 return _hrs.addr_to_region((HeapWord*) addr); |
51 return _hrs.addr_to_region((HeapWord*) addr); |
52 } |
52 } |
53 |
53 |
54 template <class T> |
54 template <class T> |
55 inline HeapRegion* |
55 inline HeapRegion* |