summaryrefslogtreecommitdiff
path: root/openjdkjvmti/ti_extension.cc
diff options
context:
space:
mode:
author Alex Light <allight@google.com> 2019-05-17 21:42:33 +0000
committer Alex Light <allight@google.com> 2019-05-17 21:43:40 +0000
commit799e536da9733ab638946f56e1ceb62d62cd3c81 (patch)
tree66a8910e6e8ffd96a83b31513998dc9745209d5b /openjdkjvmti/ti_extension.cc
parentc5265d93c8340b3c419f7f2a7620b5279f274637 (diff)
Revert "Add AddToDexClassloader JVMTI extension functions"
This reverts commit 92ed90ca3897ae7861b22aa12740065152839649. Reason for revert: Test 1963 fails when run by chrome buildbots. Change-Id: Ia3a7dc64f0372da9feca9bca1a75038d3f9fb01e Test: None Bug: 132699522 Bug: 132914283
Diffstat (limited to 'openjdkjvmti/ti_extension.cc')
-rw-r--r--openjdkjvmti/ti_extension.cc49
1 files changed, 0 insertions, 49 deletions
diff --git a/openjdkjvmti/ti_extension.cc b/openjdkjvmti/ti_extension.cc
index 08667c34f8..f12cb0a380 100644
--- a/openjdkjvmti/ti_extension.cc
+++ b/openjdkjvmti/ti_extension.cc
@@ -42,7 +42,6 @@
#include "ti_heap.h"
#include "ti_logging.h"
#include "ti_monitor.h"
-#include "ti_search.h"
#include "thread-inl.h"
@@ -328,54 +327,6 @@ jvmtiError ExtensionUtil::GetExtensionFunctions(jvmtiEnv* env,
return error;
}
- // AddToDexClassLoader
- error = add_extension(
- reinterpret_cast<jvmtiExtensionFunction>(SearchUtil::AddToDexClassLoader),
- "com.android.art.classloader.add_to_dex_class_loader",
- "Adds a dexfile to a given dalvik.system.BaseDexClassLoader in a manner similar to"
- " AddToSystemClassLoader.",
- {
- { "classloader", JVMTI_KIND_IN, JVMTI_TYPE_JOBJECT, false },
- { "segment", JVMTI_KIND_IN_PTR, JVMTI_TYPE_CCHAR, false },
- },
- {
- ERR(NULL_POINTER),
- ERR(CLASS_LOADER_UNSUPPORTED),
- ERR(ILLEGAL_ARGUMENT),
- ERR(WRONG_PHASE),
- });
- if (error != ERR(NONE)) {
- return error;
- }
-
- // AddToDexClassLoaderInMemory requires memfd_create which non-linux doesn't have. The code will
- // still all link but since it will only ever return ERR(INTERNAL) we might as well not even
- // advertise the extension.
- // TODO Support non-linux in some way.
-#ifdef __linux__
- // AddToDexClassLoaderInMemory
- error = add_extension(
- reinterpret_cast<jvmtiExtensionFunction>(SearchUtil::AddToDexClassLoaderInMemory),
- "com.android.art.classloader.add_to_dex_class_loader_in_memory",
- "Adds a dexfile buffer to a given dalvik.system.BaseDexClassLoader in a manner similar to"
- " AddToSystemClassLoader. This may only be done during the LIVE phase. The buffer is copied"
- " and the caller is responsible for deallocating it after this call.",
- {
- { "classloader", JVMTI_KIND_IN, JVMTI_TYPE_JOBJECT, false },
- { "dex_bytes", JVMTI_KIND_IN_BUF, JVMTI_TYPE_CCHAR, false },
- { "dex_bytes_len", JVMTI_KIND_IN, JVMTI_TYPE_JINT, false },
- },
- {
- ERR(NULL_POINTER),
- ERR(CLASS_LOADER_UNSUPPORTED),
- ERR(ILLEGAL_ARGUMENT),
- ERR(WRONG_PHASE),
- });
- if (error != ERR(NONE)) {
- return error;
- }
-#endif
-
// Copy into output buffer.
*extension_count_ptr = ext_vector.size();