relocInfo_ext.hpp revision 12422:98fe046473c9
1258052Snwhitehorn/*
2258052Snwhitehorn * Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
3258052Snwhitehorn * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4258052Snwhitehorn *
5258052Snwhitehorn * This code is free software; you can redistribute it and/or modify it
6258052Snwhitehorn * under the terms of the GNU General Public License version 2 only, as
7258052Snwhitehorn * published by the Free Software Foundation.
8258052Snwhitehorn *
9258052Snwhitehorn * This code is distributed in the hope that it will be useful, but WITHOUT
10258052Snwhitehorn * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11258052Snwhitehorn * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
12258052Snwhitehorn * version 2 for more details (a copy is included in the LICENSE file that
13258052Snwhitehorn * accompanied this code).
14258052Snwhitehorn *
15258052Snwhitehorn * You should have received a copy of the GNU General Public License version
16258052Snwhitehorn * 2 along with this work; if not, write to the Free Software Foundation,
17258052Snwhitehorn * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18258052Snwhitehorn *
19258052Snwhitehorn * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20258052Snwhitehorn * or visit www.oracle.com if you need additional information or have any
21258052Snwhitehorn * questions.
22258052Snwhitehorn *
23258052Snwhitehorn */
24258052Snwhitehorn
25258052Snwhitehorn#ifndef SHARE_VM_CODE_RELOCINFO_EXT_HPP
26258052Snwhitehorn#define SHARE_VM_CODE_RELOCINFO_EXT_HPP
27258052Snwhitehorn
28258052Snwhitehorn// symbolic_Relocation allows to anotate some addresses in the generated code.
29258052Snwhitehorn//
30258052Snwhitehorn// This class was initially defined using the last unused relocType. The
31258052Snwhitehorn// new version tries to limit the impact on open source code changes.
32258052Snwhitehorn//
33258052Snwhitehorn// Without compiled code support, symbolic_Relocation need not be a real
34258052Snwhitehorn// relocation. To avoid using the last unused relocType, the
35258052Snwhitehorn// symbolic_Relocation::spec(<any symbolic type>) has been replaced
36258052Snwhitehorn// by additional methods using directly the symbolic type.
37258052Snwhitehorn//
38258052Snwhitehorn// Note: the order of the arguments in some methods had to reversed
39258052Snwhitehorn// to avoid confusion between the relocType enum and the
40258052Snwhitehorn// symbolic_reference enum.
41258052Snwhitehornclass symbolic_Relocation : AllStatic {
42258052Snwhitehorn
43258052Snwhitehorn public:
44258052Snwhitehorn  enum symbolic_reference {
45258052Snwhitehorn    card_table_reference,
46258052Snwhitehorn    eden_top_reference,
47258052Snwhitehorn    heap_end_reference,
48258052Snwhitehorn    polling_page_reference,
49258052Snwhitehorn    mark_bits_reference,
50258052Snwhitehorn    mark_mask_reference,
51258052Snwhitehorn    oop_bits_reference,
52258052Snwhitehorn    oop_mask_reference,
53258052Snwhitehorn    debug_string_reference,
54258052Snwhitehorn    last_symbolic_reference
55258052Snwhitehorn  };
56258052Snwhitehorn
57258052Snwhitehorn  // get the new value for a given symbolic type
58258052Snwhitehorn  static address symbolic_value(symbolic_reference t);
59258052Snwhitehorn};
60258052Snwhitehorn
61258052Snwhitehorn#endif // SHARE_VM_CODE_RELOCINFO_EXT_HPP
62258052Snwhitehorn