History log of /frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
8c1177be9bd7175979e970a066474bc6f258ba48 11-Oct-2017 Dan Albert <danalbert@google.com> Add missing includes.

Test: mma
Bug: None
Change-Id: I56db7a5411a18520ed8082b78a8789b3357c2791
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
f186c5d799bf401d0384d0145f01de76a6ab6e0e 10-May-2017 Miao Wang <miaowang@google.com> Fix typo in ScriptForEachMulti support lib jni.

Bug: 38163938
Test: mm, and verified the affected test not crashing any more.
Change-Id: Ief9d9a409a726ec909da2abb10d7e25fe3f3853d
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
c020bdd35e30a0478c1d642a64abb26ccd1d372c 16-Feb-2017 Miao Wang <miaowang@google.com> Add dispatch table entries required by RenderScript HIDL implementation.

- Add several missing entries to the dispatch table. Dispatch table is
now used for switching between HIDL implementation and our CPU
fallback, instead of only accessing the APIs exposed by RS
support library and RS NDK library.

Bug: 34396220
Test: mm
Change-Id: Ie06746ed6a59120af008e1bf291479bf3c6407ec
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
d602b3121f8eed302002aed88ea6d881fc73dd24 14-Jun-2016 David Gross <dgross@google.com> Merge \\"Delete simple reduction implementation.\\" into nyc-dev am: ad849948dc
am: 1480d8fef2

Change-Id: Id74aa55a863bd58ef8d5b0c7322d2238bcd181b8
2141e9b9d98b6f4e2f4124f9b67a7819e8d40a4c 02-Jun-2016 David Gross <dgross@google.com> Delete simple reduction implementation.

Bug: 27298560
Change-Id: I8d246c4e7d5b427148ebaf9a17bfa6fe3f6ea78b
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
cf8cd79a6e480ef1b92cab2a113c1192de5d623f 30-Apr-2016 Yang Ni <yangni@google.com> Zero-initialize launch option fields

Bug: 28463187

If left unintialized, these fields will fail checks in
setUpMtlsDiemensions() in rsCpuScript.cpp (if targetAPI >= 23).

Change-Id: I143bfcd052a7b799801bf5fbf2b1bae13ca4a671
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
b9493edce485263c3ae9b1f648715ed19dc55da2 30-Apr-2016 Yang Ni <yangni@google.com> Zero-initialize launch option fields

Bug: 28463187

If left unintialized, these fields will fail checks in
setUpMtlsDiemensions() in rsCpuScript.cpp (if targetAPI >= 23).

Change-Id: I143bfcd052a7b799801bf5fbf2b1bae13ca4a671
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
e5125574a68ee6283c300732a11662d8f9945624 25-Mar-2016 Yang Ni <yangni@google.com> Removed unused variables

Bug: 27272549

Also avoided alloca(0)

Change-Id: I64d0baf3ccd1da37851f337293d356973a12a9d7
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
6a8ec7ed1b46523ad0b468c4345801fb9454ebef 19-Mar-2016 Stephen Hines <srhines@google.com> Fix possibly uninitialized access to strideIn, and turn on -Werror.

Change-Id: Ia3f333761e512490a9db61e74c56c1d56a6d1dc5
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
f9e49ed8dd695fe9c7dd9b3516d613365667763a 12-Feb-2016 David Gross <dgross@google.com> Compatibility library support for general reduction.

Requires corresponding change in frameworks/rs.

Bug: 23535724
(cherry picked from commit 62a63e5b0d6548c3ff8ade45235739008f6589f1)

Change-Id: I171eda6388115e19bea9c51c3c68a857d866cf25
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
043d28678b7e52ed1011286af57173c2c7bec749 12-Feb-2016 David Gross <dgross@google.com> Compatibility library support for general reduction.

Requires corresponding change in frameworks/rs.

Bug: 23535724
Change-Id: Ib5d047470ce76edbf02fb025a16624c3192562f2
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
ea7e7afcc59db75fbc3844c63568fc1bca1dbf78 12-Feb-2016 Miao Wang <miaowang@google.com> [RenderScript] Fix potential leak in RS JNI

