1 /* vm/statistics.h - exports global varables for statistics
3 Copyright (C) 1996-2005 R. Grafl, A. Krall, C. Kruegel, C. Oates,
4 R. Obermaisser, M. Platter, M. Probst, S. Ring, E. Steiner,
5 C. Thalinger, D. Thuernbeck, P. Tomsich, C. Ullrich, J. Wenninger,
6 Institut f. Computersprachen - TU Wien
8 This file is part of CACAO.
10 This program is free software; you can redistribute it and/or
11 modify it under the terms of the GNU General Public License as
12 published by the Free Software Foundation; either version 2, or (at
13 your option) any later version.
15 This program is distributed in the hope that it will be useful, but
16 WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
25 Contact: cacao@complang.tuwien.ac.at
27 Authors: Christian Thalinger
29 $Id: statistics.h 1971 2005-03-01 20:06:36Z carolyn $
38 #include "vm/global.h"
39 /* in_ inline statistics */
42 #define IN_UNIQUEVIRT 0x0000
43 #define IN_UNIQUE_INTERFACE 0x0001
44 #define IN_OUTSIDERS 0x0004
45 #define IN_MAXDEPTH 0x0008
46 #define IN_MAXCODE 0x0010
47 #define IN_JCODELENGTH 0x0020
48 #define IN_EXCEPTION 0x0040
49 #define IN_NOT_UNIQUE_VIRT 0x0080
50 #define IN_NOT_UNIQUE_INTERFACE 0x0100
52 #define N_UNIQUEVIRT 0
53 #define N_UNIQUE_INTERFACE 1
57 #define N_JCODELENGTH 5
59 #define N_NOT_UNIQUE_VIRT 7
60 #define N_NOT_UNIQUE_INTERFACE 8
64 /* global variables ***********************************************************/
66 extern s4 memoryusage;
67 extern s4 maxmemusage;
68 extern s4 maxdumpsize;
70 extern s4 globalallocateddumpsize;
71 extern s4 globaluseddumpsize;
73 extern int count_class_infos; /* variables for measurements */
74 extern int count_const_pool_len;
75 extern int count_vftbl_len;
76 extern int count_all_methods;
77 extern int count_methods_marked_used; /*RTA*/
78 extern int count_vmcode_len;
79 extern int count_extable_len;
80 extern int count_class_loads;
81 extern int count_class_inits;
83 extern int count_utf_len; /* size of utf hash */
84 extern int count_utf_new;
85 extern int count_utf_new_found;
87 extern int count_locals_conflicts;
88 extern int count_locals_spilled;
89 extern int count_locals_register;
90 extern int count_ss_spilled;
91 extern int count_ss_register;
92 extern int count_methods_allocated_by_lsra;
93 extern int count_mem_move_bb;
94 extern int count_interface_size;
95 extern int count_argument_mem_ss;
96 extern int count_argument_reg_ss;
97 extern int count_method_in_register;
99 extern int count_jit_calls;
100 extern int count_methods;
101 extern int count_spills;
102 extern int count_spills_read;
103 extern int count_pcmd_activ;
104 extern int count_pcmd_drop;
105 extern int count_pcmd_zero;
106 extern int count_pcmd_const_store;
107 extern int count_pcmd_const_alu;
108 extern int count_pcmd_const_bra;
109 extern int count_pcmd_load;
110 extern int count_pcmd_move;
111 extern int count_load_instruction;
112 extern int count_pcmd_store;
113 extern int count_pcmd_store_comb;
114 extern int count_dup_instruction;
115 extern int count_pcmd_op;
116 extern int count_pcmd_mem;
117 extern int count_pcmd_met;
118 extern int count_pcmd_bra;
119 extern int count_pcmd_table;
120 extern int count_pcmd_return;
121 extern int count_pcmd_returnx;
122 extern int count_check_null;
123 extern int count_check_bound;
124 extern int count_max_basic_blocks;
125 extern int count_basic_blocks;
126 extern int count_max_javainstr;
127 extern int count_javainstr;
128 extern int count_javacodesize;
129 extern int count_javaexcsize;
130 extern int count_calls;
131 extern int count_tryblocks;
132 extern int count_code_len;
133 extern int count_data_len;
134 extern int count_cstub_len;
135 extern int count_nstub_len;
136 extern int count_max_new_stack;
137 extern int count_upper_bound_new_stack;
138 extern int *count_block_stack;
139 extern int *count_analyse_iterations;
140 extern int *count_method_bb_distribution;
141 extern int *count_block_size_distribution;
142 extern int *count_store_length;
143 extern int *count_store_depth;
144 /* in_ inline statistics */
146 extern int count_in_uniqVirt;
147 extern int count_in_uniqIntf;
148 extern int count_in_rejected;
149 extern int count_in_rejected_mult;
150 extern int count_in_outsiders;
151 extern int count_in_uniqueVirt_not_inlined;
152 extern int count_in_uniqueInterface_not_inlined;
153 extern int count_in_maxDepth;
154 extern int count_in_maxMethods;
156 extern u2 count_in_not [512];
162 /* function prototypes ********************************************************/
166 void loadingtime_start();
167 void loadingtime_stop();
168 void compilingtime_start();
169 void compilingtime_stop();
174 void mem_usagelog(bool givewarnings);
176 #endif /* _STATISTICS_H */
180 * These are local overrides for various environment variables in Emacs.
181 * Please do not remove this and leave it at the end of the file, where
182 * Emacs will automagically detect them.
183 * ---------------------------------------------------------------------
186 * indent-tabs-mode: t