This was previously using the following condition to decide that a block hadn't been visited yet: either dest_offset is non-0 or the block isn't the entry block. Unfortunately, this didn't work when the first block would be non-empty but wouldn't generate code at all. Since the original code would do at least one pass over the entire code, the first pass that determines initial EBB offsets is done separately, without considering branch relaxation. This ensures that all EBBs have been visited and have correct initial offsets, and doesn't require a special check to know whether an EBB has been visited or not.
This crate contains the core Cranelift code generator. It translates code from an intermediate representation into executable machine code.