diff options
| -rw-r--r-- | cmdline/cmdline_parser_test.cc | 2 | ||||
| -rw-r--r-- | runtime/runtime.cc | 15 | ||||
| -rw-r--r-- | runtime/runtime_options.def | 2 | ||||
| -rwxr-xr-x | test/etc/run-test-jar | 8 |
4 files changed, 4 insertions, 23 deletions
diff --git a/cmdline/cmdline_parser_test.cc b/cmdline/cmdline_parser_test.cc index 3cb9731a17..1e79fdff1b 100644 --- a/cmdline/cmdline_parser_test.cc +++ b/cmdline/cmdline_parser_test.cc @@ -369,7 +369,7 @@ TEST_F(CmdlineParserTest, DISABLED_TestXGcOption) { */ TEST_F(CmdlineParserTest, TestJdwpProviderEmpty) { { - EXPECT_SINGLE_PARSE_DEFAULT_VALUE(JdwpProvider::kNone, "", M::JdwpProvider); + EXPECT_SINGLE_PARSE_DEFAULT_VALUE(JdwpProvider::kInternal, "", M::JdwpProvider); } } // TEST_F diff --git a/runtime/runtime.cc b/runtime/runtime.cc index b1286daf4a..77f1fb9718 100644 --- a/runtime/runtime.cc +++ b/runtime/runtime.cc @@ -1253,20 +1253,7 @@ bool Runtime::Init(RuntimeArgumentMap&& runtime_options_in) { jdwp_provider_ = runtime_options.GetOrDefault(Opt::JdwpProvider); switch (jdwp_provider_) { case JdwpProvider::kNone: { - LOG(INFO) << "Disabling all JDWP support."; - if (!jdwp_options_.empty()) { - bool has_transport = jdwp_options_.find("transport") != std::string::npos; - const char* transport_internal = !has_transport ? "transport=dt_android_adb," : ""; - std::string adb_connection_args = - std::string(" -XjdwpProvider:adbconnection -XjdwpOptions:") + jdwp_options_; - LOG(WARNING) << "Jdwp options given when jdwp is disabled! You probably want to enable " - << "jdwp with one of:" << std::endl - << " -XjdwpProvider:internal " - << "-XjdwpOptions:" << transport_internal << jdwp_options_ << std::endl - << " -Xplugin:libopenjdkjvmti" << (kIsDebugBuild ? "d" : "") << ".so " - << "-agentpath:libjdwp.so=" << jdwp_options_ << std::endl - << (has_transport ? "" : adb_connection_args); - } + LOG(WARNING) << "Disabling all JDWP support."; break; } case JdwpProvider::kInternal: { diff --git a/runtime/runtime_options.def b/runtime/runtime_options.def index e78d952c1c..6e1a68b07d 100644 --- a/runtime/runtime_options.def +++ b/runtime/runtime_options.def @@ -44,7 +44,7 @@ RUNTIME_OPTIONS_KEY (std::string, Image) RUNTIME_OPTIONS_KEY (Unit, CheckJni) RUNTIME_OPTIONS_KEY (Unit, JniOptsForceCopy) RUNTIME_OPTIONS_KEY (std::string, JdwpOptions, "") -RUNTIME_OPTIONS_KEY (JdwpProvider, JdwpProvider, JdwpProvider::kNone) +RUNTIME_OPTIONS_KEY (JdwpProvider, JdwpProvider, JdwpProvider::kInternal) RUNTIME_OPTIONS_KEY (MemoryKiB, MemoryMaximumSize, gc::Heap::kDefaultMaximumSize) // -Xmx RUNTIME_OPTIONS_KEY (MemoryKiB, MemoryInitialSize, gc::Heap::kDefaultInitialSize) // -Xms RUNTIME_OPTIONS_KEY (MemoryKiB, HeapGrowthLimit) // Default is 0 for unlimited diff --git a/test/etc/run-test-jar b/test/etc/run-test-jar index ca24471675..5e40b86aa0 100755 --- a/test/etc/run-test-jar +++ b/test/etc/run-test-jar @@ -436,13 +436,7 @@ if [ "$DEBUGGER" = "y" ]; then msg " adb forward tcp:$PORT tcp:$PORT" fi msg " jdb -attach localhost:$PORT" - if [ "$USE_JVM" = "n" ]; then - # TODO We should switch over to using the jvmti agent by default. - # Need to tell the runtime to enable the internal jdwp implementation. - DEBUGGER_OPTS="-XjdwpOptions:transport=dt_socket,address=$PORT,server=y,suspend=y -XjdwpProvider:internal" - else - DEBUGGER_OPTS="-agentlib:jdwp=transport=dt_socket,address=$PORT,server=y,suspend=y" - fi + DEBUGGER_OPTS="-agentlib:jdwp=transport=dt_socket,address=$PORT,server=y,suspend=y" elif [ "$DEBUGGER" = "agent" ]; then PORT=12345 # TODO Support ddms connection and support target. |