mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-30 23:31:12 +00:00
morphic stuff can happen in the LLVM backend alone
This commit is contained in:
parent
ab8abb8f11
commit
07e16469e4
2 changed files with 26 additions and 29 deletions
|
@ -706,7 +706,6 @@ pub struct MonomorphizedModule<'a> {
|
|||
pub type_problems: MutMap<ModuleId, Vec<solve::TypeError>>,
|
||||
pub mono_problems: MutMap<ModuleId, Vec<roc_mono::ir::MonoProblem>>,
|
||||
pub procedures: MutMap<(Symbol, TopLevelFunctionLayout<'a>), Proc<'a>>,
|
||||
pub alias_analysis_solutions: AliasAnalysisSolutions,
|
||||
pub exposed_to_host: MutMap<Symbol, Variable>,
|
||||
pub header_sources: MutMap<ModuleId, (PathBuf, Box<str>)>,
|
||||
pub sources: MutMap<ModuleId, (PathBuf, Box<str>)>,
|
||||
|
@ -864,19 +863,6 @@ struct State<'a> {
|
|||
pub layout_caches: std::vec::Vec<LayoutCache<'a>>,
|
||||
|
||||
pub procs: Procs<'a>,
|
||||
|
||||
pub alias_analysis_solutions: AliasAnalysisSolutions,
|
||||
}
|
||||
|
||||
pub enum AliasAnalysisSolutions {
|
||||
NotAvailable,
|
||||
Available(morphic_lib::Solutions),
|
||||
}
|
||||
|
||||
impl std::fmt::Debug for AliasAnalysisSolutions {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
write!(f, "AliasAnalysisSolutions {{}}")
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
|
@ -1486,7 +1472,6 @@ where
|
|||
specializations_in_flight: 0,
|
||||
layout_caches: std::vec::Vec::with_capacity(num_cpus::get()),
|
||||
procs: Procs::new_in(arena),
|
||||
alias_analysis_solutions: AliasAnalysisSolutions::NotAvailable,
|
||||
};
|
||||
|
||||
// We've now distributed one worker queue to each thread.
|
||||
|
@ -2085,18 +2070,6 @@ fn update<'a>(
|
|||
&mut state.procedures,
|
||||
);
|
||||
|
||||
if false {
|
||||
let it = state.procedures.iter().map(|x| x.1);
|
||||
|
||||
match roc_mono::alias_analysis::spec_program(it) {
|
||||
Err(e) => panic!("Error in alias analysis: {:?}", e),
|
||||
Ok(solutions) => {
|
||||
state.alias_analysis_solutions =
|
||||
AliasAnalysisSolutions::Available(solutions)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
state.constrained_ident_ids.insert(module_id, ident_ids);
|
||||
|
||||
for (module_id, requested) in external_specializations_requested {
|
||||
|
@ -2176,7 +2149,6 @@ fn finish_specialization(
|
|||
|
||||
let State {
|
||||
procedures,
|
||||
alias_analysis_solutions,
|
||||
module_cache,
|
||||
output_path,
|
||||
platform_path,
|
||||
|
@ -2238,7 +2210,6 @@ fn finish_specialization(
|
|||
subs,
|
||||
interns,
|
||||
procedures,
|
||||
alias_analysis_solutions,
|
||||
sources,
|
||||
header_sources,
|
||||
timings: state.timings,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue