[LLVMdev] Crash on accessing deleted MBBs (new backend)

Evan Cheng evan.cheng at apple.com
Fri Sep 28 23:00:11 PDT 2007


Yeah, that will cause problems. However, I expect an assertion  
somewhere. Any chance you can track down the exact problem?

Thanks.

Evan

On Sep 28, 2007, at 1:37 PM, Andreas Fredriksson  
<deplinenoise at gmail.com> wrote:

> Replying to my self here. It seems I was missing an isTerminator = 1
> on the branch instruction in question, so LLVM didn't know that the
> instruction terminated a basic block. Does that make sense, or is just
> masking some other problem?
>
> Thanks,
> Andreas
>
> On 9/28/07, Andreas Fredriksson <deplinenoise at gmail.com> wrote:
>> Hi,
>> I'm trying to write up my little m68k backend things have been going
>> smoothly. I've been working with the x86 backend as a template,  
>> fixing
>> things as I go.
>>
>> Now I've run into branches and I have a crash I don't really
>> understand. Here's the sample IR I'm running llc on to generate
>> assembly:
>> <snip>
>> llc crashes at this point because the target branch of the BLT  
>> (branch
>> if lower than) has gone away. On my win32 box it's filled with
>> 0xfeeefeee (deleted data).
>>
>> I've verified that the block is actually removed by the branch
>> folding, but for some reason this poor BLT instruction never hears
>> about that. What can I do to fix this?
>>
>> Thanks,
>> Andreas
>>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev



More information about the llvm-dev mailing list