For a target that hasn’t implemented branch relaxation (yet), does anyone know what is the preferred way to report an error if a fixup cannot be applied because, for example, the destination of a branch is out of range?
I suppose I could use asserts just like AArch64 is doing but that won’t stop the assembler of emitting a branch to an undesired location in release builds.
Does anyone see any problem in using report_fatal_error to report errors in the target Asm backend ?
Regards,
Matheus
Matheus Almeida
MIPS processor IP
Matheus,
The ARM backend reports these kinds of errors using FatalError method of MCContext. You can see some examples in ARMAsmBackend.cpp (search for "out of range pc-relative fixup value").
-David
_______________________________________________
LLVM Developers mailing list
LLV...@cs.uiuc.edu http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev