We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 4406

Summary: failed detection SDL_HasNEON()
Product: SDL Reporter: Sylvain <sylvain.becker>
Component: *don't know*Assignee: Ryan C. Gordon <icculus>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2    
Version: don't know   
Hardware: ARM   
OS: Android (All)   
Attachments: patch

Description Sylvain 2018-12-01 13:41:54 UTC
When compiling with armeabi-v7a, SDL_HasNEON() doesn't detect NEON.

In this mode, it uses "readProcAuxvForNeon()" which reads "/proc/self/auxv".
But this is sometimes not accessible.

in ndk cpufeatures it says:

   // Parsing /proc/self/auxv will fail from regular application
   // processes on some Android platform versions, when this happens
   // parse proc/cpuinfo instead.


We should use cpufeatures that also reads /proc/cpuinfo
Comment 1 Sylvain 2018-12-01 13:47:25 UTC
Created attachment 3517 [details]
patch

Patch that uses cpu-features.

- I am not 100% sure of the Android.mk (Mine is a little bit different).

- it also fix a comment missing in blendmode.h (-Wdocumentation)
Comment 2 Ryan C. Gordon 2018-12-01 17:20:24 UTC
> Patch that uses cpu-features.

This is now https://hg.libsdl.org/SDL/rev/3a0793e5e134

( and the blendmode doxygen comment in that patch is https://hg.libsdl.org/SDL/rev/a107bc9988d1 )

Thanks!

--ryan.