Bug: 27145639
Change-Id: I4d0759c3658dd3de3026237a670bdfb07fd6d268
(cherry picked from commit 11fdcf704d79b0609887069cecab51dd964fa4b2)
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
cc99363890bf2d4ef5da32bad794cad7089b1eec 12-Feb-2016 Miao Wang <miaowang@google.com> [RenderScript] Fix potential leak in RS JNI

Bug: 27145639
Change-Id: I4d0759c3658dd3de3026237a670bdfb07fd6d268
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
29f8636ee81c93588204e54273df97d8326b103c 25-Nov-2015 Miao Wang <miaowang@google.com> [RenderScript] Add API to map Allocation mallocptr to Java ByteBuffer

- Construct the ByteBuffer using the AllocationGetPointer when running
on L+ devices, otherwise create a read-only ByteBuffer and
explicitly copy the data from Allocation to it.
- Add an API to query the stride of the allocation.
- Both ByteBuffer and Stride will be cached for normal Allocations.
if using USAGE_IO, since after each ioReceive, the mallocPtr will
change, getByteBuffer will always create a new one using the most
up-to-date mallocPtr.

Bug: 25926361

Change-Id: I3ac187ffc598d07362abb704ec3393ae2b8b892a
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
75c84f43017db82b547665436e7abda2caa2a645 12-Nov-2015 Yang Ni <yangni@google.com> Various fixes in setting globals in a script group

Bug: 25602504

1) Passing floating point values into a script group was broken,
since they were casted to long values. Fixed that in the frameworks
implementation by taking the raw bits instead.

2) Passing 64-bit values into a script group was broken on 32-bit
platforms, since they were casted to pointer-sized integers
(uintptr_t) in the JNI code. Fixed that by casting to int64_t
instead.

3) Setting global variables of Allocation type in a script group was
broken. The special size value -1 was used to indicate the value is an
Allocation. However, size was casted to size_t in the JNI code.
Fixed that by using signed integers.

Change-Id: Ifff099a76be7707df7b67c388395f5a00f9cae66
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
d3fdb27e85cd38ffacd963bced1f91a9297a68d8 07-Nov-2015 Miao Wang <miaowang@google.com> [RenderScript] Load from the full path of librsjni and libRSSupport.

- For API 9+ load from the full path of librsjni, libRSSupport.
- Enable logging of critical error.
- Log the version of both JAVA and JNI.

Bug: 25226912
Change-Id: I357398634ec3bfd70c71e005241c5a66650bdba6
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
38ac0d48403bd7e46bd32de0285e1de4c93afc74 23-Oct-2015 Miao Wang <miaowang@google.com> Fix improper declaration/use of pointer.

https://code.google.com/p/android/issues/detail?id=61547

This variable is shadowing the outer "ptr" declaration, resulting in a
potential NULL pointer being passed to the message API.

Previous CL in fw/base/rs: Change-Id: If96bfae8d5e874e12597182678a180ba137b78da

Change-Id: I46ec4eceb197f0e78769c764edb9884d1488da11
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
1e46e4458cd167070301ecbc81ceea73c49eb0f6 01-Oct-2015 Miao Wang <miaowang@google.com> [RenderScript] pass correct length of ains to BLAS functions.

bug: 24540091
Change-Id: I7b7b42041d2241c265c15f5b92394f6b7cef8c2b
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
5154a13fa3b65d2f4e47ceeca51f4013daa49b7a 18-Aug-2015 Matt Wala <wala@google.com> Add reduce kernels to the support library.

Currently hidden behind a flag, since reduce isn't part of any API
level yet.

Bug: 22631253
Change-Id: Ia8e8bb9429f9cb8844d38067f43fa493cbb8540c
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
94ded3567e0f2a567887e5d8ab896634da855a2e 24-Jul-2015 Miao Wang <miaowang@google.com> [RenderScript] Adaptive alignment of allocation for Incremental Intrinsic Support.

