If you look in X86JITInfo.cpp, you'll find CompilationCallback. I'm not
sure about CompilationCallback2. In any event, the code is conditionally
compiled and that might be tripping things up on Cygwin.
X86CompilationCallback2 is also defined in X86JITInfo.cpp. One is a thin assembler wrapper around the other. No matter how things are conditionally compiled, both functions will be present. Is X86JITInfo.cpp itself being compiled?
I ran into the same kinds of issues when I was working on Cygwin. I had
meant to complete it but the disk died on that machine (probably from
doing nightly builds every night .. it was just a laptop).
Anyway, thanks for your efforts to get Cygwin straightened out. This
will help many people, I suspect.
/usr/src/llvm/lib/Target/X86/X86ISelPattern.cpp:73: undefined reference to `X86CompilationCallback2'
doesn't make sense. X86CompilationCallback2 is not visible outside of X86JITInfo.cpp, and line 73 of X86ISelPattern.cpp is in the middle of a comment block.
When one moves an instruction from one BasicBlock to another, the
instruction continues to believe that its parent is the original BasicBlock.
This is very undesirable. Is there a way to set the parent or a way to move
the instruction such that the parent is updated correctly?
Currently, my way around this was to go into Instruction.h and make
setParent() public. I hope there is a better way?
You shouldn't be modifying the API like this ...
When one moves an instruction from one BasicBlock to another, the
instruction continues to believe that its parent is the original
BasicBlock. This is very undesirable. Is there a way to set the
parent or a way to move the instruction such that the parent is
updated correctly?
See LICM::hoist() in lib/Transforms/Scalar/LICM.cpp for an example.