New blog post! Debugging a rustc segfault using some very cool illumos debugging tools.
Really excited about this one, it is a bit long but there was so much to cover, from how the stack and the heap works to virtual address permissions :D
Notably, the crash is while compiling a crate called cranelift-codegen, which suggests automatic code generation.
it’s funny you say this, because it’s a very reasonable assumption, but actually this is one of rustc’s codegen backends, as an alternative to llvm. the whole cranelift backend is actually optional, one easy hack would’ve been just to disable it in your config.toml
@jyn @rain cranelift-codegen and specifically the bits that seem like they were causing issues *are* code-generated code (they're part of isle, cranelift's instruction selection dsl). so cranelift-codegen does have parts that are code generated, even though "codegen" in the crate name refers to generating actual machine code