-
Notifications
You must be signed in to change notification settings - Fork 62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compatibility with Linux or OSX ? #1
Comments
I'm not from AMD, but it does not currently build on Linux as-is. It uses some Visual C/C++ specific compiler directives and gets stuck on functions not declared in the current scope. This is due to that the function definitions they sit within |
I've been working on portability in my Unreal Engine 4.24 PR: https://github.com/GPUOpenSoftware/UnrealEngine/pull/14 |
@mastercoms Have you got it working?
I've only briefly looked at it and it would seem that there's a decoherence between So will have to dig deeper and spend a non-trivial amount of time on this. It's a bit unfortunate that there are no tests to guide the porting effort. |
I haven't finished my porting of it (been a bit busy!), but you need to recreate the unions which are included by the MSVC SIMD libraries: typedef union __declspec(align(16)) vec4 {
__m128 v;
float m128_f32[4];
uint64_t m128_u64[2];
int8_t m128_i8[16];
int16_t m128_i16[8];
int32_t m128_i32[4];
int64_t m128_i64[2];
uint8_t m128_u8[16];
uint16_t m128_u16[8];
uint32_t m128_u32[4];
} vec4;
typedef union __declspec(align(16)) vec4i {
__m128i v;
int8_t m128i_i8[16];
int16_t m128i_i16[8];
int32_t m128i_i32[4];
int64_t m128i_i64[2];
uint8_t m128i_u8[16];
uint16_t m128i_u16[8];
uint32_t m128i_u32[4];
uint64_t m128i_u64[2];
} vec4i;
typedef union __declspec(align(16)) vec4d {
__m128d v;
double m128d_f64[2];
} vec4d;
typedef union __declspec(align(32)) vec8 {
__m256 v;
float m256_f32[8];
} vec8;
typedef union __declspec(align(32)) vec8d {
__m256d v;
double m256d_f64[4];
} vec8d;
typedef union __declspec(align(32)) vec8i {
__m256i v;
int8_t m256i_i8[32];
int16_t m256i_i16[16];
int32_t m256i_i32[8];
int64_t m256i_i64[4];
uint8_t m256i_u8[32];
uint16_t m256i_u16[16];
uint32_t m256i_u32[8];
uint64_t m256i_u64[4];
} vec8i; Then it should just be a matter of creating a union, using the SIMD object (like of type m128_i32) and assigned it to the |
I also tried this (blatantly copying stuff from your branch/pr :D and patching declspec-align thing), but the result is the same, so it's either something else, or both of our impls are wrong. |
I haven't implemented everything for portability so it's possible there's still some non-portable code. Did you complete the implementation? |
I completed it in a sense that I got it to build and link successfully without leaving any unimplemented stubs behind or making any significant shortcuts. There are a few warnings remaining. |
Does it work on Linux or OSX and do you have a fork? |
@erwincoumans it crashes early at startup, which makes it hard to say it works :). This is what I got: https://github.com/w23/FEMFX/tree/linux-port |
Any luck making this work on Linux or OSX? With no updates in almost 2 years, has FEMFX been abandoned? |
Hi,
Before digging into the code I wanted to know if there is a known limitation on OSX or Linux, does the code depend on windows specific libraries?
Thanks
The text was updated successfully, but these errors were encountered: