167 Commits

Author SHA1 Message Date
Miao Wang
7787760961 Merge "[RenderScript] fix Allocation.copyToFieldPacker" 2015-05-19 16:45:13 +00:00
Jason Sams
54371b4b09 Fix issues found during CTS testing of FP16
bug 20822382

This corrects a copy&paste error placing F16 into F32.
Fixes an error disallowing vectors of fp16 types.

Change-Id: I34be1aa9a323d61a7121581ab9599d2c2d32dd42
2015-05-13 17:02:36 -07:00
Miao Wang
bfa5e659e7 [RenderScript] fix Allocation.copyToFieldPacker
Change-Id: Iaba3333f9741238745fdb5c94f1b27b1015d50b2
2015-05-11 15:49:18 -07:00
Miao Wang
cce01f480f [RenderScript] (minor) fix validation of L3 BLAS
bug: 21028875

Change-Id: I9fd48c57b6518e06ee1d9d7d4ca44faa96d887b0
2015-05-11 12:19:33 -07:00
Miao Wang
6517eb635a [RenderScript] Make L2 BLAS methods pulic field.
Change-Id: Ia5f6a747c4998203f8155c67111aea70301af24a
2015-05-07 17:56:05 -07:00
Miao Wang
328919aeb5 [RenderScript] typo fix in BLAS, TRMM & TSMM
Change-Id: I78f014a864700369c7ccdfb46a257851a45abd7c
2015-05-07 15:53:30 -07:00
Miao Wang
e1cf095071 [RenderScript] fix edges cases about Transpose for SYMM & SYR2K
Change-Id: Id86d5fe8475060a22f49b06b6e1f8f3eae7c7e9f
2015-05-07 15:48:04 -07:00
Miao Wang
cc711795e2 [RenderScript] L2 BLAS, fix element type in ZHER
Change-Id: I99f9f9ff8942522d6581ff60b9a2d75e33e66ff6
2015-05-07 15:44:08 -07:00
Miao Wang
b530d8ec79 [RenderScript] fixes for L3 BLAS APIs
- Typo for validateUplo
  - Typo in ZHEMM, element should be FLOAT64_2.
  - For GEMM and SYMM, SYRK, 'CONJ_TRANSPOSE' should also be handled in the
    validation process.
  - For SYMM, check matrix A is symmetric.
  - For HERK, the dimension validation was switched for Transpose case.
    Also, only Conj Trans is allowed in this case.
  - FOR SYR2K, fix the dimension check for Matrix C.
  - For TRMM & TRSM, fix the validation part for dimension check.

Change-Id: I559b5c5695aa82604de2955ae2327b694236d3ed
2015-05-07 15:41:37 -07:00
Miao Wang
2b6fad9339 [RenderScript] improve & minor fixes of L2 BLAS validation.
Change-Id: If8dd0f9d4c7db03df22763a80fa6d600539be7c1
2015-05-07 15:39:50 -07:00
Miao Wang
333bcc0485 [RenderScript] Fix HEMM and SYRK in IntrinscBLAS to correctly handle
complex 'Alpha' and 'Beta'

Change-Id: I0aed57d41b0199d5c6dd3c31ca33644a5634dc35
2015-05-07 15:34:50 -07:00
Jason Sams
d5c780a787 Merge "Fix Allocation-less launches" 2015-05-05 21:57:27 +00:00
Yang Ni
4e90b9b57c Sanity checks in JNI code for closure creation
b/20728113

In case the requested size for memory allocation overflows, or memory
allocation fails.

Change-Id: I8dac132dd4d0210938660ffbb82cbe44000d2a90
2015-05-01 14:39:02 -07:00
Yang Ni
ead1af8319 Move new script group API into ScriptGroup class
And mark existing methods and builder deprecated.
Removed ScriptGroup2 class.
Renamed nested class UnboundValue to Input.
Marked classes Closure, Future, and Input as final.

