test/compiler/codecache/CheckUpperLimit.java

Thu, 01 Aug 2013 16:01:32 -0700

author
anoll
date
Thu, 01 Aug 2013 16:01:32 -0700
changeset 5487
446cb5d25d03
parent 5382
7ac80525ece9
child 6876
710a3c8b516e
permissions
-rw-r--r--

8020531: Test compiler/codecache/CheckUpperLimit.java fails when memory limited
Summary: Removed part of the test that required the VM to start up with -XX:ReservedCodeCacheSize=2048m
Reviewed-by: kvn, rbackman

anoll@5382 1 /*
anoll@5382 2 * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
anoll@5382 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
anoll@5382 4 *
anoll@5382 5 * This code is free software; you can redistribute it and/or modify it
anoll@5382 6 * under the terms of the GNU General Public License version 2 only, as
anoll@5382 7 * published by the Free Software Foundation.
anoll@5382 8 *
anoll@5382 9 * This code is distributed in the hope that it will be useful, but WITHOUT
anoll@5382 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
anoll@5382 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
anoll@5382 12 * version 2 for more details (a copy is included in the LICENSE file that
anoll@5382 13 * accompanied this code).
anoll@5382 14 *
anoll@5382 15 * You should have received a copy of the GNU General Public License version
anoll@5382 16 * 2 along with this work; if not, write to the Free Software Foundation,
anoll@5382 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
anoll@5382 18 *
anoll@5382 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
anoll@5382 20 * or visit www.oracle.com if you need additional information or have any
anoll@5382 21 * questions.
anoll@5382 22 */
anoll@5382 23
anoll@5382 24 /*
anoll@5382 25 * @test
anoll@5382 26 * @bug 8015635
anoll@5382 27 * @summary Test ensures that the ReservedCodeCacheSize is at most MAXINT
anoll@5382 28 * @library /testlibrary
anoll@5382 29 *
anoll@5382 30 */
anoll@5382 31 import com.oracle.java.testlibrary.*;
anoll@5382 32
anoll@5382 33 public class CheckUpperLimit {
anoll@5382 34 public static void main(String[] args) throws Exception {
anoll@5382 35 ProcessBuilder pb;
anoll@5382 36 OutputAnalyzer out;
anoll@5382 37
anoll@5382 38 pb = ProcessTools.createJavaProcessBuilder("-XX:ReservedCodeCacheSize=2049m", "-version");
anoll@5382 39 out = new OutputAnalyzer(pb.start());
anoll@5382 40 out.shouldContain("Invalid ReservedCodeCacheSize=");
anoll@5382 41 out.shouldHaveExitValue(1);
anoll@5382 42 }
anoll@5382 43 }

mercurial