Why I Get "invalid Rs Info File"?
Solution 1:
Temporary workaround: I got the same issue with the CarouselExample RS after installing Android Build-Tools version 19 when having Build-Tools 17 installed. After deinstalling Build-Tools version 19, it works again. I don't know what is going on with version 19.
Solution 2:
Native RS isn't backwards compatible from new versions of RS to old versions of RS (LLVM bitcode differences, things like that). The error you're getting is expected in this case.
RS with the support lib enables API 18 RS to run on API 8 through API 17 using a CPU-only fallback path. On devices with API 18 or above, it'll use bitcode, JIT compilation, GPU acceleration, etc--identical to native.
The option you probably want is an option to llvm-rs-cc, the core RS compiler: -target-api. There might be a way to set this from Eclipse, but in your project.properties you should be able to set
renderscript.target=14
and things may work.
Solution 3:
The issue was because the script uses the "old" kernel style:
voidroot(const uchar4 *in, uchar4 *out, uint32_t x, uint32_t y){
after updating the kernel to
uchar4 __attribute__((kernel)) kernel(uchar4 in, uint32_t x, uint32_t y) {
it works. However, now I'm facing the problem that older target devices (API 14 for instance) don't work anymore, so this is not a great solution.
Solution 4:
You mention seeing this log line, but does the code actually run/work? That log is saying that the info file doesn't exist, which is the case whenever you first install the application or when you clear its cache. Info files are an internal implementation detail that allows us to cache/load existing binary code for RS. I don't think there is an actual bug here. Let me know if you still see the code not running at all.
Solution 5:
I was targetting a x86 device on 4.3 (API 18) using latest RS buildtools (20) with:
renderscript.support.mode=truerenderscript.target = 18
I had also the same error, followed in the stacktrace with many lookup failed errors, in my specific case related to pow and exp functions:
E/RenderScript(5251): ScriptCsymlookupfailedforpowfE/RenderScript(5251): ScriptCsymlookupfailedforexpf[...]E/bcc(5251): Somesymbolsarefoundtobeundefinedduringrelocation!
E/bcc(5251): Erroroccurredwhen performs relocation on /data/data/*********/cache/com.android.renderscript.cache/synth.o!
[...]
E/RenderScript(5251): bcc: FAILS to prepare executable for 'synth'
[...]
E/AndroidRuntime(5251): Caused by: android.renderscript.RSRuntimeException: Loading of ScriptC script failed.
[...]
I/Process(5251): Sending signal. PID: 5251SIG: 9
Thus, to solve this issue, I replaced calls of pow and exp respectively by native_powr (not visible in the documentation but available) and native_exp in the RS source code. Note that it's also important to properly clean your project, otherwise you might end up with a different crash as:
A/libc(5844): Fatal signal 11 (SIGSEGV) at 0x97698030 (code=2), thread 5844 (****)
Post a Comment for "Why I Get "invalid Rs Info File"?"