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 * @test CodeCacheTest
26 * @bug 8054889
27 * @build DcmdUtil CodeCacheTest
28 * @run main/othervm -XX:+SegmentedCodeCache CodeCacheTest
29 * @run main/othervm -XX:-SegmentedCodeCache CodeCacheTest
30 * @summary Test of diagnostic command Compiler.codecache
31 */
32
33 import java.io.BufferedReader;
34 import java.io.StringReader;
35 import java.lang.reflect.Method;
36 import java.util.regex.Matcher;
37 import java.util.regex.Pattern;
38
39 public class CodeCacheTest {
40
41 /**
42 * This test calls Jcmd (diagnostic command tool) Compiler.codecache and then parses the output,
43 * making sure that all numbers look ok
44 *
45 *
46 * Expected output without code cache segmentation:
47 *
48 * CodeCache: size=245760Kb used=4680Kb max_used=4680Kb free=241079Kb
|
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 * @test CodeCacheTest
26 * @bug 8054889
27 * @library ..
28 * @build DcmdUtil CodeCacheTest
29 * @run main/othervm -XX:+SegmentedCodeCache CodeCacheTest
30 * @run main/othervm -Xint -XX:+SegmentedCodeCache CodeCacheTest
31 * @run main/othervm -XX:-SegmentedCodeCache CodeCacheTest
32 * @summary Test of diagnostic command Compiler.codecache
33 */
34
35 import java.io.BufferedReader;
36 import java.io.StringReader;
37 import java.lang.reflect.Method;
38 import java.util.regex.Matcher;
39 import java.util.regex.Pattern;
40
41 public class CodeCacheTest {
42
43 /**
44 * This test calls Jcmd (diagnostic command tool) Compiler.codecache and then parses the output,
45 * making sure that all numbers look ok
46 *
47 *
48 * Expected output without code cache segmentation:
49 *
50 * CodeCache: size=245760Kb used=4680Kb max_used=4680Kb free=241079Kb
|