[llvm-dev] Error compiling libc++ for ARMv6

JF Bastien via llvm-dev llvm-dev at lists.llvm.org
Fri Sep 25 14:17:50 PDT 2015


Looks like this was caused by r248294. Author CC'ed.

On Fri, Sep 25, 2015 at 1:46 PM, Richard Pennington via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> Hi,
>
> I was compiling libc++ with a recent TOT (248571) and when I got to the
> ARMv6, I got a code generation error in memory.cpp:
>
> fatal error: error in backend: Cannot select: intrinsic %llvm.arm.clrex
> ecc: error: clang frontend command failed with exit code 70 (use -v to see
> invocation)
> clang version 3.8.0 (trunk)
>
> It looks as if the newly added emitAtomicCmpXchgNoStoreLLBalance()
> function is the culprit.  Does this seem like a resaonable fix, or do I
> need to do something different for v6 and earlier?
>
> void ARMTargetLowering::emitAtomicCmpXchgNoStoreLLBalance(
>     IRBuilder<> &Builder) const {
>   if (Subtarget->hasV7Ops()) {
>     Module *M = Builder.GetInsertBlock()->getParent()->getParent();
>     Builder.CreateCall(llvm::Intrinsic::getDeclaration(M,
> Intrinsic::arm_clrex));
>   }
> }
>
> -Rich
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150925/e4904a97/attachment.html>


More information about the llvm-dev mailing list