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
This commit is contained in:
Yang Ni
2015-04-01 17:29:14 -07:00
parent 069f4cbccb
commit 8bcbf47245
2 changed files with 62 additions and 165 deletions

View File

@@ -112,7 +112,7 @@ public class ScriptGroup2 extends BaseObj {
public Closure(RenderScript rs, Script.InvokeID invokeID,
Object[] args, Map<Script.FieldID, Object> globals) {
super(0, rs);
mFP = FieldPacker.createFieldPack(args);
mFP = FieldPacker.createFromArray(args);
mArgs = args;
mBindings = globals;