# HG changeset patch # User Doug Simon # Date 1353657732 -3600 # Node ID b618f7c63d17b7e586c96ee3df5dc449ddc1b750 # Parent 45029b3ac59f8486f7d6c6ac06f5d4a0f6bb0e98 removed AddressMap utility diff -r 45029b3ac59f -r b618f7c63d17 graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotGraalRuntime.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotGraalRuntime.java Thu Nov 22 23:36:04 2012 +0100 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotGraalRuntime.java Fri Nov 23 09:02:12 2012 +0100 @@ -119,9 +119,6 @@ printConfig(config); } - AddressMap.log(config.cardtableStartAddress, "CARDTABLE"); - AddressMap.log(config.cardtableStartAddress, "SAFEPOINT_POLL_PAGE"); - target = createTarget(); assert wordKind == null || wordKind.equals(target.wordKind); wordKind = target.wordKind; diff -r 45029b3ac59f -r b618f7c63d17 graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/bridge/VMToCompilerImpl.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/bridge/VMToCompilerImpl.java Thu Nov 22 23:36:04 2012 +0100 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/bridge/VMToCompilerImpl.java Fri Nov 23 09:02:12 2012 +0100 @@ -528,7 +528,6 @@ // lost the race - return the existing value instead type = (HotSpotResolvedJavaType) unsafe.getObject(javaMirror, offset); } - AddressMap.log(metaspaceKlass, type.toJava().getName()); return type; } diff -r 45029b3ac59f -r b618f7c63d17 graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/AddressMap.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/AddressMap.java Thu Nov 22 23:36:04 2012 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,61 +0,0 @@ -/* - * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ -package com.oracle.graal.hotspot.meta; - -import java.io.*; - -import com.oracle.graal.debug.*; -import com.oracle.graal.graph.*; -import com.oracle.graal.phases.*; - -/** - * Utility for logging an address to symbol mapping to a file. - * This is useful when looking at disassembled code. - * - * @see GraalOptions#PrintAddressMap - */ -public class AddressMap { - - private static PrintStream addressMapStream; - static { - synchronized (AddressMap.class) { - if (GraalOptions.PrintAddressMap) { - File file = new File("addressMap-" + System.currentTimeMillis() + ".log"); - try { - addressMapStream = new PrintStream(new FileOutputStream(file), true); - } catch (FileNotFoundException e) { - throw new GraalInternalError("Could not open " + file.getAbsolutePath()); - } - TTY.println("Logging {address -> symbol} map to %s", file); - } - } - } - - public static void log(long address, String symbol) { - if (addressMapStream != null) { - synchronized (addressMapStream) { - addressMapStream.println("0x" + Long.toHexString(address) + " " + symbol); - } - } - } -} diff -r 45029b3ac59f -r b618f7c63d17 graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/HotSpotResolvedJavaMethod.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/HotSpotResolvedJavaMethod.java Thu Nov 22 23:36:04 2012 +0100 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/HotSpotResolvedJavaMethod.java Fri Nov 23 09:02:12 2012 +0100 @@ -63,7 +63,6 @@ this.metaspaceMethod = metaspaceMethod; this.holder = holder; HotSpotGraalRuntime.getInstance().getCompilerToVM().initializeMethod(metaspaceMethod, this); - AddressMap.log(metaspaceMethod, MetaUtil.format("%H.%n(%P):%R", this)); } @Override @@ -203,7 +202,6 @@ long metaspaceMethodData = unsafe.getLong(null, metaspaceMethod + HotSpotGraalRuntime.getInstance().getConfig().methodDataOffset); if (metaspaceMethodData != 0) { methodData = new HotSpotMethodData(metaspaceMethodData); - AddressMap.log(metaspaceMethodData, MetaUtil.format("MethodData{%H.%n(%P):%R}", this)); } } diff -r 45029b3ac59f -r b618f7c63d17 graal/com.oracle.graal.phases/src/com/oracle/graal/phases/GraalOptions.java --- a/graal/com.oracle.graal.phases/src/com/oracle/graal/phases/GraalOptions.java Thu Nov 22 23:36:04 2012 +0100 +++ b/graal/com.oracle.graal.phases/src/com/oracle/graal/phases/GraalOptions.java Fri Nov 23 09:02:12 2012 +0100 @@ -141,7 +141,6 @@ public static int PrintBinaryGraphPort = 4445; // Other printing settings - public static boolean PrintAddressMap = ____; public static boolean PrintQueue = ____; public static boolean PrintCompilation = ____; public static boolean PrintProfilingInformation = ____;