Linkage error on ARM

0 views
Skip to first unread message

bme...@ska.ac.za

unread,
Nov 30, 2015, 9:47:12 AM11/30/15
to Numba Public Discussion - Public
Hi

I know numba isn't official supported on ARM, but I was hoping someone might know of a workaround for the following problem since previous threads have indicated that numba used to at least partially work on TK1. I'm trying to use it on TX1, but as soon as I "import numba" I get this error (and the Python process exits):

LLVM ERROR: Program used external function '__sync_fetch_and_add_4' which could not be resolved!

Using LLVM 1:3.6-2ubuntu1~trusty1, llvmlite 0.8.0 and numba 0.22.1 (the latter two installed from PyPI).

Thanks
Bruce

Stanley Seibert

unread,
Nov 30, 2015, 9:52:08 AM11/30/15
to Numba Public Discussion - Public
This is unknown territory for us, as we've never tested Numba on ARMv8 (64-bit), which is what the TX1 is.  (BTW, very jealous you have a TX1 to play with!)  In the past, we've gotten Numba to unofficially work on ARMv7, although lately there have been mysterious linker errors that I haven't been able to figure out.

This kind of error you are seeing is a sign that LLVM is emitting calls to functions in its special "compiler-rt" library.  The ARMv8 backend appears to be generating a call to a function we have never seen before.

Can you open a Github issue on this? (https://github.com/numba/numba/issues)  I'll see if we can provide you with some guidance on how this could be fixed.  We don't have access to ARMv8 right now, so we can't easily test ourselves.


--
You received this message because you are subscribed to the Google Groups "Numba Public Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to numba-users...@continuum.io.
To post to this group, send email to numba...@continuum.io.
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/numba-users/6dc0285b-f799-4cb9-b39b-605b1f657fdc%40continuum.io.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.

Antoine Pitrou

unread,
Nov 30, 2015, 9:58:16 AM11/30/15
to numba...@continuum.io
I remember getting this error too with LLVM 3.6, and it disappeared
with LLVM 3.6.2. You might want to install llvmlite using conda to give
it a try.

Regards

Antoine.


Stanley Seibert

unread,
Nov 30, 2015, 10:08:22 AM11/30/15
to Numba Public Discussion - Public
I don't think conda is an option.  conda doesn't have support for the ARMv8 architecture right now, and so there are no packages for that platform.

You could build LLVM 3.6.2 from source, though.


--
You received this message because you are subscribed to the Google Groups "Numba Public Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to numba-users...@continuum.io.
To post to this group, send email to numba...@continuum.io.

Brandon Doyle

unread,
Aug 10, 2016, 8:56:32 PM8/10/16
to Numba Public Discussion - Public, bme...@ska.ac.za
I just tried running this on my Raspberry Pi 2 and got the same error with llvm 3.7.


LLVM ERROR: Program used external function '__sync_fetch_and_add_4' which could not be resolved!

Stanley Seibert

unread,
Aug 11, 2016, 12:49:10 PM8/11/16
to Numba Public Discussion - Public, bme...@ska.ac.za
We have a pull request that fixes support for ARMv7 here:

https://github.com/numba/numba/pull/1968

It has not been merged because a few unit tests still fail related to linear algebra and datetime dtypes, as described in the PR, but works fine more most things.

(Note that Numba master requires llmvlite master as well as LLVM 3.8.)

--
You received this message because you are subscribed to the Google Groups "Numba Public Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to numba-users+unsubscribe@continuum.io.

To post to this group, send email to numba...@continuum.io.

hby...@gmail.com

unread,
Oct 19, 2016, 9:06:17 AM10/19/16
to Numba Public Discussion - Public, bme...@ska.ac.za


在 2016年8月12日星期五 UTC+8上午12:49:10,Stanley Seibert写道:
We have a pull request that fixes support for ARMv7 here:

https://github.com/numba/numba/pull/1968

It has not been merged because a few unit tests still fail related to linear algebra and datetime dtypes, as described in the PR, but works fine more most things.

(Note that Numba master requires llmvlite master as well as LLVM 3.8.)
On Wed, Aug 10, 2016 at 7:56 PM, Brandon Doyle <bjd238...@gmail.com> wrote:
I just tried running this on my Raspberry Pi 2 and got the same error with llvm 3.7.

LLVM ERROR: Program used external function '__sync_fetch_and_add_4' which could not be resolved!

On Monday, November 30, 2015 at 9:47:12 AM UTC-5, bme...@ska.ac.za wrote:
Hi

I know numba isn't official supported on ARM, but I was hoping someone might know of a workaround for the following problem since previous threads have indicated that numba used to at least partially work on TK1. I'm trying to use it on TX1, but as soon as I "import numba" I get this error (and the Python process exits):

LLVM ERROR: Program used external function '__sync_fetch_and_add_4' which could not be resolved!

Using LLVM 1:3.6-2ubuntu1~trusty1, llvmlite 0.8.0 and numba 0.22.1 (the latter two installed from PyPI).

Thanks
Bruce

--
You received this message because you are subscribed to the Google Groups "Numba Public Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to numba-users...@continuum.io.

To post to this group, send email to numba...@continuum.io.
Hi Seibert:
Here I'm facing the very same trouble as yours,
I tried install LLVM 3.8 on a Rabspberry Pi 3 and compiled it ,then compiled Numba via PIP3.5  , it's passed , but when excuting the program the error occured, error is sth like this:

LLVM ERROR: Program used external function '__aeabi_unwind_cpp_pr0' which could not be resolved!


Tried with Google but very few posts about this error and currently I got entirely no clue and which direction will got this issue resolved, would you like to share some experience if you already get this trouble fixed, and thank you.
Reply all
Reply to author
Forward
0 new messages