Rename ctxt to context.

Rename ctxt to context to be consistent with documentation and our coding
standards that asks us to eschew abbreviations.

b/21647353

Change-Id: Ic8c1c2720276aae60c5d2e3782f4336488ecb61e
diff --git a/api/GenerateStubsWhiteList.cpp b/api/GenerateStubsWhiteList.cpp
index 428dd71..ea18eed 100644
--- a/api/GenerateStubsWhiteList.cpp
+++ b/api/GenerateStubsWhiteList.cpp
@@ -430,7 +430,7 @@
         *calls << separator;
         // Special case for the kernel context, as it has a special existence.
         if (p->rsType == "rs_kernel_context") {
-            *calls << "ctxt";
+            *calls << "context";
         } else if (p->isOutParameter) {
             *calls << "(" << p->rsType << "*) " << addVariable(file, variableNumber);
         } else {
@@ -498,7 +498,7 @@
 
     // Modify the style of kernel as required by the API level.
     if (apiLevel >= 23) {
-        file << "void RS_KERNEL test(int in, rs_kernel_context ctxt) {\n";
+        file << "void RS_KERNEL test(int in, rs_kernel_context context) {\n";
     } else if (apiLevel >= 17) {
         file << "void RS_KERNEL test(int in) {\n";
     } else {
diff --git a/api/rs_for_each.spec b/api/rs_for_each.spec
index 9206d02..bf5ede2 100644
--- a/api/rs_for_each.spec
+++ b/api/rs_for_each.spec
@@ -54,8 +54,8 @@
  A kernel may be executed in parallel over multiple threads.  Each thread will have its
  own context.
 
- You can access the context by adding a rs_kernel_context argument to your kernel
- function.  See @rsGetDimX() and @rsGetArray0() for examples.
+ You can access the context by adding a special parameter named "context" and of type
+ rs_kernel_context to your kernel function.  See @rsGetDimX() and @rsGetArray0() for examples.
 end:
 
 type: rs_script_call_t
@@ -162,7 +162,7 @@
 function: rsGetArray0
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Index in the Array0 dimension for the specified context
 description:
  Returns the index in the Array0 dimension of the cell being processed, as specified
@@ -172,8 +172,8 @@
  It contains common characteristics of the allocations being iterated over and rarely
  used indexes, like the Array0 index.
 
- You can access the context by adding a rs_kernel_context argument to your kernel
- function.  E.g.<br/>
+ You can access the context by adding a special parameter named "context" and of
+ type rs_kernel_context to your kernel function.  E.g.<br/>
  <code>short RS_KERNEL myKernel(short value, uint32_t x, rs_kernel_context context) {<br/>
  &nbsp;&nbsp;// The current index in the common x, y, z, w dimensions are accessed by<br/>
  &nbsp;&nbsp;// adding these variables as arguments.  For the more rarely used indexes<br/>
@@ -189,7 +189,7 @@
 function: rsGetArray1
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Index in the Array1 dimension for the specified context
 description:
  Returns the index in the Array1 dimension of the cell being processed, as specified
@@ -202,7 +202,7 @@
 function: rsGetArray2
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Index in the Array2 dimension for the specified context
 description:
  Returns the index in the Array2 dimension of the cell being processed,
@@ -216,7 +216,7 @@
 function: rsGetArray3
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Index in the Array3 dimension for the specified context
 description:
  Returns the index in the Array3 dimension of the cell being processed, as specified
@@ -229,7 +229,7 @@
 function: rsGetDimArray0
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Size of the Array0 dimension for the specified context
 description:
  Returns the size of the Array0 dimension for the specified context.
@@ -244,7 +244,7 @@
 function: rsGetDimArray1
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Size of the Array1 dimension for the specified context
 description:
  Returns the size of the Array1 dimension for the specified context.
@@ -257,7 +257,7 @@
 function: rsGetDimArray2
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Size of the Array2 dimension for the specified context
 description:
  Returns the size of the Array2 dimension for the specified context.
@@ -270,7 +270,7 @@
 function: rsGetDimArray3
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Size of the Array3 dimension for the specified context
 description:
  Returns the size of the Array3 dimension for the specified context.
@@ -283,7 +283,7 @@
 function: rsGetDimHasFaces
 version: 23
 ret: bool, "Returns true if more than one face is present, false otherwise."
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Presence of more than one face for the specified context
 description:
  If the context refers to a cubemap, this function returns true if there's more than
@@ -297,7 +297,7 @@
 function: rsGetDimLod
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Number of levels of detail for the specified context
 description:
  Returns the number of levels of detail for the specified context.  This is useful
@@ -313,7 +313,7 @@
 function: rsGetDimX
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Size of the X dimension for the specified context
 description:
  Returns the size of the X dimension for the specified context.
@@ -322,8 +322,8 @@
  characteristics of the allocations being iterated over by the kernel in
  a very efficient structure.  It also contains rarely used indexes.
 
- You can access it by adding a rs_kernel_context argument to your kernel
- function.  E.g.<br/>
+ You can access it by adding a special parameter named "context" and of
+ type rs_kernel_context to your kernel function.  E.g.<br/>
  <code>int4 RS_KERNEL myKernel(int4 value, rs_kernel_context context) {<br/>
  &nbsp;&nbsp;uint32_t size = rsGetDimX(context); //...<br/></code>
 
@@ -334,7 +334,7 @@
 function: rsGetDimY
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Size of the Y dimension for the specified context
 description:
  Returns the size of the X dimension for the specified context.
@@ -349,7 +349,7 @@
 function: rsGetDimZ
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Size of the Z dimension for the specified context
 description:
  Returns the size of the Z dimension for the specified context.
@@ -364,7 +364,7 @@
 function: rsGetFace
 version: 23
 ret: rs_allocation_cubemap_face
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Coordinate of the Face for the specified context
 description:
  Returns the face on which the cell being processed is found, as specified by the
@@ -378,7 +378,7 @@
 function: rsGetLod
 version: 23
 ret: uint32_t
-arg: rs_kernel_context ctxt
+arg: rs_kernel_context context
 summary: Index in the Levels of Detail dimension for the specified context
 description:
  Returns the index in the Levels of Detail dimension of the cell being processed,
diff --git a/scriptc/rs_for_each.rsh b/scriptc/rs_for_each.rsh
index 1bbcf9f..9507c0c 100644
--- a/scriptc/rs_for_each.rsh
+++ b/scriptc/rs_for_each.rsh
@@ -57,8 +57,8 @@
  * A kernel may be executed in parallel over multiple threads.  Each thread will have its
  * own context.
  *
- * You can access the context by adding a rs_kernel_context argument to your kernel
- * function.  See rsGetDimX() and rsGetArray0() for examples.
+ * You can access the context by adding a special parameter named "context" and of type
+ * rs_kernel_context to your kernel function.  See rsGetDimX() and rsGetArray0() for examples.
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 typedef const struct rs_kernel_context_t * rs_kernel_context;
@@ -161,8 +161,8 @@
  * It contains common characteristics of the allocations being iterated over and rarely
  * used indexes, like the Array0 index.
  *
- * You can access the context by adding a rs_kernel_context argument to your kernel
- * function.  E.g.
+ * You can access the context by adding a special parameter named "context" and of
+ * type rs_kernel_context to your kernel function.  E.g.
  * short RS_KERNEL myKernel(short value, uint32_t x, rs_kernel_context context) {
  *   // The current index in the common x, y, z, w dimensions are accessed by
  *   // adding these variables as arguments.  For the more rarely used indexes
@@ -175,7 +175,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetArray0(rs_kernel_context ctxt);
+    rsGetArray0(rs_kernel_context context);
 #endif
 
 /*
@@ -188,7 +188,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetArray1(rs_kernel_context ctxt);
+    rsGetArray1(rs_kernel_context context);
 #endif
 
 /*
@@ -202,7 +202,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetArray2(rs_kernel_context ctxt);
+    rsGetArray2(rs_kernel_context context);
 #endif
 
 /*
@@ -215,7 +215,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetArray3(rs_kernel_context ctxt);
+    rsGetArray3(rs_kernel_context context);
 #endif
 
 /*
@@ -228,7 +228,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetDimArray0(rs_kernel_context ctxt);
+    rsGetDimArray0(rs_kernel_context context);
 #endif
 
 /*
@@ -241,7 +241,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetDimArray1(rs_kernel_context ctxt);
+    rsGetDimArray1(rs_kernel_context context);
 #endif
 
 /*
@@ -254,7 +254,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetDimArray2(rs_kernel_context ctxt);
+    rsGetDimArray2(rs_kernel_context context);
 #endif
 
 /*
@@ -267,7 +267,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetDimArray3(rs_kernel_context ctxt);
+    rsGetDimArray3(rs_kernel_context context);
 #endif
 
 /*
@@ -283,7 +283,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern bool __attribute__((overloadable))
-    rsGetDimHasFaces(rs_kernel_context ctxt);
+    rsGetDimHasFaces(rs_kernel_context context);
 #endif
 
 /*
@@ -299,7 +299,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetDimLod(rs_kernel_context ctxt);
+    rsGetDimLod(rs_kernel_context context);
 #endif
 
 /*
@@ -311,8 +311,8 @@
  * characteristics of the allocations being iterated over by the kernel in
  * a very efficient structure.  It also contains rarely used indexes.
  *
- * You can access it by adding a rs_kernel_context argument to your kernel
- * function.  E.g.
+ * You can access it by adding a special parameter named "context" and of
+ * type rs_kernel_context to your kernel function.  E.g.
  * int4 RS_KERNEL myKernel(int4 value, rs_kernel_context context) {
  *   uint32_t size = rsGetDimX(context); //...
  *
@@ -320,7 +320,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetDimX(rs_kernel_context ctxt);
+    rsGetDimX(rs_kernel_context context);
 #endif
 
 /*
@@ -335,7 +335,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetDimY(rs_kernel_context ctxt);
+    rsGetDimY(rs_kernel_context context);
 #endif
 
 /*
@@ -350,7 +350,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetDimZ(rs_kernel_context ctxt);
+    rsGetDimZ(rs_kernel_context context);
 #endif
 
 /*
@@ -364,7 +364,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern rs_allocation_cubemap_face __attribute__((overloadable))
-    rsGetFace(rs_kernel_context ctxt);
+    rsGetFace(rs_kernel_context context);
 #endif
 
 /*
@@ -378,7 +378,7 @@
  */
 #if (defined(RS_VERSION) && (RS_VERSION >= 23))
 extern uint32_t __attribute__((overloadable))
-    rsGetLod(rs_kernel_context ctxt);
+    rsGetLod(rs_kernel_context context);
 #endif
 
 #endif // RENDERSCRIPT_RS_FOR_EACH_RSH