Skip to content

Commit

Permalink
Remove -Z incremental-queries.
Browse files Browse the repository at this point in the history
Because it uses `parse_bool` and defaults to true, it is actually
impossible to set it to false. And it hasn't been experimental for some
time now.
  • Loading branch information
nnethercote committed Mar 24, 2020
1 parent 8818eac commit f19ab9a
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 12 deletions.
4 changes: 1 addition & 3 deletions src/librustc/ty/query/plumbing.rs
Expand Up @@ -615,9 +615,7 @@ impl<'tcx> TyCtxt<'tcx> {
debug_assert!(self.dep_graph.is_green(dep_node));

// First we try to load the result from the on-disk cache.
let result = if Q::cache_on_disk(self, key.clone(), None)
&& self.sess.opts.debugging_opts.incremental_queries
{
let result = if Q::cache_on_disk(self, key.clone(), None) {
let prof_timer = self.prof.incr_cache_loading();
let result = Q::try_load_from_disk(self, prev_dep_node_index);
prof_timer.finish_with_query_invocation_id(dep_node_index.into());
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_incremental/persist/load.rs
Expand Up @@ -195,7 +195,7 @@ pub fn load_dep_graph(sess: &Session) -> DepGraphFuture {
}

pub fn load_query_result_cache(sess: &Session) -> OnDiskCache<'_> {
if sess.opts.incremental.is_none() || !sess.opts.debugging_opts.incremental_queries {
if sess.opts.incremental.is_none() {
return OnDiskCache::new_empty(sess.source_map());
}

Expand Down
8 changes: 3 additions & 5 deletions src/librustc_incremental/persist/save.rs
Expand Up @@ -31,11 +31,9 @@ pub fn save_dep_graph(tcx: TyCtxt<'_>) {

join(
move || {
if tcx.sess.opts.debugging_opts.incremental_queries {
sess.time("incr_comp_persist_result_cache", || {
save_in(sess, query_cache_path, |e| encode_query_cache(tcx, e));
});
}
sess.time("incr_comp_persist_result_cache", || {
save_in(sess, query_cache_path, |e| encode_query_cache(tcx, e));
});
},
|| {
sess.time("incr_comp_persist_dep_graph", || {
Expand Down
2 changes: 0 additions & 2 deletions src/librustc_session/options.rs
Expand Up @@ -791,8 +791,6 @@ options! {DebuggingOptions, DebuggingSetter, basic_debugging_options,
"print tasks that execute and the color their dep node gets (requires debug build)"),
incremental: Option<String> = (None, parse_opt_string, [UNTRACKED],
"enable incremental compilation (experimental)"),
incremental_queries: bool = (true, parse_bool, [UNTRACKED],
"enable incremental compilation support for queries (experimental)"),
incremental_info: bool = (false, parse_bool, [UNTRACKED],
"print high-level information about incremental reuse (or the lack thereof)"),
incremental_dump_hash: bool = (false, parse_bool, [UNTRACKED],
Expand Down
1 change: 0 additions & 1 deletion src/tools/compiletest/src/runtest.rs
Expand Up @@ -1852,7 +1852,6 @@ impl<'test> TestCx<'test> {
if let Some(ref incremental_dir) = self.props.incremental_dir {
rustc.args(&["-C", &format!("incremental={}", incremental_dir.display())]);
rustc.args(&["-Z", "incremental-verify-ich"]);
rustc.args(&["-Z", "incremental-queries"]);
}

if self.config.mode == CodegenUnits {
Expand Down

0 comments on commit f19ab9a

Please sign in to comment.