1 /*
2 * Copyright (c) 1997, 2005, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
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
7 * published by the Free Software Foundation.
8 *
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 // Forward definition
26 class MethodOopMap;
27 class GenerateOopMap;
28 class BasicBlock;
29 class CellTypeState;
30 class StackMap;
31
32 // These two should be removed. But requires som code to be cleaned up
33 #define MAXARGSIZE 256 // This should be enough
34 #define MAX_LOCAL_VARS 65536 // 16-bit entry
35
36 typedef void (*jmpFct_t)(GenerateOopMap *c, int bcpDelta, int* data);
37
38
39 // RetTable
40 //
41 // Contains maping between jsr targets and there return addresses. One-to-many mapping
42 //
43 class RetTableEntry : public ResourceObj {
44 private:
540 //
541 class GeneratePairingInfo: public GenerateOopMap {
542 private:
543
544 virtual bool report_results() const { return false; }
545 virtual bool report_init_vars() const { return false; }
546 virtual bool allow_rewrites() const { return false; }
547 virtual bool possible_gc_point (BytecodeStream *bcs) { return false; }
548 virtual void fill_stackmap_prolog (int nof_gc_points) {}
549 virtual void fill_stackmap_epilog () {}
550 virtual void fill_stackmap_for_opcodes (BytecodeStream *bcs,
551 CellTypeState* vars,
552 CellTypeState* stack,
553 int stack_top) {}
554 virtual void fill_init_vars (GrowableArray<intptr_t> *init_vars) {}
555 public:
556 GeneratePairingInfo(methodHandle method) : GenerateOopMap(method) {};
557
558 // Call compute_map(CHECK) to generate info.
559 };
|
1 /*
2 * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
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
7 * published by the Free Software Foundation.
8 *
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #ifndef SHARE_VM_OOPS_GENERATEOOPMAP_HPP
26 #define SHARE_VM_OOPS_GENERATEOOPMAP_HPP
27
28 #include "interpreter/bytecodeStream.hpp"
29 #include "memory/allocation.inline.hpp"
30 #include "memory/universe.inline.hpp"
31 #include "oops/methodOop.hpp"
32 #include "oops/oopsHierarchy.hpp"
33 #include "runtime/signature.hpp"
34
35 // Forward definition
36 class MethodOopMap;
37 class GenerateOopMap;
38 class BasicBlock;
39 class CellTypeState;
40 class StackMap;
41
42 // These two should be removed. But requires som code to be cleaned up
43 #define MAXARGSIZE 256 // This should be enough
44 #define MAX_LOCAL_VARS 65536 // 16-bit entry
45
46 typedef void (*jmpFct_t)(GenerateOopMap *c, int bcpDelta, int* data);
47
48
49 // RetTable
50 //
51 // Contains maping between jsr targets and there return addresses. One-to-many mapping
52 //
53 class RetTableEntry : public ResourceObj {
54 private:
550 //
551 class GeneratePairingInfo: public GenerateOopMap {
552 private:
553
554 virtual bool report_results() const { return false; }
555 virtual bool report_init_vars() const { return false; }
556 virtual bool allow_rewrites() const { return false; }
557 virtual bool possible_gc_point (BytecodeStream *bcs) { return false; }
558 virtual void fill_stackmap_prolog (int nof_gc_points) {}
559 virtual void fill_stackmap_epilog () {}
560 virtual void fill_stackmap_for_opcodes (BytecodeStream *bcs,
561 CellTypeState* vars,
562 CellTypeState* stack,
563 int stack_top) {}
564 virtual void fill_init_vars (GrowableArray<intptr_t> *init_vars) {}
565 public:
566 GeneratePairingInfo(methodHandle method) : GenerateOopMap(method) {};
567
568 // Call compute_map(CHECK) to generate info.
569 };
570
571 #endif // SHARE_VM_OOPS_GENERATEOOPMAP_HPP
|