How to track down a bad llvm optimization pass
David Nadlinger via digitalmars-d-ldc
digitalmars-d-ldc at puremagic.com
Mon Jun 20 03:32:15 PDT 2016
On 19 Jun 2016, at 7:58, Joakim via digitalmars-d-ldc wrote:
> Anyone know if we're breaking some llvm assumptions here?
I'm not aware of any – if that is the case (which is quite likely),
then it's of course a bug in our code gen.
What I'd be inclined to do is to have a manual look at the IR
immediately before GVN and see whether there is anything fishy to spot
there already. I might also use a debugger on GVN to see exactly why it
thinks it can perform a certain replacement – the LLVM pass internals
are usually fairly well documented, although GVN is of course
algorithmically a bit cumbersome to trace.
More information about the digitalmars-d-ldc