let (opt_level, _) = to_llvm_opt_settings(optlvl);
let use_softfp = sess.opts.cg.soft_float;
- let ffunction_sections = sess.target.options.function_sections;
+ let ffunction_sections =
+ sess.opts.debugging_opts.function_sections.unwrap_or(sess.target.options.function_sections);
let fdata_sections = ffunction_sections;
let code_model = to_llvm_code_model(sess.code_model());
tracked!(force_overflow_checks, Some(true));
tracked!(force_unstable_if_unmarked, true);
tracked!(fuel, Some(("abc".to_string(), 99)));
+ tracked!(function_sections, Some(false));
tracked!(human_readable_cgu_names, true);
tracked!(inline_in_all_cgus, Some(true));
tracked!(insert_sideeffect, true);
"force all crates to be `rustc_private` unstable (default: no)"),
fuel: Option<(String, u64)> = (None, parse_optimization_fuel, [TRACKED],
"set the optimization fuel quota for a crate"),
+ function_sections: Option<bool> = (None, parse_opt_bool, [TRACKED],
+ "whether each function should go in its own section"),
graphviz_dark_mode: bool = (false, parse_bool, [UNTRACKED],
"use dark-themed colors in graphviz output (default: no)"),
graphviz_font: String = ("Courier, monospace".to_string(), parse_string, [UNTRACKED],