Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
stb_image: NEON and SSE2 SIMD detection fixes.
This fixes two things. First, the logic to disable SSE2 on GCC unless "-msse2" was not specific enough, and ended up disabling SIMD support on NEON targets entirely. Shuffle the detection logic around to make that bit x86-specific. Second, 32-bit MinGW assumes 16-byte aligned stacks, but this is not in the Windows ABI and hence DLLs and callbacks don't necessarily provide it. This caused a crash. This can be fixed by providing the right command-line option, which we have no control over. As a compromise, disable the SSE2 path on MinGW unless a specific #define explained in the comments is set. That way, we default to safe (never-crashing) behavior unless the user explicitly signals they know what they're doing.
- Loading branch information