Merge "Keep annotated classes in main dex list"
diff --git a/dx/src/com/android/dx/command/dexer/Main.java b/dx/src/com/android/dx/command/dexer/Main.java
index 6ce23ab..563a93c 100644
--- a/dx/src/com/android/dx/command/dexer/Main.java
+++ b/dx/src/com/android/dx/command/dexer/Main.java
@@ -57,6 +57,7 @@
 import java.io.PrintWriter;
 import java.util.ArrayList;
 import java.util.Arrays;
+import java.util.Collection;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.List;
@@ -326,7 +327,8 @@
         assert args.numThreads == 1;
 
         if (args.mainDexListFile != null) {
-            classesInMainDex = readPathsFromFile(args.mainDexListFile);
+            classesInMainDex = new HashSet<String>();
+            readPathsFromFile(args.mainDexListFile, classesInMainDex);
         }
 
         if (!processAllFiles()) {
@@ -380,8 +382,7 @@
         }
     }
 
-    private static Set<String> readPathsFromFile(String fileName) throws IOException {
-        Set<String> paths = new HashSet<String>();
+    private static void readPathsFromFile(String fileName, Collection<String> paths) throws IOException {
         BufferedReader bfr = null;
         try {
             FileReader fr = new FileReader(fileName);
@@ -398,7 +399,6 @@
                 bfr.close();
             }
         }
-        return paths;
     }
 
     /**
@@ -1293,7 +1293,7 @@
         public boolean minimalMainDex = false;
 
         /** Optional list containing inputs read in from a file. */
-        private Set<String> inputList = null;
+        private List<String> inputList = null;
 
         private int maxNumberOfIdxPerDex = DexFormat.MAX_MEMBER_IDX + 1;
 
@@ -1501,7 +1501,8 @@
                 } else if(parser.isArg(INPUT_LIST_OPTION + "=")) {
                     File inputListFile = new File(parser.getLastValue());
                     try{
-                        inputList = readPathsFromFile(inputListFile.getAbsolutePath());
+                        inputList = new ArrayList<String>();
+                        readPathsFromFile(inputListFile.getAbsolutePath(), inputList);
                     } catch(IOException e) {
                         System.err.println(
                             "Unable to read input list file: " + inputListFile.getName());
diff --git a/libdex/Android.mk b/libdex/Android.mk
index 0b805dd..15e7ba7 100644
--- a/libdex/Android.mk
+++ b/libdex/Android.mk
@@ -49,6 +49,7 @@
 #LOCAL_CFLAGS += -UNDEBUG -DDEBUG=1
 LOCAL_SRC_FILES := $(dex_src_files)
 LOCAL_C_INCLUDES += $(dex_include_files)
+LOCAL_CPPFLAGS := -std=gnu++11
 LOCAL_STATIC_LIBRARIES := liblog
 LOCAL_WHOLE_STATIC_LIBRARIES := libziparchive
 LOCAL_SHARED_LIBRARIES := libutils
@@ -69,6 +70,7 @@
 include $(CLEAR_VARS)
 LOCAL_SRC_FILES := $(dex_src_files)
 LOCAL_C_INCLUDES += $(dex_include_files)
+LOCAL_CPPFLAGS := -std=gnu++11
 LOCAL_STATIC_LIBRARIES := liblog libutils
 LOCAL_WHOLE_STATIC_LIBRARIES := libziparchive-host
 LOCAL_MODULE_TAGS := optional
diff --git a/libdex/DexFile.h b/libdex/DexFile.h
index 7104005..e8ab319 100644
--- a/libdex/DexFile.h
+++ b/libdex/DexFile.h
@@ -33,7 +33,44 @@
 #ifndef LIBDEX_DEXFILE_H_
 #define LIBDEX_DEXFILE_H_
 
-#include "vm/Common.h"      // basic type defs, e.g. u1/u2/u4/u8, and LOG
+#ifndef LOG_TAG
+# define LOG_TAG "libdex"
+#endif
+
+#include <stdbool.h>
+#include <stdint.h>
+#include <stdio.h>
+#include <assert.h>
+#include "cutils/log.h"
+
+/*
+ * If "very verbose" logging is enabled, make it equivalent to ALOGV.
+ * Otherwise, make it disappear.
+ *
+ * Define this above the #include "Dalvik.h" to enable for only a
+ * single file.
+ */
+/* #define VERY_VERBOSE_LOG */
+#if defined(VERY_VERBOSE_LOG)
+# define LOGVV      ALOGV
+# define IF_LOGVV() IF_ALOGV()
+#else
+# define LOGVV(...) ((void)0)
+# define IF_LOGVV() if (false)
+#endif
+
+/*
+ * These match the definitions in the VM specification.
+ */
+typedef uint8_t             u1;
+typedef uint16_t            u2;
+typedef uint32_t            u4;
+typedef uint64_t            u8;
+typedef int8_t              s1;
+typedef int16_t             s2;
+typedef int32_t             s4;
+typedef int64_t             s8;
+
 #include "libdex/SysUtil.h"
 
 /*
diff --git a/libdex/DexSwapVerify.cpp b/libdex/DexSwapVerify.cpp
index ff47ab5..7f18831 100644
--- a/libdex/DexSwapVerify.cpp
+++ b/libdex/DexSwapVerify.cpp
@@ -31,35 +31,9 @@
 #include <stdlib.h>
 #include <string.h>
 
-#ifndef __BYTE_ORDER
-# error "byte ordering not defined"
-#endif
-
-#if __BYTE_ORDER == __LITTLE_ENDIAN
-# define SWAP2(_value)      (_value)
-# define SWAP4(_value)      (_value)
-# define SWAP8(_value)      (_value)
-#else
-# define SWAP2(_value)      endianSwapU2((_value))
-# define SWAP4(_value)      endianSwapU4((_value))
-# define SWAP8(_value)      endianSwapU8((_value))
-static u2 endianSwapU2(u2 value) {
-    return (value >> 8) | (value << 8);
-}
-static u4 endianSwapU4(u4 value) {
-    /* ABCD --> CDAB --> DCBA */
-    value = (value >> 16) | (value << 16);
-    return ((value & 0xff00ff00) >> 8) | ((value << 8) & 0xff00ff00);
-}
-static u8 endianSwapU8(u8 value) {
-    /* ABCDEFGH --> EFGHABCD --> GHEFCDAB --> HGFEDCBA */
-    value = (value >> 32) | (value << 32);
-    value = ((value & 0xffff0000ffff0000ULL) >> 16) |
-            ((value << 16) & 0xffff0000ffff0000ULL);
-    return ((value & 0xff00ff00ff00ff00ULL) >> 8) |
-           ((value << 8) & 0xff00ff00ff00ff00ULL);
-}
-#endif
+#define SWAP2(_value)      (_value)
+#define SWAP4(_value)      (_value)
+#define SWAP8(_value)      (_value)
 
 #define SWAP_FIELD2(_field) (_field) = SWAP2(_field)
 #define SWAP_FIELD4(_field) (_field) = SWAP4(_field)
diff --git a/libdex/OptInvocation.cpp b/libdex/OptInvocation.cpp
index 031ec91..be7f70b 100644
--- a/libdex/OptInvocation.cpp
+++ b/libdex/OptInvocation.cpp
@@ -18,8 +18,6 @@
  * Utility functions for dealing with optimized dex files.
  */
 
-#include "vm/DalvikVersion.h"
-
 #include <stdint.h>
 #include <stdlib.h>
 #include <unistd.h>
diff --git a/libdex/sha1.cpp b/libdex/sha1.cpp
index 15a81cc..60c4d93 100644
--- a/libdex/sha1.cpp
+++ b/libdex/sha1.cpp
@@ -93,12 +93,9 @@
 # include <unistd.h>
 # include <stdlib.h>
 //# include <endian.h>
-
-#include "DexFile.h"    // want common byte ordering def
-
-# if __BYTE_ORDER == __LITTLE_ENDIAN
+//# if __BYTE_ORDER == __LITTLE_ENDIAN
 #  define X_LITTLE_ENDIAN
-# endif
+//# endif
 #endif
 #include <ctype.h>
 
diff --git a/tools/dmtracedump/Android.mk b/tools/dmtracedump/Android.mk
index 5d3146e..933f4e5 100644
--- a/tools/dmtracedump/Android.mk
+++ b/tools/dmtracedump/Android.mk
@@ -10,7 +10,6 @@
 include $(CLEAR_VARS)
 LOCAL_SRC_FILES := TraceDump.c
 LOCAL_CFLAGS += -O0 -g
-LOCAL_C_INCLUDES += dalvik/vm
 LOCAL_MODULE_TAGS := optional
 LOCAL_MODULE := dmtracedump
 include $(BUILD_HOST_EXECUTABLE)
@@ -18,7 +17,6 @@
 include $(CLEAR_VARS)
 LOCAL_SRC_FILES := CreateTestTrace.c
 LOCAL_CFLAGS += -O0 -g
-LOCAL_C_INCLUDES += dalvik/vm
 LOCAL_MODULE_TAGS := optional
 LOCAL_MODULE := create_test_dmtrace
 include $(BUILD_HOST_EXECUTABLE)
diff --git a/tools/dmtracedump/Profile.h b/tools/dmtracedump/Profile.h
new file mode 100644
index 0000000..efbedb3
--- /dev/null
+++ b/tools/dmtracedump/Profile.h
@@ -0,0 +1,43 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/*
+ * Android's method call profiling goodies.
+ */
+#ifndef DALVIK_PROFILE_H_
+#define DALVIK_PROFILE_H_
+
+/*
+ * Enumeration for the two "action" bits.
+ */
+enum {
+    METHOD_TRACE_ENTER = 0x00,      // method entry
+    METHOD_TRACE_EXIT = 0x01,       // method exit
+    METHOD_TRACE_UNROLL = 0x02,     // method exited by exception unrolling
+    // 0x03 currently unused
+};
+
+#define TOKEN_CHAR      '*'
+
+/*
+ * Common definitions, shared with the dump tool.
+ */
+#define METHOD_ACTION_MASK      0x03            /* two bits */
+#define METHOD_ID(_method)      ((_method) & (~METHOD_ACTION_MASK))
+#define METHOD_ACTION(_method)  (((unsigned int)(_method)) & METHOD_ACTION_MASK)
+#define METHOD_COMBINE(_method, _action)    ((_method) | (_action))
+
+#endif  // DALVIK_PROFILE_H_
diff --git a/vm/Common.h b/vm/Common.h
deleted file mode 100644
index af31b97..0000000
--- a/vm/Common.h
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*
- * Common defines for all Dalvik code.
- */
-#ifndef DALVIK_COMMON_H_
-#define DALVIK_COMMON_H_
-
-#ifndef LOG_TAG
-# define LOG_TAG "dalvikvm"
-#endif
-
-#include <stdbool.h>
-#include <stdint.h>
-#include <stdio.h>
-#include <assert.h>
-#include "cutils/log.h"
-
-#if defined(HAVE_ENDIAN_H)
-# include <endian.h>
-#else /*not HAVE_ENDIAN_H*/
-# define __BIG_ENDIAN 4321
-# define __LITTLE_ENDIAN 1234
-# if defined(HAVE_LITTLE_ENDIAN)
-#  define __BYTE_ORDER __LITTLE_ENDIAN
-# else
-#  define __BYTE_ORDER __BIG_ENDIAN
-# endif
-#endif /*not HAVE_ENDIAN_H*/
-
-#if !defined(NDEBUG) && defined(WITH_DALVIK_ASSERT)
-# undef assert
-# define assert(x) \
-    ((x) ? ((void)0) : (ALOGE("ASSERT FAILED (%s:%d): %s", \
-        __FILE__, __LINE__, #x), *(int*)39=39, (void)0) )
-#endif
-
-#define MIN(x,y) (((x) < (y)) ? (x) : (y))
-#define MAX(x,y) (((x) > (y)) ? (x) : (y))
-
-#define LIKELY(exp) (__builtin_expect((exp) != 0, true))
-#define UNLIKELY(exp) (__builtin_expect((exp) != 0, false))
-
-#define ALIGN_UP(x, n) (((size_t)(x) + (n) - 1) & ~((n) - 1))
-#define ALIGN_DOWN(x, n) ((size_t)(x) & -(n))
-#define ALIGN_UP_TO_PAGE_SIZE(p) ALIGN_UP(p, SYSTEM_PAGE_SIZE)
-#define ALIGN_DOWN_TO_PAGE_SIZE(p) ALIGN_DOWN(p, SYSTEM_PAGE_SIZE)
-
-#define CLZ(x) __builtin_clz(x)
-
-/*
- * If "very verbose" logging is enabled, make it equivalent to ALOGV.
- * Otherwise, make it disappear.
- *
- * Define this above the #include "Dalvik.h" to enable for only a
- * single file.
- */
-/* #define VERY_VERBOSE_LOG */
-#if defined(VERY_VERBOSE_LOG)
-# define LOGVV      ALOGV
-# define IF_LOGVV() IF_ALOGV()
-#else
-# define LOGVV(...) ((void)0)
-# define IF_LOGVV() if (false)
-#endif
-
-
-/*
- * These match the definitions in the VM specification.
- */
-typedef uint8_t             u1;
-typedef uint16_t            u2;
-typedef uint32_t            u4;
-typedef uint64_t            u8;
-typedef int8_t              s1;
-typedef int16_t             s2;
-typedef int32_t             s4;
-typedef int64_t             s8;
-
-/*
- * Storage for primitive types and object references.
- *
- * Some parts of the code (notably object field access) assume that values
- * are "left aligned", i.e. given "JValue jv", "jv.i" and "*((s4*)&jv)"
- * yield the same result.  This seems to be guaranteed by gcc on big- and
- * little-endian systems.
- */
-struct Object;
-
-union JValue {
-#if defined(HAVE_LITTLE_ENDIAN)
-    u1      z;
-    s1      b;
-    u2      c;
-    s2      s;
-    s4      i;
-    s8      j;
-    float   f;
-    double  d;
-    Object* l;
-#endif
-#if defined(HAVE_BIG_ENDIAN)
-    struct {
-        u1    _z[3];
-        u1    z;
-    };
-    struct {
-        s1    _b[3];
-        s1    b;
-    };
-    struct {
-        u2    _c;
-        u2    c;
-    };
-    struct {
-        s2    _s;
-        s2    s;
-    };
-    s4      i;
-    s8      j;
-    float   f;
-    double  d;
-    void*   l;
-#endif
-};
-
-#define OFFSETOF_MEMBER(t, f)         \
-  (reinterpret_cast<char*>(           \
-     &reinterpret_cast<t*>(16)->f) -  \
-   reinterpret_cast<char*>(16))
-
-#define NELEM(x) ((int) (sizeof(x) / sizeof((x)[0])))
-
-#endif  // DALVIK_COMMON_H_
diff --git a/vm/DalvikVersion.h b/vm/DalvikVersion.h
deleted file mode 100644
index e71c839..0000000
--- a/vm/DalvikVersion.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*
- * Dalvik VM version info.
- */
-#ifndef DALVIK_VERSION_H_
-#define DALVIK_VERSION_H_
-
-/*
- * The version we show to tourists.
- */
-#define DALVIK_MAJOR_VERSION    1
-#define DALVIK_MINOR_VERSION    6
-#define DALVIK_BUG_VERSION      0
-
-/*
- * VM build number.  This must change whenever something that affects the
- * way classes load changes, e.g. field ordering or vtable layout.  Changing
- * this guarantees that the optimized form of the DEX file is regenerated.
- */
-#define DALVIK_VM_BUILD         27
-
-#endif  // DALVIK_VERSION_H_
diff --git a/vm/Profile.h b/vm/Profile.h
deleted file mode 100644
index 9059181..0000000
--- a/vm/Profile.h
+++ /dev/null
@@ -1,206 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*
- * Android's method call profiling goodies.
- */
-#ifndef DALVIK_PROFILE_H_
-#define DALVIK_PROFILE_H_
-
-#ifndef NOT_VM      /* for utilities that sneakily include this file */
-
-#include <stdio.h>
-
-struct Thread;      // extern
-
-
-/* boot init */
-bool dvmProfilingStartup(void);
-void dvmProfilingShutdown(void);
-
-/*
- * Method trace state.  This is currently global.  In theory we could make
- * most of this per-thread.
- */
-struct MethodTraceState {
-    /* active state */
-    pthread_mutex_t startStopLock;
-    pthread_cond_t  threadExitCond;
-    FILE*   traceFile;
-    bool    directToDdms;
-    int     bufferSize;
-    int     flags;
-
-    int     traceEnabled;
-    u1*     buf;
-    volatile int curOffset;
-    u8      startWhen;
-    int     overflow;
-
-    int     traceVersion;
-    size_t  recordSize;
-
-    bool    samplingEnabled;
-    pthread_t       samplingThreadHandle;
-};
-
-/*
- * Memory allocation profiler state.  This is used both globally and
- * per-thread.
- *
- * If you add a field here, zero it out in dvmStartAllocCounting().
- */
-struct AllocProfState {
-    bool    enabled;            // is allocation tracking enabled?
-
-    int     allocCount;         // #of objects allocated
-    int     allocSize;          // cumulative size of objects
-
-    int     failedAllocCount;   // #of times an allocation failed
-    int     failedAllocSize;    // cumulative size of failed allocations
-
-    int     freeCount;          // #of objects freed
-    int     freeSize;           // cumulative size of freed objects
-
-    int     gcCount;            // #of times an allocation triggered a GC
-
-    int     classInitCount;     // #of initialized classes
-    u8      classInitTime;      // cumulative time spent in class init (nsec)
-};
-
-
-/*
- * Start/stop method tracing.
- */
-void dvmMethodTraceStart(const char* traceFileName, int traceFd, int bufferSize,
-        int flags, bool directToDdms, bool samplingEnabled, int intervalUs);
-void dvmMethodTraceStop(void);
-
-/*
- * Returns current method tracing mode.
- */
-enum TracingMode {
-    TRACING_INACTIVE,
-    METHOD_TRACING_ACTIVE,
-    SAMPLE_PROFILING_ACTIVE,
-};
-TracingMode dvmGetMethodTracingMode(void);
-
-/*
- * Start/stop emulator tracing.
- */
-void dvmEmulatorTraceStart(void);
-void dvmEmulatorTraceStop(void);
-
-/*
- * Start/stop Dalvik instruction counting.
- */
-void dvmStartInstructionCounting();
-void dvmStopInstructionCounting();
-
-/*
- * Bit flags for dvmMethodTraceStart "flags" argument.  These must match
- * the values in android.os.Debug.
- */
-enum {
-    TRACE_ALLOC_COUNTS      = 0x01,
-};
-
-/*
- * Call these when a method enters or exits.
- */
-#define TRACE_METHOD_ENTER(_self, _method)                                  \
-    do {                                                                    \
-        if (_self->interpBreak.ctl.subMode & kSubModeMethodTrace) {         \
-            u4 cpuClockDiff = 0;                                            \
-            u4 wallClockDiff = 0;                                           \
-            dvmMethodTraceReadClocks(_self, &cpuClockDiff, &wallClockDiff); \
-            dvmMethodTraceAdd(_self, _method, METHOD_TRACE_ENTER,           \
-                              cpuClockDiff, wallClockDiff);                 \
-        }                                                                   \
-        if (_self->interpBreak.ctl.subMode & kSubModeEmulatorTrace)         \
-            dvmEmitEmulatorTrace(_method, METHOD_TRACE_ENTER);              \
-    } while(0);
-#define TRACE_METHOD_EXIT(_self, _method)                                   \
-    do {                                                                    \
-        if (_self->interpBreak.ctl.subMode & kSubModeMethodTrace) {         \
-            u4 cpuClockDiff = 0;                                            \
-            u4 wallClockDiff = 0;                                           \
-            dvmMethodTraceReadClocks(_self, &cpuClockDiff, &wallClockDiff); \
-            dvmMethodTraceAdd(_self, _method, METHOD_TRACE_EXIT,            \
-                              cpuClockDiff, wallClockDiff);                 \
-        }                                                                   \
-        if (_self->interpBreak.ctl.subMode & kSubModeEmulatorTrace)         \
-            dvmEmitEmulatorTrace(_method, METHOD_TRACE_EXIT);               \
-    } while(0);
-#define TRACE_METHOD_UNROLL(_self, _method)                                 \
-    do {                                                                    \
-        if (_self->interpBreak.ctl.subMode & kSubModeMethodTrace) {         \
-            u4 cpuClockDiff = 0;                                            \
-            u4 wallClockDiff = 0;                                           \
-            dvmMethodTraceReadClocks(_self, &cpuClockDiff, &wallClockDiff); \
-            dvmMethodTraceAdd(_self, _method, METHOD_TRACE_UNROLL,          \
-                              cpuClockDiff, wallClockDiff);                 \
-        }                                                                   \
-        if (_self->interpBreak.ctl.subMode & kSubModeEmulatorTrace)         \
-            dvmEmitEmulatorTrace(_method, METHOD_TRACE_UNROLL);             \
-    } while(0);
-
-void dvmMethodTraceReadClocks(Thread* self, u4* cpuClockDiff,
-                              u4* wallClockDiff);
-void dvmMethodTraceAdd(struct Thread* self, const Method* method, int action,
-                       u4 cpuClockDiff, u4 wallClockDiff);
-void dvmEmitEmulatorTrace(const Method* method, int action);
-
-void dvmMethodTraceGCBegin(void);
-void dvmMethodTraceGCEnd(void);
-void dvmMethodTraceClassPrepBegin(void);
-void dvmMethodTraceClassPrepEnd(void);
-
-extern "C" void dvmFastMethodTraceEnter(const Method* method, struct Thread* self);
-extern "C" void dvmFastMethodTraceExit(struct Thread* self);
-extern "C" void dvmFastNativeMethodTraceExit(const Method* method, struct Thread* self);
-
-/*
- * Start/stop alloc counting.
- */
-void dvmStartAllocCounting(void);
-void dvmStopAllocCounting(void);
-
-#endif
-
-
-/*
- * Enumeration for the two "action" bits.
- */
-enum {
-    METHOD_TRACE_ENTER = 0x00,      // method entry
-    METHOD_TRACE_EXIT = 0x01,       // method exit
-    METHOD_TRACE_UNROLL = 0x02,     // method exited by exception unrolling
-    // 0x03 currently unused
-};
-
-#define TOKEN_CHAR      '*'
-
-/*
- * Common definitions, shared with the dump tool.
- */
-#define METHOD_ACTION_MASK      0x03            /* two bits */
-#define METHOD_ID(_method)      ((_method) & (~METHOD_ACTION_MASK))
-#define METHOD_ACTION(_method)  (((unsigned int)(_method)) & METHOD_ACTION_MASK)
-#define METHOD_COMBINE(_method, _action)    ((_method) | (_action))
-
-#endif  // DALVIK_PROFILE_H_