Skip to content

Commit

Permalink
Remove profiler output and replace with a raw event dump
Browse files Browse the repository at this point in the history
Related to #58372
  • Loading branch information
wesleywiser committed Mar 3, 2019
1 parent 25b8c61 commit fccc841
Show file tree
Hide file tree
Showing 4 changed files with 271 additions and 329 deletions.
4 changes: 1 addition & 3 deletions src/librustc/session/config.rs
Expand Up @@ -1405,9 +1405,7 @@ options! {DebuggingOptions, DebuggingSetter, basic_debugging_options,
crate_attr: Vec<String> = (Vec::new(), parse_string_push, [TRACKED],
"inject the given attribute in the crate"),
self_profile: bool = (false, parse_bool, [UNTRACKED],
"run the self profiler"),
profile_json: bool = (false, parse_bool, [UNTRACKED],
"output a json file with profiler results"),
"run the self profiler and output the raw event data"),
emit_stack_sizes: bool = (false, parse_bool, [UNTRACKED],
"emits a section containing stack size metadata"),
plt: Option<bool> = (None, parse_opt_bool, [TRACKED],
Expand Down
5 changes: 1 addition & 4 deletions src/librustc/session/mod.rs
Expand Up @@ -1131,11 +1131,8 @@ pub fn build_session_(
source_map: Lrc<source_map::SourceMap>,
driver_lint_caps: FxHashMap<lint::LintId, lint::Level>,
) -> Session {
let self_profiling_active = sopts.debugging_opts.self_profile ||
sopts.debugging_opts.profile_json;

let self_profiler =
if self_profiling_active { Some(Arc::new(PlMutex::new(SelfProfiler::new()))) }
if sopts.debugging_opts.self_profile { Some(Arc::new(PlMutex::new(SelfProfiler::new()))) }
else { None };

let host_triple = TargetTriple::from_triple(config::host_triple());
Expand Down

0 comments on commit fccc841

Please sign in to comment.