Add two useful comments.
This commit is contained in:
parent
cf561904db
commit
09c807ed82
@ -455,6 +455,8 @@ fn run_compiler(
|
|||||||
|
|
||||||
let ongoing_codegen = queries.ongoing_codegen()?;
|
let ongoing_codegen = queries.ongoing_codegen()?;
|
||||||
|
|
||||||
|
// This must run after monomorphization so that all generic types
|
||||||
|
// have been instantiated.
|
||||||
if sess.opts.unstable_opts.print_type_sizes {
|
if sess.opts.unstable_opts.print_type_sizes {
|
||||||
sess.code_stats.print_type_sizes();
|
sess.code_stats.print_type_sizes();
|
||||||
}
|
}
|
||||||
@ -469,6 +471,8 @@ fn run_compiler(
|
|||||||
Ok(Some(linker))
|
Ok(Some(linker))
|
||||||
})?;
|
})?;
|
||||||
|
|
||||||
|
// Linking is done outside the `compiler.enter()` so that the
|
||||||
|
// `GlobalCtxt` within `Queries` can be freed as early as possible.
|
||||||
if let Some(linker) = linker {
|
if let Some(linker) = linker {
|
||||||
let _timer = sess.timer("link");
|
let _timer = sess.timer("link");
|
||||||
linker.link(sess, codegen_backend)?
|
linker.link(sess, codegen_backend)?
|
||||||
|
Loading…
x
Reference in New Issue
Block a user