Change-Id: I362910c115e9d0173dc515674e08bf4878232879
2015-04-22 15:34:07 -07:00
Jason Sams
bc5c64b725 Fix Allocation-less launches
Change-Id: Ic4c6644072a11aab9a273070be5734519136f685
2015-04-16 15:13:52 -07:00
Miao Wang
782b43394e Merge "[RenderScript] typo fix in Allocation.java" 2015-04-16 02:03:32 +00:00
Miao Wang
179e8b5351 [RenderScript] typo fix in Allocation.java
Change-Id: Id0eae76387d18c5bfed6cdbb52781b0dc3e4ae90
2015-04-15 17:44:32 -07:00
Tim Murray
7f72f74766 Merge "Add BNNM intrinsic." 2015-04-15 22:30:14 +00:00
Tim Murray
9cb16a2f91 Add BNNM intrinsic.
Change-Id: I05fc9835786455e28d69f2b4ffe70c3292a01404
2015-04-14 15:10:19 -07:00
Yang Ni
35be56cce8 Add name to ScriptGroup2.Builder.create() method
This name will be used to name the .so file generated for the
script group with fused kernels.

Change-Id: I46e351c8412740512f56b7915b14f36183c6eeaf
2015-04-13 17:24:44 -07:00
Yang Ni
ad6b44aaa1 Add a name to ScriptGroup2.Builder.create method
The name is not used in any meaningful way yet, but would be used
to name the file for generated code for fused kernels in other
coming CLs.

A script group name cannot be null or empty, or longer than 100
characters. It can only contain letters, digits, '-', or '_'.

Change-Id: I95fdbf58e6689da91ca98c2057dfa1a803d3b27b
2015-04-13 14:32:18 -07:00
Tim Murray
47f31582b6 Add support for setting the cache directory.
Change-Id: I2bf1874705b877a8a8262ab49b47fe8241e603d5
2015-04-09 17:50:39 -07:00
Tim Murray
e1e6c66198 Move cache dir to its own class.
This prevents us from loading the RS static initializer all the time.

Change-Id: I8cea7540e50251aba8c2f199f06f344f991e7d7f
2015-04-07 13:24:14 -07:00
Jason Sams
7200f661c1 Merge "Fix minor blur doc bug" 2015-04-06 23:38:05 +00:00
Yang Ni
8bcbf47245 Rewrote FieldPack::createFieldPack for alignment
b/20032217

Some data types requires data alignment. This has an impact on the
total data size for the FieldPack. Fixed createFiledPack()
implementation to handle this correctly.

Change-Id: I241da19df69bf51cfdaf3b3a1381b446eaacb7fb
2015-04-06 14:49:53 -07:00
Miao Wang
d9b6328509 [RenderScript] update exception reporting for copyTo() after
autoPadding added.

 - This CL fixes recent CTS failures about copyPadded after
   lmp-mr1-dev changes pushed to aosp.

Change-Id: Ica1f4fd934cd83ca4357ea7e7c82dcc7f844b689
2015-04-03 09:15:39 -07:00
Jason Sams
37192dcde3 Fix minor blur doc bug
Change-Id: I4c129d9d3c93d8a36c887e5c594b4402aca5745e
2015-04-02 14:10:53 -07:00
Yang Ni
4c93c8c93a Fix value size data type in closure creation.
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: I1179d34aa67f845578740e71cc2da4f82419f251
2015-03-30 10:45:34 -07:00
Jason Sams
fb4f5cf614 Fix doc bug for object size.
Change-Id: I3c810abcb9734196bd8804a22efc010dd3a73291
2015-03-26 17:39:34 -07:00
Jason Sams
bca8e6d35f Catch errors for unknown object types.
bug 19805334

Change-Id: I71e172b8123076896737d352403f8ddefca544b6
2015-03-26 15:29:56 -07:00
Jason Sams
ae5be38ebb Fix potential npe
bug 19805515

Change-Id: Id36b145d3ce1c81311e88f5cdd2441880e98f737
2015-03-26 14:47:17 -07:00
Miao Wang
a4e5adf955 [RenderScript] Add create(Context, int) to be compatible with
the thunker layer & minor tweaks.

bug:19888167
bug:19888339
Change-Id: Ib264c4ca48c990b3476456838047f73d95f6752f
2015-03-23 11:50:18 -07:00
Yang Ni
8ff2980f31 New API methods for Script Group
Use a single vararg Object array for both kernel/invoke arguments
and global bindings. The assumption is that global bindings are in
the end after the kernel/invoke arguments.
This simplifies the api to add a kernel or invoke to a script group.

Change-Id: I7efb1035c5967e2cadd15e6fe27f20c80ba197a2
2015-03-19 14:38:20 -07:00
Yang Ni
c077ee316e Merge "Added copyright notice and formatted to convention" 2015-03-19 21:28:13 +00:00
Jason Sams
f75e4ca394 Merge "Make it harder to leak contexts" 2015-03-19 18:38:16 +00:00
Jason Sams
e16da12b7b Make it harder to leak contexts
Change-Id: Ied60b6428bedb200d7b5b627e8196fbf2b4151e1
2015-03-18 17:04:18 -07:00
Andreas Gampe
9cc36ac2a2 Merge "Frameworks/base: Remove duplicate check in Mesh" 2015-03-18 22:19:27 +00:00
Andreas Gampe
8df1bedcba Merge "Frameworks/base: Fix potential NPE in Script" 2015-03-18 22:18:26 +00:00
Andreas Gampe
ad555f91a0 Frameworks/base: Fix potential NPE in Script
Bug: 19797138
Change-Id: I5cd9394bd2c0f7c044c1f2f24665384fa797cd97
2015-03-18 12:24:57 -07:00
Andreas Gampe
16720c1849 Frameworks/base: Remove duplicate check in Mesh
Bug: 19797138
Change-Id: I0b11c4ff63a8031d5e58a06ac13f91ae0bbac5dc
2015-03-17 19:10:14 -07:00
Jason Sams
1e68bac5f8 Avoid duplicate surface creation.
Change-Id: I43104c8b48dd26681735940e6b2e1ba902af2020
2015-03-17 16:36:55 -07:00
Yang Ni
cc1ca488e2 Added copyright notice and formatted to convention
Pure format change. No other changes at all.

Change-Id: I74a53aa67ef0960f70becaf288b85be40066a0ae
2015-03-16 15:53:18 -07:00
Andreas Gampe
c8ddcddd13 Frameworks/base: Check before foreach in Script
According to the if below, ains == null is potentially valid. But
the foreach loop would throw a NullPointerException.

Change-Id: I4460fb1357eaa3abfe0ab9a21effb608f474ab51
2015-03-15 15:57:30 -07:00
Jason Sams
a7e2509d8d Remove dead path code
This API was never shipped and the implementation
never finished.

Change-Id: I2491db216d6a7a8ea30628d791773f89da5fb4d2
2015-03-11 11:00:00 -07:00
Miao Wang
c1e2bf95ab am 4b5af9bc: Merge "[RenderScript] Update the java API about Allocation copyTo & From FieldPacker"
* commit '4b5af9bce10dbb8b6d5ff27a5f0c49f3498a6245':
  [RenderScript] Update the java API about Allocation copyTo & From FieldPacker
2015-03-06 01:10:38 +00:00
Miao Wang
a61832c8fd am 288e6f67: Merge "[RenderScript] AutoPadding & Unpadding for Vec3 Elements during copyTo & copyFrom."
* commit '288e6f67181ce74ec4b97b61def1b9510b1221d0':
  [RenderScript] AutoPadding & Unpadding for Vec3 Elements during copyTo & copyFrom.
2015-03-06 01:01:58 +00:00
Miao Wang
45cec0a971 [RenderScript] Update the java API about Allocation copyTo & From FieldPacker
Change-Id: I4e1b911d4cdfec8a841bc5a8bc615c64c50e8fc8
2015-03-05 16:52:05 -08:00
Miao Wang
87e908dfde [RenderScript] AutoPadding & Unpadding for Vec3 Elements during
copyTo & copyFrom.

Change-Id: I10b6fb235717e181ebb30b92e4dbe23e6183a29c
2015-03-04 15:50:11 -08:00
Miao Wang
411473de4a am caa8a8fb: Merge "[Renderscript] JAVA API update for Allocation.CopyTo add the following functions to make it more symmetric to copyFrom()."
* commit 'caa8a8fb9849f1d44ffab3117950ac1e7b02cd4d':
  [Renderscript] JAVA API update for Allocation.CopyTo add the following functions to make it more symmetric to copyFrom().
2015-03-03 01:11:18 +00:00
Miao Wang
caa8a8fb98 Merge "[Renderscript] JAVA API update for Allocation.CopyTo add the following functions to make it more symmetric to copyFrom()." 2015-03-03 00:57:48 +00:00