Cross-platform (SIMD) Math Library?

Started by
4 comments, last by gekko 11 years, 4 months ago
In the past I've used XNA Math because my engine only used DirectX, and it got the job done.

Now I'm looking port my engine to other platforms (mainly iOS with OpenGL ES) so I'm trying to find a fast cross-platform Math Library...

Or should I simply use a different library in each platform?
Advertisement
I use glm but as far as I know the SIMD functionality only works on x86.
The linearmath module of Bullet has a NEON implementation in 2.81, (and SSE for x86) maybe that is useful for you?

I have no opinion of its general speed though.
Although the devices both have SIMD operations, the operations are not identical nor are they interchangable. There are operations available on each that are not available on the other. The usage patterns on each are different.

If you need functions optimized for either platform you would be best to use a platform-specific library.

Yep. There is no NEON for x86, there is no SSE for ARM.

SIMD, Single Instruction Multiple Data is just the general idea of a particular sort of parallelism. Implementations differ.

"I AM ZE EMPRAH OPENGL 3.3 THE CORE, I DEMAND FROM THEE ZE SHADERZ AND MATRIXEZ"

My journals: dustArtemis ECS framework and Making a Terrain Generator

You might want to look into DirectX Math, which replaced XNA Math. It has support for ARM NEON for Windows 8, and I have no iOS experience, but there's a chance it uses the same instructions. If not, you might want to consider porting it.

-- gekko

This topic is closed to new replies.

Advertisement