Home
last modified time | relevance | path

Searched refs:i (Results 1 – 25 of 1190) sorted by relevance

12345678910>>...48

/libcore/benchmarks/src/benchmarks/
DInvokeInterface.java28 for (int i = 0; i < nreps; i++) { in timeCall0Concrete()
35 for (int i = 0; i < nreps; i++) { in timeCall0Interface()
42 for (int i = 0; i < nreps; i++) { in timeCall1Interface()
49 for (int i = 0; i < nreps; i++) { in timeCall2Interface()
56 for (int i = 0; i < nreps; i++) { in timeCall3Interface()
63 for (int i = 0; i < nreps; i++) { in timeCall4Interface()
70 for (int i = 0; i < nreps; i++) { in timeCall5Interface()
77 for (int i = 0; i < nreps; i++) { in timeCall6Interface()
84 for (int i = 0; i < nreps; i++) { in timeCall7Interface()
91 for (int i = 0; i < nreps; i++) { in timeCall8Interface()
[all …]
DDeepArrayOpsBenchmark.java36 for (int i = 0; i < arrayLength; i += 13) { in setUp()
37 array[i] = new IntWrapper(i); in setUp()
38 array2[i] = new IntWrapper(i); in setUp()
40 array[i + 1] = new16ElementObjectarray(); in setUp()
41 array2[i + 1] = new16ElementObjectarray(); in setUp()
43 array[i + 2] = new boolean[16]; in setUp()
44 array2[i + 2] = new boolean[16]; in setUp()
46 array[i + 3] = new byte[16]; in setUp()
47 array2[i + 3] = new byte[16]; in setUp()
49 array[i + 4] = new char[16]; in setUp()
[all …]
DMethodInvocationBenchmark.java36 for (int i = 0; i < reps; ++i) { in timeInternalGetter()
44 for (int i = 0; i < reps; ++i) { in timeInternalFieldAccess()
71 for (int i = 0; i < reps; ++i) { in timeStringLength()
79 for (int i = 0; i < reps; ++i) { in timeEmptyStatic()
86 for (int i = 0; i < reps; ++i) { in timeEmptyVirtual()
93 for (int i = 0; i < reps; ++i) { in timeEmptyInterface()
99 private int i; field in MethodInvocationBenchmark.Inner
100 private void privateMethod() { ++i; } in privateMethod()
101 protected void protectedMethod() { ++i; } in protectedMethod()
102 public void publicMethod() { ++i; } in publicMethod()
[all …]
/libcore/luni/src/main/java/java/math/
DLogical.java47 int i; in not() local
52 for (i = 0; val.digits[i] == -1; i++) { in not()
56 for (i = 0; (i < val.numberLength) && (val.digits[i] == -1); i++) { in not()
59 if (i == val.numberLength) { in not()
60 resDigits[i] = 1; in not()
61 return new BigInteger(-val.sign, i + 1, resDigits); in not()
67 for (i = 0; val.digits[i] == 0; i++) { in not()
68 resDigits[i] = -1; in not()
73 resDigits[i] = val.digits[i] + val.sign; in not()
75 for (i++; i < val.numberLength; i++) { in not()
[all …]
DBitLevel.java50 int i = val.getFirstNonzeroDigit(); in bitLength() local
52 if (i == val.numberLength - 1) { in bitLength()
70 int i = val.getFirstNonzeroDigit(); in bitCount() local
72 for ( ; i < val.numberLength; i++) { in bitCount()
73 bCount += Integer.bitCount(val.digits[i]); in bitCount()
77 bCount += Integer.bitCount(-val.digits[i]); in bitCount()
78 for (i++; i < val.numberLength; i++) { in bitCount()
79 bCount += Integer.bitCount(~val.digits[i]); in bitCount()
106 int i; in nonZeroDroppedBits() local
108 for (i = 0; (i < intCount) && (digits[i] == 0); i++) { in nonZeroDroppedBits()
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/org/xml/sax/
DInputSourceTest.java31 InputSource i = new InputSource(); in testInputSource() local
33 assertNull(i.getByteStream()); in testInputSource()
34 assertNull(i.getCharacterStream()); in testInputSource()
35 assertNull(i.getEncoding()); in testInputSource()
36 assertNull(i.getPublicId()); in testInputSource()
37 assertNull(i.getSystemId()); in testInputSource()
41 InputSource i = new InputSource("Foo"); in testInputSourceString() local
43 assertNull(i.getByteStream()); in testInputSourceString()
44 assertNull(i.getCharacterStream()); in testInputSourceString()
45 assertNull(i.getEncoding()); in testInputSourceString()
[all …]
/libcore/ojluni/src/main/java/java/lang/
DInteger.java130 public static String toString(int i, int radix) { in toString() argument
137 return toString(i); in toString()
141 boolean negative = (i < 0); in toString()
145 i = -i; in toString()
148 while (i <= -radix) { in toString()
149 int q = i / radix; in toString()
150 buf[charPos--] = digits[radix * q - i]; in toString()
151 i = q; in toString()
153 buf[charPos] = digits[-i]; in toString()
196 public static String toHexString(int i) { in toHexString() argument
[all …]
DLong.java116 public static String toString(long i, int radix) { in toString() argument
120 return toString(i); in toString()
123 boolean negative = (i < 0); in toString()
126 i = -i; in toString()
129 while (i <= -radix) { in toString()
130 buf[charPos--] = Integer.digits[(int)(-(i % radix))]; in toString()
131 i = i / radix; in toString()
133 buf[charPos] = Integer.digits[(int)(-i)]; in toString()
177 public static String toHexString(long i) { in toHexString() argument
178 return toUnsignedString(i, 4); in toHexString()
[all …]
/libcore/jsr166-tests/src/test/java/jsr166/
DAtomicLongArrayTest.java33 for (int i = 0; i < SIZE; i++) in testConstructor()
34 assertEquals(0, aa.get(i)); in testConstructor()
55 for (int i = 0; i < a.length; i++) in testConstructor2()
56 assertEquals(a[i], aa.get(i)); in testConstructor2()
101 for (int i = 0; i < SIZE; i++) { in testGetSet()
102 aa.set(i, 1); in testGetSet()
103 assertEquals(1, aa.get(i)); in testGetSet()
104 aa.set(i, 2); in testGetSet()
105 assertEquals(2, aa.get(i)); in testGetSet()
106 aa.set(i, -3); in testGetSet()
[all …]
DAtomicIntegerArrayTest.java34 for (int i = 0; i < SIZE; i++) in testConstructor()
35 assertEquals(0, aa.get(i)); in testConstructor()
56 for (int i = 0; i < a.length; i++) in testConstructor2()
57 assertEquals(a[i], aa.get(i)); in testConstructor2()
102 for (int i = 0; i < SIZE; i++) { in testGetSet()
103 aa.set(i, 1); in testGetSet()
104 assertEquals(1, aa.get(i)); in testGetSet()
105 aa.set(i, 2); in testGetSet()
106 assertEquals(2, aa.get(i)); in testGetSet()
107 aa.set(i, -3); in testGetSet()
[all …]
DPriorityQueueTest.java46 for (int i = n - 1; i >= 0; i -= 2) in populatedQueue()
47 assertTrue(q.offer(new Integer(i))); in populatedQueue()
48 for (int i = (n & 1); i < n; i += 2) in populatedQueue()
49 assertTrue(q.offer(new Integer(i))); in populatedQueue()
97 for (int i = 0; i < SIZE - 1; ++i) in testConstructor5()
98 ints[i] = new Integer(i); in testConstructor5()
110 for (int i = 0; i < SIZE; ++i) in testConstructor6()
111 ints[i] = new Integer(i); in testConstructor6()
113 for (int i = 0; i < SIZE; ++i) in testConstructor6()
114 assertEquals(ints[i], q.poll()); in testConstructor6()
[all …]
DLinkedListTest.java38 for (int i = 0; i < n; ++i) in populatedQueue()
39 assertTrue(q.offer(new Integer(i))); in populatedQueue()
67 for (int i = 0; i < SIZE; ++i) in testConstructor6()
68 ints[i] = i; in testConstructor6()
70 for (int i = 0; i < SIZE; ++i) in testConstructor6()
71 assertEquals(ints[i], q.poll()); in testConstructor6()
93 for (int i = 0; i < SIZE; ++i) { in testSize()
94 assertEquals(SIZE - i, q.size()); in testSize()
97 for (int i = 0; i < SIZE; ++i) { in testSize()
98 assertEquals(i, q.size()); in testSize()
[all …]
DAtomicReferenceArrayTest.java33 for (int i = 0; i < SIZE; i++) { in testConstructor()
34 assertNull(aa.get(i)); in testConstructor()
56 for (int i = 0; i < a.length; i++) in testConstructor2()
57 assertEquals(a[i], aa.get(i)); in testConstructor2()
67 for (int i = 0; i < a.length; i++) { in testConstructorSubClassArray()
68 assertSame(a[i], aa.get(i)); in testConstructorSubClassArray()
69 Long x = Long.valueOf(i); in testConstructorSubClassArray()
70 aa.set(i, x); in testConstructorSubClassArray()
71 assertSame(x, aa.get(i)); in testConstructorSubClassArray()
109 for (int i = 0; i < SIZE; i++) { in testGetSet()
[all …]
DPriorityBlockingQueueTest.java72 for (int i = n - 1; i >= 0; i -= 2) in populatedQueue()
73 assertTrue(q.offer(new Integer(i))); in populatedQueue()
74 for (int i = (n & 1); i < n; i += 2) in populatedQueue()
75 assertTrue(q.offer(new Integer(i))); in populatedQueue()
126 for (int i = 0; i < SIZE - 1; ++i) in testConstructor5()
127 ints[i] = i; in testConstructor5()
140 for (int i = 0; i < SIZE; ++i) in testConstructor6()
141 ints[i] = i; in testConstructor6()
143 for (int i = 0; i < SIZE; ++i) in testConstructor6()
144 assertEquals(ints[i], q.poll()); in testConstructor6()
[all …]
/libcore/benchmarks/src/benchmarks/regression/
DIntegerBenchmark.java22 for (int i = 0; i < reps; ++i) { in timeLongSignumBranch()
23 t += signum1(-i); in timeLongSignumBranch()
25 t += signum1(i); in timeLongSignumBranch()
32 for (int i = 0; i < reps; ++i) { in timeLongSignumBranchFree()
33 t += signum2(-i); in timeLongSignumBranchFree()
35 t += signum2(i); in timeLongSignumBranchFree()
50 for (int i = 0; i < reps; ++i) { in timeLongBitCount_BitSet()
51 t += pop((long) i); in timeLongBitCount_BitSet()
76 for (int i = 0; i < reps; ++i) { in timeLongBitCount_2Int()
77 t += pop2((long) i); in timeLongBitCount_2Int()
[all …]
DCharacterBenchmark.java51 for (int i = 0; i < 65536; ++i) { in CharacterSet()
52 chars[i] = (char) (i % size); in CharacterSet()
61 for (int i = 0; i < reps; ++i) { in timeIsSpace()
67 for (int i = 0; i < reps; ++i) { in timeIsSpace()
78 for (int i = 0; i < reps; ++i) { in timeDigit()
84 for (int i = 0; i < reps; ++i) { in timeDigit()
94 for (int i = 0; i < reps; ++i) { in timeGetNumericValue()
100 for (int i = 0; i < reps; ++i) { in timeGetNumericValue()
110 for (int i = 0; i < reps; ++i) { in timeIsDigit()
116 for (int i = 0; i < reps; ++i) { in timeIsDigit()
[all …]
DAnnotatedElementBenchmark.java42 for (int i = 0; i < reps; i++) { in timeGetTypeAnnotations()
48 for (int i = 0; i < reps; i++) { in timeGetFieldAnnotations()
54 for (int i = 0; i < reps; i++) { in timeGetMethodAnnotations()
60 for (int i = 0; i < reps; i++) { in timeGetParameterAnnotations()
66 for (int i = 0; i < reps; i++) { in timeGetTypeAnnotation()
72 for (int i = 0; i < reps; i++) { in timeGetFieldAnnotation()
78 for (int i = 0; i < reps; i++) { in timeGetMethodAnnotation()
84 for (int i = 0; i < reps; i++) { in timeIsTypeAnnotationPresent()
90 for (int i = 0; i < reps; i++) { in timeIsFieldAnnotationPresent()
96 for (int i = 0; i < reps; i++) { in timeIsMethodAnnotationPresent()
[all …]
DExpensiveObjectsBenchmark.java33 for (int i = 0; i < reps; ++i) { in timeNewDateFormatTimeInstance()
41 for (int i = 0; i < reps; ++i) { in timeClonedDateFormatTimeInstance()
48 for (int i = 0; i < reps; ++i) { in timeReusedDateFormatTimeInstance()
56 for (int i = 0; i < reps; ++i) { in timeNewCollator()
63 for (int i = 0; i < reps; ++i) { in timeClonedCollator()
69 for (int i = 0; i < reps; ++i) { in timeNewDateFormatSymbols()
76 for (int i = 0; i < reps; ++i) { in timeClonedDateFormatSymbols()
82 for (int i = 0; i < reps; ++i) { in timeNewDecimalFormatSymbols()
89 for (int i = 0; i < reps; ++i) { in timeClonedDecimalFormatSymbols()
95 for (int i = 0; i < reps; ++i) { in timeNewNumberFormat()
[all …]
DIntConstantMultiplicationBenchmark.java22 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByConstant6()
29 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByConstant7()
36 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByConstant8()
43 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByConstant8_Shift()
50 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByConstant10()
57 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByConstant10_Shift()
64 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByConstant2047()
71 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByConstant2048()
78 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByConstant2049()
86 for (int i = 0; i < reps; ++i) { in timeMultiplyIntByVariable10()
[all …]
DIntConstantDivisionBenchmark.java22 for (int i = 0; i < reps; ++i) { in timeDivideIntByConstant2()
29 for (int i = 0; i < reps; ++i) { in timeDivideIntByConstant8()
36 for (int i = 0; i < reps; ++i) { in timeDivideIntByConstant10()
43 for (int i = 0; i < reps; ++i) { in timeDivideIntByConstant100()
50 for (int i = 0; i < reps; ++i) { in timeDivideIntByConstant100_HandOptimized()
57 for (int i = 0; i < reps; ++i) { in timeDivideIntByConstant2048()
65 for (int i = 0; i < reps; ++i) { in timeDivideIntByVariable2()
73 for (int i = 0; i < reps; ++i) { in timeDivideIntByVariable10()
/libcore/luni/src/test/java/dalvik/system/
DJniTest.java98 for(int i = 0; i < 16; i++) { in testPassingObjectReferences()
99 a[i] = literal; in testPassingObjectReferences()
101 for(int i = 0; i < 16; i++) { in testPassingObjectReferences()
102 assertEquals(a[i], returnObjectArgFrom16(i, a[0], a[1], a[2], a[3], a[4], in testPassingObjectReferences()
109 for(int i = 0; i < 16; i++) { in testPassingObjectReferences()
110 a[i] = literals[(i + j) % literals.length]; in testPassingObjectReferences()
112 for(int i = 0; i < 16; i++) { in testPassingObjectReferences()
113 assertEquals(a[i], returnObjectArgFrom16(i, a[0], a[1], a[2], a[3], a[4], in testPassingObjectReferences()
126 for(int i = 0; i < 16; i++) { in testPassingBooleans()
127 a[i] = literal; in testPassingBooleans()
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/math/
DBigIntegerConstructorsTest.java56 for(int i = 0; i < resBytes.length; i++) { in testConstructorBytesPositive1()
57 assertTrue(resBytes[i] == rBytes[i]); in testConstructorBytesPositive1()
72 for(int i = 0; i < resBytes.length; i++) { in testConstructorBytesPositive2()
73 assertTrue(resBytes[i] == rBytes[i]); in testConstructorBytesPositive2()
88 for(int i = 0; i < resBytes.length; i++) { in testConstructorBytesPositive3()
89 assertTrue(resBytes[i] == rBytes[i]); in testConstructorBytesPositive3()
104 for(int i = 0; i < resBytes.length; i++) { in testConstructorBytesPositive()
105 assertTrue(resBytes[i] == rBytes[i]); in testConstructorBytesPositive()
120 for(int i = 0; i < resBytes.length; i++) { in testConstructorBytesNegative1()
121 assertTrue(resBytes[i] == rBytes[i]); in testConstructorBytesNegative1()
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/
DBitSetTest.java92 for (int i = 0; i < 8; i++) { in test_clear()
93 assertTrue("Clear didn't clear bit " + i, !eightbs.get(i)); in test_clear()
112 for (int i = 0; i < 7; i++) { in test_clearI()
113 assertTrue("Clear cleared incorrect bits", eightbs.get(i)); in test_clearI()
165 for (int i = 0; i < 20; i++) { in test_clearII()
166 bitset.set(i); in test_clearII()
178 for (int i = 0; i < 7; i++) { in test_clearII()
179 if (i == 5) { in test_clearII()
180 assertFalse("Shouldn't have flipped bit " + i, bs.get(i)); in test_clearII()
182 assertTrue("Shouldn't have cleared bit " + i, bs.get(i)); in test_clearII()
[all …]
/libcore/ojluni/src/main/java/sun/security/x509/
DIPAddressName.java207 for (int i = 0; i < prefixLen; i++) in parseIPv6()
208 bitArray.set(i, true); in parseIPv6()
212 for (int i = 0; i < MASKSIZE; i++) in parseIPv6()
213 address[MASKSIZE+i] = maskArray[i]; in parseIPv6()
279 for (int i=16; i < 32; i++) in getName()
280 maskBytes[i-16] = address[i]; in getName()
283 int i=0; in getName() local
284 for (; i < 16*8; i++) { in getName()
285 if (!ba.get(i)) in getName()
288 name = name + "/" + i; in getName()
[all …]
/libcore/ojluni/src/main/java/sun/misc/
DFDBigInt.java67 int i = nd0; in FDBigInt() local
70 while ( i < limit ){ in FDBigInt()
71 int ilim = i+5; in FDBigInt()
72 v = (int)digit[i++]-(int)'0'; in FDBigInt()
73 while( i <ilim ){ in FDBigInt()
74 v = 10*v + (int)digit[i++]-(int)'0'; in FDBigInt()
80 while ( i < nd ){ in FDBigInt()
81 v = 10*v + (int)digit[i++]-(int)'0'; in FDBigInt()
204 for( int i=0; i < nWords; i++ ) { in mult()
205 p += v * ((long)data[i]&0xffffffffL); in mult()
[all …]

12345678910>>...48