Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Core » Unable to Compile ScatterCtrl Example on Debian 12 (ARM64, Clang 18) -- Eigen Package Error
Unable to Compile ScatterCtrl Example on Debian 12 (ARM64, Clang 18) -- Eigen Package Error [message #61827] Mon, 13 October 2025 20:34 Go to next message
nikitha_k is currently offline  nikitha_k
Messages: 6
Registered: July 2023
Location: Banglore
Promising Member
Hello everyone,

I'm currently working on Debian GNU/Linux 12 (Bookworm) with the ARM64 architecture and Clang 18. While most of my projects compile and run successfully, I'm encountering an issue when trying to build the ScatterCtrl example program.

The build process fails with an error related to the Eigen package.

Has anyone faced a similar issue or know how to resolve this problem? Any suggestions or guidance would be greatly appreciated.
Re: Unable to Compile ScatterCtrl Example on Debian 12 (ARM64, Clang 18) -- Eigen Package Error [message #61828 is a reply to message #61827] Tue, 14 October 2025 11:09 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3451
Registered: August 2008
Senior Veteran
Thank you for the report.

plugin/Eigen is just updated to the latest stable version 5.0.0 (09/10/2025).
Please check if this solves the problem. It happens in ARM64 architecture, that I cannot test.


Best regards
Iñaki
Re: Unable to Compile ScatterCtrl Example on Debian 12 (ARM64, Clang 18) -- Eigen Package Error [message #61829 is a reply to message #61828] Wed, 15 October 2025 08:21 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3451
Registered: August 2008
Senior Veteran
Hi Nikitha

The problem seems to be that when building Eigen on ARM platforms with NEON enabled, compilation fails with errors like:
error: unknown type name 'float32x4_t'; did you mean 'Upp::float32x4_t'?
/usr/lib/llvm-18/lib/clang/18/include/arm_vector_types.h: note: 'Upp::float32x4_t' declared here

This happens whenever Eigen includes <arm_neon.h> after U++ headers are already processed.
U++ wraps many system headers inside the Upp namespace -- including <arm_neon.h> and <arm_vector_types.h> -- so NEON vector types like float32x4_t and intrinsics like vdupq_n_f32 are declared as Upp::float32x4_t, not in the global namespace.
However, Eigen expects these NEON types and intrinsics to exist in the global namespace, so it can't find them.
The easy solution would be including Eigen before U++ headers. Unfortunately this breaks the
#define eigen_assert(x) ASSERT(x)
in Eigen.h that links Eigen assertions with U++ ones.

The fix that is being implemented is to re-export NEON types and intrinsics from U++ into the global namespace before including Eigen headers.
This is done doing this in Eigen.h:
#ifdef CPU_NEON
namespace {
    using Upp::float32x2_t;
    using Upp::float32x4_t;
    using Upp::int8x8_t;
...

Thank you for your patience and support.


Best regards
Iñaki
Re: Unable to Compile ScatterCtrl Example on Debian 12 (ARM64, Clang 18) -- Eigen Package Error [message #61830 is a reply to message #61829] Thu, 16 October 2025 09:16 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3451
Registered: August 2008
Senior Veteran
Hi to all

I just wanted to say that the problems with ARM NEON have been resolved.
Nikitha not only detected them, but also helped a lot to solve them.
Thank you very much.


Best regards
Iñaki
Re: Unable to Compile ScatterCtrl Example on Debian 12 (ARM64, Clang 18) -- Eigen Package Error [message #61831 is a reply to message #61827] Thu, 16 October 2025 10:58 Go to previous message
nikitha_k is currently offline  nikitha_k
Messages: 6
Registered: July 2023
Location: Banglore
Promising Member
Thanks Iñaki,

I'm glad to contribute to fix the bug, Also thanks for your support.

Regards,
Nikitha K
Previous Topic: This is heap leak?
Next Topic: Add compilable testcases for nontrivial problems!
Goto Forum:
  


Current Time: Thu Oct 16 13:57:29 CEST 2025

Total time taken to generate the page: 0.06171 seconds