Change-Id: I8e93317a00b8b80cdbdcc76df6c8b073f3e4bcd8
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
89b58238694d7d1eebaac0aa59b0bdd67a779582 18-Jul-2015 Miao Wang <miaowang@google.com> [RenderScript] Add Multi-input Kernel support in RS Support lib

- Only functional for target API >= 23.

bug: 22541075
Change-Id: I4ad46d4d60c38f5b2adeacde6d878098ee903b4b
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
341032cd8e6c1a8a8ddceccdafbf02687d0828ac 01-Jul-2015 Miao Wang <miaowang@google.com> [RenderScript] update the type of offsets for BLAS.BNNM for RS support
lib.

bug: 22184114
Change-Id: I59686228cf716b0eace80541a43ac99f1da2f208
(cherry-picked from commit: 2e372074c036b9a8e4b4a1cbbd394071a50586df)
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
8919a441f977cb787d244aa42cc2d4dda1cbfa11 13-May-2015 Miao Wang <miaowang@google.com> [RenderScript] Implement BLAS in support lib.

- Works in compat mode
- Native mode is enabled if targetSdkVersion >= 23 and deviceAPI >= 23
- As other intrinsics, if set targetSdkVersion = 21, Incremental
Support (hybrid mode) will be enabled on device running L or later.

bug: 21902810

(cherry picked from commit 8dab1e59827244f84ceb73c5eb24427223b58b21)

Change-Id: I62410d174a60ab2a284cc94e8a1f6fcd70b7e102
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
e6821d265a52424e23ec2c8d88712ee420726d1e 08-May-2015 Yang Ni <yangni@google.com> Merge "Sanity checks in JNI code for script groups"
2ee9138416600d9d66c254d1d5fe58b1616eba77 07-May-2015 Miao Wang <miaowang@google.com> Merge "[RenderScript] Better handle DispatchTable init"
d454f4541683a6bddfa1d00424a71f5855675e86 05-May-2015 Yang Ni <yangni@google.com> Sanity checks in JNI code for script groups

b/20728113

