summaryrefslogtreecommitdiff
path: root/runtime/runtime.h
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/runtime.h')
-rw-r--r--runtime/runtime.h17
1 files changed, 8 insertions, 9 deletions
diff --git a/runtime/runtime.h b/runtime/runtime.h
index 261429ec82..be07828f16 100644
--- a/runtime/runtime.h
+++ b/runtime/runtime.h
@@ -34,6 +34,7 @@
#include "instrumentation.h"
#include "jobject_comparator.h"
#include "object_callbacks.h"
+#include "profiler_options.h"
#include "quick/quick_method_frame_info.h"
#include "runtime_stats.h"
#include "safe_map.h"
@@ -114,6 +115,10 @@ class Runtime {
return image_compiler_options_;
}
+ const ProfilerOptions& GetProfilerOptions() const {
+ return profiler_options_;
+ }
+
// Starts a runtime, which may cause threads to be started and code to run.
bool Start() UNLOCK_FUNCTION(Locks::mutator_lock_);
@@ -386,7 +391,7 @@ class Runtime {
const std::vector<const DexFile*>& GetCompileTimeClassPath(jobject class_loader);
void SetCompileTimeClassPath(jobject class_loader, std::vector<const DexFile*>& class_path);
- void StartProfiler(const char* appDir, const char* procName);
+ void StartProfiler(const char* profile_output_filename);
void UpdateProfilerState(int state);
// Transaction support.
@@ -551,15 +556,9 @@ class Runtime {
const bool running_on_valgrind_;
- // Runtime profile support.
- bool profile_;
std::string profile_output_filename_;
- uint32_t profile_period_s_; // Generate profile every n seconds.
- uint32_t profile_duration_s_; // Run profile for n seconds.
- uint32_t profile_interval_us_; // Microseconds between samples.
- double profile_backoff_coefficient_; // Coefficient to exponential backoff.
- bool profile_start_immediately_; // Whether the profile should start upon app
- // startup or be delayed by some random offset.
+ ProfilerOptions profiler_options_;
+ bool profiler_started_;
bool method_trace_;
std::string method_trace_file_;