1 package org.ibex.arenaj;
8 public class Main extends SceneTransformer {
10 public static final int initialSize = 1000;
12 private static Main instance = new Main();
14 public static Main v() { return instance; }
16 public static void main(String[] args) throws Exception {
17 if(args.length == 0) {
18 System.out.println("Syntax: java " + v().getClass().getName() + " [soot options]");
21 PackManager.v().getPack("wjtp").add(new Transform("wjtp.tx", Main.v()));
22 String[] args2 = new String[args.length + 14];
23 System.arraycopy(args, 0, args2, 0, args.length-1);
25 System.getProperty("java.class.path") +
27 System.getProperty("sun.boot.class.path");
28 String extDirs = System.getProperty("java.ext.dirs");
29 if (extDirs != null) {
30 StringTokenizer st = new StringTokenizer(extDirs, File.pathSeparatorChar+"");
31 while(st.hasMoreTokens()) {
32 String goo = st.nextToken();
33 File f = new File(goo);
34 if (!f.exists() || !f.isDirectory()) continue;
35 String[] jars = f.list();
36 for(int i=0; i<jars.length; i++)
37 sootcp += File.pathSeparator + f.getPath() + File.separatorChar + jars[i];
40 args2[args.length - 1] = "-w";
41 args2[args.length + 0] = "-p";
42 args2[args.length + 1] = "cg";
43 args2[args.length + 2] = "enabled:false";
44 args2[args.length + 3] = "-p";
45 args2[args.length + 4] = "wjap";
46 args2[args.length + 5] = "enabled:false";
47 args2[args.length + 6] = "-p";
48 args2[args.length + 7] = "jtp";
49 args2[args.length + 8] = "enabled:false";
50 args2[args.length + 9] = "-allow-phantom-refs";
51 args2[args.length + 10] = "-allow-phantom-refs";
52 args2[args.length + 11] = "-cp";
53 args2[args.length + 12] = sootcp;
54 System.out.println("sootcp => " + sootcp);
55 args2[args.length + 13] = args[args.length-1];
56 for(int i=0; i<args2.length; i++) System.out.println("args2["+i+"] = " + args2[i]);
57 soot.Main.main(args2);
60 // The main loop //////////////////////////////////////////////////////////////////////////////
62 public void internalTransform(String phaseName, Map options) {
64 List ac = new LinkedList();
65 for(Iterator it = Scene.v().getClasses().iterator(); it.hasNext();) {
66 SootClass sc = (SootClass)it.next();
69 for(Iterator it = Scene.v().getClasses().iterator(); it.hasNext();) {
70 SootClass sc = (SootClass)it.next();
71 if (!implementsGladiator(sc)) continue;
72 System.out.println(" application class: " + sc.getName());
73 System.out.println(" application class: " + getArenaForGladiator(sc).getName());
74 sc.setApplicationClass();
75 getArenaForGladiator(sc).setApplicationClass();
77 ac.add(getArenaForGladiator(sc));
79 for(Iterator it = ac.iterator(); it.hasNext();) {
80 SootClass sc = (SootClass)it.next();
81 if (sc.isInterface() || !implementsGladiator(sc)) continue;
82 processGladiatorClass(sc);
84 for(Iterator it = ac.iterator(); it.hasNext();) {
85 SootClass sc = (SootClass)it.next();
86 if (sc.isInterface()) continue;
91 // Initializers //////////////////////////////////////////////////////////////////////////////
93 public Type objectType;
94 public List arrayCopyTypes = new LinkedList();
95 public SootMethodRef arrayCopy;
97 objectType = Scene.v().getSootClass("java.lang.Object").getType();
98 arrayCopyTypes.add(objectType);
99 arrayCopyTypes.add(IntType.v());
100 arrayCopyTypes.add(objectType);
101 arrayCopyTypes.add(IntType.v());
102 arrayCopyTypes.add(IntType.v());
104 Scene.v().makeMethodRef(Scene.v().getSootClass("java.lang.System"),
111 // Helpers //////////////////////////////////////////////////////////////////////////////
114 public Local newLocal(Body b, Type t) {
115 Local l = Jimple.v().newLocal("tmpRef" + (tfr++), t);
116 b.getLocals().add(l);
120 public Local viaLocal(Value v, Body b, Unit u) {
121 Local l = newLocal(b, v.getType());
122 if (v instanceof IdentityRef) b.getUnits().insertBefore(Jimple.v().newIdentityStmt(l, v), u);
123 else b.getUnits().insertBefore(Jimple.v().newAssignStmt(l, v), u);
127 boolean implementsGladiator(SootClass c) { return c.implementsInterface("org.ibex.arenaj.Gladiator"); }
128 boolean implementsGladiator(Type t) {return (t instanceof RefType)&&implementsGladiator(((RefType)t).getSootClass());}
129 String getArenaName(SootClass sc) { return sc.getName().substring(0, sc.getName().lastIndexOf('$')); }
130 String getGladiatorName(SootClass sc) { return sc.getName().substring(sc.getName().lastIndexOf('$')+1); }
131 SootClass getArenaForGladiator(SootClass sc) { return Scene.v().getSootClass(getArenaName(sc)); }
132 InstanceFieldRef newIFR(Body b, SootFieldRef fr) { return Jimple.v().newInstanceFieldRef(b.getThisLocal(), fr); }
133 void assign(Body b, Value left, Value right) { b.getUnits().add(Jimple.v().newAssignStmt(left, right)); }
134 void assign(Body b, Value l, Value r, Stmt w) { b.getUnits().insertBefore(Jimple.v().newAssignStmt(l, r), w); }
135 Type getSliceElementType(Type t) { return implementsGladiator(t) ? IntType.v() : t; }
136 SootFieldRef getSliceForField(SootField f) { return getSliceForField(f.makeRef()); }
137 SootFieldRef getSliceForField(SootFieldRef f) {
138 return Scene.v().makeFieldRef(getArenaForGladiator(f.declaringClass()),
139 getGladiatorName(f.declaringClass())+"$$"+f.name(),
140 getSliceElementType(f.type()).makeArrayType(),
145 // Operations performed on the Gladiator class //////////////////////////////////////////////////////////////////////////
147 public SootMethod createIncMethod(SootClass sc) {
148 String incFuncName = getGladiatorName(sc) + "$$inc";
149 SootClass arena = getArenaForGladiator(sc);
150 SootMethod method = new SootMethod(incFuncName, new LinkedList(), IntType.v(), Modifier.PRIVATE, new LinkedList());
151 arena.addMethod(method);
152 Body incBody = Jimple.v().newBody(method);
153 method.setActiveBody(incBody);
154 ((JimpleBody)incBody).insertIdentityStmts();
158 public void processGladiatorClass(SootClass sc) {
160 // Set up the Arena zero-arg constructor
162 SootClass arena = getArenaForGladiator(sc);
163 SootMethod arenaInitMethod = null;
164 for(Iterator it = arena.getMethods().iterator(); it.hasNext();) {
165 SootMethod m = (SootMethod)it.next();
166 if (m.getName().equals("<init>")) {
167 if (arenaInitMethod != null) throw new Error("class " + arena.getName() + " has two constructors");
171 JimpleBody arenaInitBody = (JimpleBody)arenaInitMethod.getActiveBody();
173 SootField maxField = new SootField(getGladiatorName(sc) + "$$max", IntType.v());
174 arena.addField(maxField);
175 assign(arenaInitBody, newIFR(arenaInitBody, maxField.makeRef()), IntConstant.v(initialSize),
176 arenaInitBody.getFirstNonIdentityStmt());
178 SootField sfr = new SootField(getGladiatorName(sc) + "$$size", IntType.v());
180 assign(arenaInitBody, newIFR(arenaInitBody, sfr.makeRef()), IntConstant.v(0),
181 arenaInitBody.getFirstNonIdentityStmt());
183 SootMethod incMethod = createIncMethod(sc);
184 Body incBody = incMethod.getActiveBody();
187 // Now build the $$inc method
189 Local l = newLocal(incBody, IntType.v());
190 Local l2 = newLocal(incBody, IntType.v());
191 Local l3 = newLocal(incBody, IntType.v());
192 Local l4 = newLocal(incBody, IntType.v());
194 assign(incBody, l, newIFR(incBody, sfr.makeRef()));
195 assign(incBody, l2, Jimple.v().newAddExpr(l, IntConstant.v(1)));
196 assign(incBody, newIFR(incBody, sfr.makeRef()), l2);
197 assign(incBody, l3, newIFR(incBody, maxField.makeRef()));
199 Stmt returnStmt = Jimple.v().newReturnStmt(l2);
200 incBody.getUnits().add(Jimple.v().newIfStmt(Jimple.v().newLtExpr(l2, l3), returnStmt));
202 assign(incBody, l4, Jimple.v().newShlExpr(l3, IntConstant.v(1)));
203 assign(incBody, newIFR(incBody, maxField.makeRef()), l4);
206 // Finally, iterate over the Gladiator's fields, updating the $$inc method and Arena's zero-arg constructor as we go
208 for(Iterator it = sc.getFields().iterator(); it.hasNext();) {
209 SootField f = (SootField)it.next();
210 Type t = getSliceElementType(f.getType());
211 arena.addField(f = new SootField(getGladiatorName(sc) + "$$" + f.getName(), t.makeArrayType(), 0));
213 Expr newArr = Jimple.v().newNewArrayExpr(t, IntConstant.v(initialSize));
214 Local newArrLocal = newLocal(arenaInitBody, f.getType());
215 arenaInitBody.getUnits().addFirst(Jimple.v().newAssignStmt(newIFR(arenaInitBody, f.makeRef()), newArrLocal));
216 arenaInitBody.getUnits().addFirst(Jimple.v().newAssignStmt(newArrLocal, newArr));
218 Local ll0 = newLocal(incBody, f.getType());
219 Local ll = newLocal(incBody, f.getType());
220 assign(incBody, ll0, newIFR(incBody, f.makeRef()));
221 assign(incBody, ll, Jimple.v().newNewArrayExpr(t, l4));
223 List args = new LinkedList();
225 args.add(IntConstant.v(0));
227 args.add(IntConstant.v(0));
229 incBody.getUnits().add(Jimple.v().newInvokeStmt(Jimple.v().newStaticInvokeExpr(arrayCopy, args)));
230 assign(incBody, newIFR(incBody, f.makeRef()), ll);
233 for(Iterator it = sc.getMethods().iterator(); it.hasNext();) {
234 SootMethod m = (SootMethod)it.next();
235 if (!m.isConcrete() || !m.hasActiveBody()) continue;
236 boolean doremove = true;
237 Body mincBody = m.getActiveBody();
238 if (implementsGladiator(m.getDeclaringClass()) && m.getName().equals("<init>")) {
239 System.out.println("processing ctor " + sc.getName() + "." + m.getSignature());
241 SootClass c = m.getDeclaringClass();
242 String name = "$init";
243 List li = m.getParameterTypes();
245 SootMethod nm = new SootMethod(name, li, implementsGladiator(m.getReturnType()) ? IntType.v() : m.getReturnType());
246 JimpleBody bod = Jimple.v().newBody(nm);
247 bod.importBodyContentsFrom(m.getActiveBody());
248 nm.setActiveBody(bod);
252 for(Iterator it2 = mincBody.getUnits().snapshotIterator(); it2.hasNext(); ) {
253 Unit u = (Unit)it2.next();
254 if (u instanceof DefinitionStmt) {
255 DefinitionStmt ds = (DefinitionStmt)u;
256 if (ds.getLeftOp() instanceof ThisRef)
257 mincBody.getUnits().remove(u);
258 else if (ds.getLeftOp() instanceof FieldRef) {
259 if (((FieldRef)ds.getLeftOp()).getFieldRef().name().endsWith("this$0"))
260 mincBody.getUnits().remove(u);
262 } else if (u instanceof InvokeStmt) {
263 InvokeExpr ie = ((InvokeStmt)u).getInvokeExpr();
264 SootMethodRef meth = ie.getMethodRef();
265 if (meth.declaringClass().getName().equals("java.lang.Object") && meth.name().equals("<init>"))
266 mincBody.getUnits().remove(u);
271 System.out.println("examining " + sc.getName() + "." + m.getSignature());
272 m.retrieveActiveBody();
274 if (m.isStatic()) continue;
276 String name = sc.getShortName().substring(sc.getShortName().lastIndexOf('$')+1) + "$$" + m.getName();
277 List list = new LinkedList();
278 list.addAll(m.getParameterTypes());
279 list.add(IntType.v());
280 SootMethod m2 = new SootMethod(name, list, m.getReturnType());
281 getArenaForGladiator(sc).addMethod(m2);
283 JimpleBody ab = (JimpleBody)Jimple.v().newBody(m2);
284 ab.importBodyContentsFrom(mincBody);
285 m2.setActiveBody(ab);
286 Local loc = Jimple.v().newLocal("tmpRef" + (tfr++), getArenaForGladiator(sc).getType());
287 ab.getLocals().add(loc);
288 // FIXME: insert assignment to this
290 for(Iterator z = ab.getLocals().iterator(); z.hasNext();) {
291 Local loc2 = (Local)z.next();
292 if (implementsGladiator(loc2.getType())) {
293 loc2.setType(IntType.v());
297 Chain units = ab.getUnits();
298 boolean touched = false;
299 Local loc0 = Jimple.v().newLocal("tmpRef" + (tfr++), getArenaForGladiator(sc).getType());
300 ab.getLocals().add(loc0);
301 for(Iterator stmtIt = units.snapshotIterator(); stmtIt.hasNext();) {
302 Stmt s = (Stmt) stmtIt.next();
303 if (s instanceof IdentityStmt) {
304 IdentityStmt is = (IdentityStmt)s;
305 Local left = (Local)is.getLeftOp();
306 if (is.getRightOp() instanceof ThisRef) {
307 left.setType(IntType.v());
308 is.getRightOpBox().setValue(Jimple.v().newParameterRef(IntType.v(), m.getParameterCount()));
310 units.addFirst(Jimple.v().newIdentityStmt(loc0, Jimple.v().newThisRef(getArenaForGladiator(sc).getType())));
316 for(Iterator i = s.getUseAndDefBoxes().iterator(); i.hasNext();) {
318 if (o instanceof ValueBox) {
319 ValueBox vb = (ValueBox)o;
322 if (o instanceof Local && implementsGladiator(((Local)o).getType())) {
323 System.out.println("thunking");
327 if (vb.getValue() instanceof ThisRef) {
335 if (doremove) sc.removeMethod(m);
338 incBody.getUnits().add(returnStmt);
341 // Operations performed on all classes ////////////////////////////////////////////////////////////////////////////
343 public void processClass(SootClass c) {
344 for(Iterator it = c.getFields().iterator(); it.hasNext();) {
345 SootField f = (SootField)it.next();
346 Type t = f.getType();
347 if (t instanceof RefType) {
348 RefType rt = (RefType)t;
349 SootClass sc = rt.getSootClass();
350 if (implementsGladiator(sc)) f.setType(IntType.v());
351 } else if (t instanceof ArrayType) {
352 ArrayType at = (ArrayType)t;
353 t = at.getElementType();
354 if (!(t instanceof RefType)) continue;
355 RefType rt = (RefType)t;
356 SootClass sc = rt.getSootClass();
357 if (implementsGladiator(sc)) f.setType(IntType.v().makeArrayType());
361 List list = new LinkedList(); list.addAll(c.getMethods());
362 for(Iterator it = list.iterator(); it.hasNext();) {
363 SootMethod m = (SootMethod)it.next();
365 if (m.getName().endsWith("$$inc")) continue;
366 if (m.hasActiveBody()) b = processBody(m.getActiveBody(), c, m);
367 List l2 = new LinkedList();
368 List l = m.getParameterTypes();
369 for(Iterator it2 = l.iterator(); it2.hasNext();) {
370 Type t = (Type)it2.next();
371 l2.add(implementsGladiator(t) ? IntType.v() : t);
373 Type t = m.getReturnType();
374 if (implementsGladiator(t)) {
376 if (m.hasActiveBody()) {
377 Body bod = m.getActiveBody();
378 for(Iterator stmtIt = bod.getUnits().snapshotIterator(); stmtIt.hasNext();) {
379 Stmt s = (Stmt) stmtIt.next();
380 if (s instanceof ReturnStmt) {
381 if (((ReturnStmt)s).getOp().getType() instanceof NullType) {
382 ((ReturnStmt)s).getOpBox().setValue(IntConstant.v(-1));
388 String name = m.getName();
389 SootMethod meth = new SootMethod(name, l2, implementsGladiator(t) ? IntType.v() : t, m.getModifiers());
391 JimpleBody b2 = Jimple.v().newBody(meth);
392 b2.importBodyContentsFrom(b);
393 meth.setActiveBody(b2);
401 protected Body processBody(Body body, SootClass ownerClass, SootMethod smeth) {
402 if (body instanceof JimpleBody) {
403 JimpleBody b2 = Jimple.v().newBody(smeth);
404 b2.importBodyContentsFrom(body);
407 Chain units = body.getUnits();
408 for(Iterator it = body.getLocals().snapshotIterator(); it.hasNext();) {
409 Local l = (Local)it.next();
410 if (implementsGladiator(l.getType())) l.setType(IntType.v());
412 if (!smeth.isStatic())
413 body.getThisLocal().setType(ownerClass.getType());
414 for(int qq=0; qq<2; qq++) for(Iterator stmtIt = units.snapshotIterator(); stmtIt.hasNext();) {
415 Stmt s = (Stmt) stmtIt.next();
416 if (s instanceof DefinitionStmt) {
417 DefinitionStmt ds = (DefinitionStmt)s;
418 if (ds.getLeftOp().getType() instanceof PrimType && ds.getRightOp().getType() instanceof NullType) {
419 ds.getRightOpBox().setValue(IntConstant.v(-1));
422 if (implementsGladiator(smeth.getReturnType()) && s instanceof ReturnStmt)
423 if (((ReturnStmt)s).getOp().getType() instanceof NullType)
424 ((ReturnStmt)s).getOpBox().setValue(IntConstant.v(-1));
425 List l = s.getUseAndDefBoxes();
426 List l2l = new LinkedList();
428 for(Iterator it = l2l.iterator(); it.hasNext();) {
429 Object o = it.next();
430 if (o instanceof ValueBox) {
431 ValueBox vb = (ValueBox)o;
432 Value v = vb.getValue();
434 if (v instanceof BinopExpr) {
435 BinopExpr boe = (BinopExpr)v;
436 Type t1 = boe.getOp1().getType();
437 Type t2 = boe.getOp2().getType();
438 if (t1 instanceof PrimType && t2 instanceof NullType) boe.setOp2(IntConstant.v(-1));
439 if (t2 instanceof PrimType && t1 instanceof NullType) boe.setOp1(IntConstant.v(-1));
442 if (v instanceof NewExpr) {
443 NewExpr ne = (NewExpr)v;
444 if (implementsGladiator(ne.getBaseType())) {
445 SootClass sc = ((RefType)ne.getBaseType()).getSootClass();
446 SootClass arena = getArenaForGladiator(sc);
447 String incFuncName = sc.getShortName().substring(sc.getShortName().lastIndexOf('$')+1) + "$$inc";
448 SootMethodRef smr = Scene.v().makeMethodRef(arena, incFuncName, new LinkedList(), IntType.v(), false);
449 Expr invokeExpr = Jimple.v().newSpecialInvokeExpr(body.getThisLocal(), smr);
450 Local ll = viaLocal(invokeExpr, body, s);
458 if (v instanceof InvokeExpr) {
459 InvokeExpr ie = (InvokeExpr)v;
460 SootMethodRef mr = ie.getMethodRef();
461 String name = mr.name();
462 if (v instanceof InstanceInvokeExpr && implementsGladiator(mr.declaringClass())) {
463 InstanceInvokeExpr iie = (InstanceInvokeExpr)v;
464 List li = new LinkedList();
465 li.addAll(iie.getArgs());
466 LinkedList pl = new LinkedList();
467 for(Iterator it2 = mr.parameterTypes().iterator(); it2.hasNext();) {
468 Type t = (Type)it2.next();
469 pl.add(implementsGladiator(t) ? IntType.v() : t);
471 if (mr.name().equals("<init>") && implementsGladiator(mr.declaringClass())) {
477 li.add(/*viaLocal(*/iie.getBase()/*,body,s)*/);
478 SootClass sc = mr.declaringClass();
479 name = sc.getShortName().substring(sc.getShortName().lastIndexOf('$')+1) + "$$" + name;
480 mr = Scene.v().makeMethodRef(getArenaForGladiator(sc),
483 implementsGladiator(mr.returnType()) ? IntType.v() : mr.returnType(),
485 ie = Jimple.v().newVirtualInvokeExpr(body.getThisLocal(), mr, li);
488 } else if (!(v instanceof StaticInvokeExpr)) {
489 List l0 = mr.parameterTypes();
490 List l2 = new LinkedList();
491 for(Iterator it2 = l0.iterator(); it2.hasNext();) {
492 Type t = (Type)it2.next();
493 l2.add(implementsGladiator(t) ? IntType.v() : t);
495 mr = Scene.v().makeMethodRef(mr.declaringClass(),
498 implementsGladiator(mr.returnType()) ? IntType.v() : mr.returnType(),
504 for(int i=0; i<ie.getArgCount(); i++) {
505 ValueBox b = ie.getArgBox(i);
506 Value val = b.getValue();
507 if (mr.parameterType(i) instanceof RefType && val.getType() instanceof PrimType) {
508 SootClass intClass = Scene.v().getSootClass("java.lang.Integer");
509 List typelist = new LinkedList();
510 typelist.add(IntType.v());
511 SootMethod intMethod = intClass.getMethod("<init>", typelist);
512 Local loc = viaLocal(Jimple.v().newNewExpr(RefType.v(intClass)), body, s);
513 List list = new LinkedList();
515 units.insertBefore(Jimple.v().newInvokeStmt(Jimple.v().newSpecialInvokeExpr(loc,
521 if (val != null && val.getType() instanceof NullType && mr.parameterType(i) instanceof IntType) {
522 b.setValue(IntConstant.v(-1));
527 } else if (v instanceof CastExpr) {
528 CastExpr ce = (CastExpr)v;
529 if (implementsGladiator(ce.getCastType())) {
530 SootClass arena = getArenaForGladiator(((RefType)ce.getCastType()).getSootClass());
531 SootClass ic = Scene.v().getSootClass("java.lang.Integer");
532 ce.setCastType(ic.getType());
534 Local l1 = Jimple.v().newLocal("tmpRef" + (tfr++), ic.getType()); body.getLocals().add(l1);
535 Local l2 = Jimple.v().newLocal("tmpRef" + (tfr++), IntType.v()); body.getLocals().add(l2);
537 Stmt s2 = Jimple.v().newAssignStmt(l1, Jimple.v().newCastExpr(ce.getOp(), ic.getType()));
538 body.getUnits().insertBefore(s2, s);
540 Stmt isNull = Jimple.v().newAssignStmt(l2, IntConstant.v(-1));
541 body.getUnits().insertAfter(isNull, s2);
543 Stmt ifStmt = Jimple.v().newIfStmt(Jimple.v().newEqExpr(l1, NullConstant.v()), s);
544 body.getUnits().insertAfter(ifStmt, isNull);
546 SootMethodRef mr = Scene.v().makeMethodRef(ic, "intValue", new LinkedList(), IntType.v(), false);
548 Jimple.v().newAssignStmt(l2, Jimple.v().newVirtualInvokeExpr(l1, mr, new LinkedList()));
549 body.getUnits().insertAfter(isNotNull, ifStmt);
556 } else if (v instanceof FieldRef) {
557 FieldRef ifr = (FieldRef)v;
558 SootFieldRef fr = ifr.getFieldRef();
560 if (implementsGladiator(fr.declaringClass()) && fr.name().equals("this$0")) {
561 vb.setValue(body.getThisLocal());
562 } else if (implementsGladiator(fr.declaringClass())) {
563 SootClass arena = getArenaForGladiator(fr.declaringClass());
565 vb.setValue(newIFR(body, getSliceForField(fr)));
567 InstanceFieldRef sfr = newIFR(body, getSliceForField(fr));
568 vb.setValue(Jimple.v().newArrayRef(viaLocal(sfr, body, s), ((InstanceFieldRef)ifr).getBase()));
571 if ((t instanceof RefType) && implementsGladiator(((RefType)t).getSootClass())) {
572 SootClass tc = ((RefType)t).getSootClass();
573 SootClass arena = getArenaForGladiator(tc);
574 ifr.setFieldRef(Scene.v().makeFieldRef(arena, fr.name(), IntType.v(), fr.isStatic()));
575 } else if (t instanceof ArrayType) {
576 ArrayType at = (ArrayType)t;
577 Type et = at.getElementType();
578 if (et instanceof RefType && implementsGladiator(((RefType)et).getSootClass()))
579 ifr.setFieldRef(Scene.v().makeFieldRef(fr.declaringClass(),
581 IntType.v().makeArrayType(),