This is copying the fix I made in native implementation.
(https://android-review.googlesource.com/148980)

Change-Id: I231c0d20c41ee53342d8a975c2db5a31854b9d40
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
e68c5973af1e80c77cab9aea0b77f46a801aef96 06-Apr-2015 Yang Ni <yangni@google.com> Added a script group name to ScriptGroup2 API

Change-Id: I46e351c8412740512f56b7915b14f36183c6eeaf
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
e27a340e3a55a3650e1f74bf1d350104596c4d4b 03-Apr-2015 Miao Wang <miaowang@google.com> [RenderScript] Better handle DispatchTable init

1. targetSdkVersion <= deviceAPI, run in native mode when possible
(deviceAPI >= 19);
2. deviceAPI < 19, always use compat mode;
3. targetSdkVersion > deviceAPI, and if 19 < deviceAPI < 21, use compat
mode (since getPointer is not supported before L);
4. targetSdkVersion > deviceAPI >= 21, first try to initialize
DispatchTable based on targetSdkVersion using native mode (libRS.so), if
failed (say if targetSdkVersion = 23, native RS @21, dispatchTable will
not be able to initialized due to the new APIs added), fall back to
compat mode. If native mode successfully loaded, the Incremental
Intrinsic Support can kick in if needed.

Change-Id: Icafe2a1a5512dd15f399341c239dec802442033c
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
6be479e2c58a3ee7880f812f9b13970df8f7c529 31-Mar-2015 Miao Wang <miaowang@google.com> [RenderScript] Fix value size data type in closure creation.
Same change as the native RS part.

b/19944127

Also added references to arguments and global values in a closure to
keep them live in Java while native code may access them.

Change-Id: Icc189df881b17efb2931eea5879c55abf71c7213
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
b1c365bfb0566142c49375f09f2b8289182f1f47 31-Mar-2015 Miao Wang <miaowang@google.com> [RenderScript] Add ScriptGroup2 API for RenderScript Support Lib.

- For now, the new ScriptGroup2 API is only available for API 23+
native mode, or pure compat mode.
- Incremental Support Mode (hybrid mode) will be added in another CL.

Change-Id: I268e721e8724d51e54ab3f80e7762da4ddac4ff9
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
7c0de6383be18a1dae1297c54c56f3d9afbeaaad 06-Mar-2015 Miao Wang <miaowang@google.com> [RenderScript] Add additional check for determining whether to use
native RS.

Workaround for Incremental Support lib on KK.
- if targetSdkVersion > device API version, always use compat mode
to gain access to all the intrinsics.
- For developers intended to use intrinsics introduced later than KK
Need to set the targetSdkVersion > KK, which is running in compat
mode.
- Otherwise on KK, be able to run scripts and intrinsics<=19, in native
mode.

Change-Id: Ie00ab8b05d274b46cafd71d1347ef7ac4e91aca7
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
3bc17a5878f014a61d67e38901f310fd77aeaeac 05-Mar-2015 Miao Wang <miaowang@google.com> [RenderScript] Update the java API about Allocation copyTo & From
FieldPacker

Change-Id: I1b9b1de3e0a6b975770d9af376f696eacaa8251b
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
6f5555db1af436bb5aad430e6e00aa5b69d5ca6c 26-Jan-2015 Miao Wang <miaowang@google.com> [Renderscript] Incremental Support for Intrinsics.

- If Intrinsic API is higher than Device API,
run on compat context.
- By default, run on Native RS if available.
- If forced using compat mode, or Device API<=19,
Just fall back to regular compat mode.

Change-Id: Icb0a87ea4bcf0524c1ed2841702f1cc4f04ea24d
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
2e1cfff791e07a1caa8cb5ece86e8627f4be8b3f 28-Feb-2015 Miao Wang <miaowang@google.com> [RenderScript] AutoPadding & Unpadding for Vec3 Elements during
copyTo & copyFrom.

Change-Id: Ideaa7c9393a8cb620f5b286985a8c69eff7a6c2f
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
244b72fe088a6393f37dea49ff89cf9df738a492 21-Feb-2015 Miao Wang <miaowang@google.com> [Renderscript] JAVA API update for Allocation.CopyTo
add the following functions to make it more symmetric to copyFrom().

- copy1DRangeToUnchecked, copy1DRangeTo
- copy2DRangeToUnchecked, copy2DRangeTo

Change-Id: Ic9cd9e849f98955240e8f863202e098b58b16438
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
8352bdceb7f0030593db04a06ba8caebf81eaeea 19-Feb-2015 Miao Wang <miaowang@google.com> [RenderScript] Code clean up & Update the support lib based on native
rs. (java interface)

Change-Id: Ic4807c8913b58e833da57da77a23648feb91ff6b
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
ecccf940f72679f7602c52b0b4bcb245acdad55b 14-Jan-2015 Miao Wang <miaowang@google.com> [Renderscript] Set native lib path from java RS context for rs compat lib.

Change-Id: I84c3659bffa34d3fa07f14a7b423ed06c5315855
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
086010500c28e2bca57ea583d3f38da9a2f2f414 24-Jan-2015 Yang Ni <yangni@google.com> InvokeID in compat lib.

Change-Id: I5b59df166ea30b309b8dd9623825ac0e72d03856
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
bec39b6de685a7dddb1925c7e9f83fae20388de3 03-Dec-2014 Miao Wang <miaowang@google.com> Required 64bit changes for JNI/Java for RS compat lib.

Change-Id: I535e41c239ea536dd454646d8dbc03c4be212489
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
a6620f0f767012a1d0c2c8f71529c919bba74a41 09-Jan-2015 Miao Wang <miaowang@google.com> Hide the ScriptGroup2 apis in JNI for now.

Change-Id: I4d6174debeb44aa72c03aed0eada29d800160c22
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
e4d028863c1429047c18f0482e69e717e1bbc23b 08-Jan-2015 Yang Ni <yangni@google.com> Merge "New Script Group API for support library."
936fbd696aac243a514f74b6fee6efd5959527a4 05-Jan-2015 Yang Ni <yangni@google.com> New Script Group API for support library.

Change-Id: I9c612cf8874aabaf0ca7d1640567464c71ed3070
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
dd12e72228ea20b7fdea4dbf32c88291aef6d552 06-Nov-2014 Miao Wang <miaowang@google.com> Enable USAGE_IO_OUTPUT and corresponding SetSurface and IOSend functions
for in RS Compat lib.

The USAGE_IO support is provided by a shared lib (libRSSSupportIO)
dynamically loaded on devices running ICS or higher.

bug 12924018

Change-Id: Id9478f8db0d52dd6891e367dbef0d64a186ca399
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
32a07c00686e1d763681c9a2ebc2b268b1b94a0c 21-Nov-2014 Miao Wang <miaowang@google.com> Allow the Renderscript Compat lib to work on devices running ICS or lower.

- WAR for the bug that the dynamic linker ignores RTLD_LOCAL on older devices.
- Cleanup of Android.mk for librsjni

Change-Id: Icaf29339a29e7f0a7381d883c0ab8a1212b1575d
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
14ff9bdadc9f41b943611201bd8cc942dddc8ee3 16-Oct-2014 Miao Wang <miaowang@google.com> Create a separate static lib that provides a dispatch table to both fw/support/v8/renderscript/jni and libRScpp to reduce code duplication.

- This CL contains related changes to libRSSupport.

Change-Id: I9f243d319eb29ddc048feb3cea5866c813d9f622
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
470b3b5b70ec71042d30004747c625ca76c4007a 10-Oct-2014 Miao Wang <miaowang@google.com> Rewrite the support lib to switch compat lib over to dispatch table.

- Thunker classes are no longer needed.

Change-Id: If6f418828183ce18e307903e77ef1a5a5960a23a
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
1bb70c5cd78ab10ee54376f76d78b61c8352badd 25-Jun-2014 Stephen Hines <srhines@google.com> Switch from size_t -> uint32_t for dimensions array.

Change-Id: Id7c75caaec2fa3545b1847e640182e7a5fa36b76
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
184d51999d546d11dd18d2f5f848871f8459a230 04-Mar-2014 Tim Murray <timmurray@google.com> Remove liblog dependency in JNI and move to building with NDK.

Undefines FORTIFY_SOURCE because it doesn't work correctly with the NDK on non-ARM at the moment.

Change-Id: Ic6f77bc7874ffaf4a4662249a013fba5da246747
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
6559efb5b67a8629996c2697faf59e901f3a4d07 10-Sep-2013 Tim Murray <timmurray@google.com> Switch to flags word for context init.

bug 10427951

Change-Id: Icb244c15355843177bbddf3651aaa1046ad9e555
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
257cecb5e24c9af71ba4d621887e88e46b0ac411 02-Jul-2013 Stephen Hines <srhines@google.com> Fix RS support library.

Bug: 9664050

1) Remove dependency on libskia.
2) Remove dependency on libandroid_runtime.
3) Switch libcutils/liblog to use static libraries.
4) Remove unused include of JNIHelp.h.
5) Fix missing default USAGE_GRAPHICS_TEXTURE for bitmap Allocations.
6) Provide a setprop for testing compatibility mode:
adb shell setprop debug.rs.forcecompat 1
7) Move shouldThunk() function into base RenderScript class.
8) Switch to actual NDK-provided logging infrastructure.
9) Remove dependency on libutils.

Change-Id: Ie218e05c78aac8f0c0cecb0b84bcfd2ab2fbf845
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp
c89ad4606ae29e103b85bdfc40c57e36c8877dba 29-May-2013 Scott Main <smain@google.com> re-organize renderscript support lib to match organization patterns

Bug: 9188088

Change-Id: I8ef73a288aa0dc6dc92adbe64389dc6dee3ed807
/frameworks/rs/support/jni/android_renderscript_RenderScript.cpp