Home
last modified time | relevance | path

Searched refs:Array (Results 1 – 25 of 58) sorted by relevance

123

/art/test/045-reflect-array/src/
DMain.java5 import java.lang.reflect.Array;
27 intArray = Array.newInstance(Integer.TYPE, 2); in testSingleInt()
31 Array.setInt(intArray, 1, 6); in testSingleInt()
33 if (Array.getInt(intArray, 0) != 5) in testSingleInt()
42 Array.setInt(intArray, 2, 27); in testSingleInt()
45 if (array.length != Array.getLength(intArray) || in testSingleInt()
54 Array.set(intArray, 0, x123); in testSingleInt()
55 Array.set(intArray, 1, x456); in testSingleInt()
56 if (!Array.get(intArray, 0).equals(x123) || !Array.get(intArray, 1).equals(x456)) { in testSingleInt()
66 intArray = Array.newInstance(Integer.TYPE, 0); in testSingleInt()
[all …]
/art/runtime/mirror/
Darray.cc43 static Array* RecursiveCreateMultiArray(Thread* self, in RecursiveCreateMultiArray()
49 Handle<Array> new_array( in RecursiveCreateMultiArray()
51 Array::Alloc<true>(self, array_class.Get(), array_length, array_class->GetComponentSize(), in RecursiveCreateMultiArray()
62 Array* sub_array = RecursiveCreateMultiArray(self, h_component_type, in RecursiveCreateMultiArray()
69 new_array->AsObjectArray<Array>()->Set<false, false>(i, sub_array); in RecursiveCreateMultiArray()
75 Array* Array::CreateMultiArray(Thread* self, Handle<Class> element_class, in CreateMultiArray()
112 Array* new_array = RecursiveCreateMultiArray(self, array_class, 0, dimensions); in CreateMultiArray()
119 void Array::ThrowArrayIndexOutOfBoundsException(int32_t index) { in ThrowArrayIndexOutOfBoundsException()
123 void Array::ThrowArrayStoreException(Object* object) { in ThrowArrayStoreException()
Darray.h31 class MANAGED Array : public Object {
40 static Array* Alloc(Thread* self, Class* array_class, int32_t component_count,
45 static Array* CreateMultiArray(Thread* self, Handle<Class> element_class,
54 return GetField32<kVerifyFlags>(OFFSET_OF_OBJECT_MEMBER(Array, length_)); in GetLength()
61 SetField32<false, false, kVerifyNone>(OFFSET_OF_OBJECT_MEMBER(Array, length_), length); in SetLength()
65 return OFFSET_OF_OBJECT_MEMBER(Array, length_); in LengthOffset()
70 return OFFSET_OF_OBJECT_MEMBER(Array, first_element_); in DataOffset()
73 return MemberOffset(OFFSETOF_MEMBER(Array, first_element_) + 4); in DataOffset()
107 DISALLOW_IMPLICIT_CONSTRUCTORS(Array);
111 class MANAGED PrimitiveArray : public Array {
Darray-inl.h30 inline uint32_t Array::ClassSize() { in ClassSize()
36 inline size_t Array::SizeOf() { in SizeOf()
49 inline bool Array::CheckIsValidIndex(int32_t index) { in CheckIsValidIndex()
65 size_t header_size = Array::DataOffset(component_size).SizeValue(); in ComputeArraySize()
91 Array* array = down_cast<Array*>(obj); in operator()
113 Array* array = down_cast<Array*>(obj); in operator()
133 inline Array* Array::Alloc(Thread* self, Class* array_class, int32_t component_count, in Alloc()
142 Array* result; in Alloc()
145 result = down_cast<Array*>( in Alloc()
151 result = down_cast<Array*>( in Alloc()
[all …]
Dobject_test.cc84 EXPECT_EQ(ARRAY_LENGTH_OFFSET, Array::LengthOffset().Int32Value()); in TEST_F()
85 …EXPECT_EQ(OBJECT_ARRAY_DATA_OFFSET, Array::DataOffset(sizeof(HeapReference<Object>)).Int32Value()); in TEST_F()
90 EXPECT_EQ(STRING_DATA_OFFSET, Array::DataOffset(sizeof(uint16_t)).Int32Value()); in TEST_F()
168 Handle<Array> a( in TEST_F()
169 hs.NewHandle(Array::Alloc<true>(soa.Self(), c, 1, c->GetComponentSize(), in TEST_F()
175 a.Assign(Array::Alloc<true>(soa.Self(), c, 1, c->GetComponentSize(), in TEST_F()
181 a.Assign(Array::Alloc<true>(soa.Self(), c, 1, c->GetComponentSize(), in TEST_F()
191 Handle<Array> a( in TEST_F()
192 hs.NewHandle(Array::Alloc<true>(soa.Self(), c, 1, c->GetComponentSize(), in TEST_F()
198 a.Assign(Array::Alloc<true>(soa.Self(), c, 2, c->GetComponentSize(), in TEST_F()
[all …]
Dobject_array.h26 class MANAGED ObjectArray: public Array {
30 return Array::ClassSize(); in ClassSize()
/art/runtime/native/
Djava_lang_reflect_Array.cc41 mirror::Array* new_array = mirror::Array::CreateMultiArray(soa.Self(), element_class, in Array_createMultiArray()
62 mirror::Array* new_array = mirror::Array::Alloc<true>(soa.Self(), array_class, length, in Array_createObjectArray()
69 NATIVE_METHOD(Array, createMultiArray, "!(Ljava/lang/Class;[I)Ljava/lang/Object;"),
70 NATIVE_METHOD(Array, createObjectArray, "!(Ljava/lang/Class;I)Ljava/lang/Object;"),
Djava_lang_System.cc72 mirror::Array* srcArray = srcObject->AsArray(); in System_arraycopy()
73 mirror::Array* dstArray = dstObject->AsArray(); in System_arraycopy()
152 inline T* AsPrimitiveArray(mirror::Array* array) { in AsPrimitiveArray()
163 mirror::Array* srcArray = srcObject->AsArray(); in System_arraycopyTUnchecked()
164 mirror::Array* dstArray = dstObject->AsArray(); in System_arraycopyTUnchecked()
Ddalvik_system_VMRuntime.cc78 mirror::Array* result = mirror::Array::Alloc<true>(soa.Self(), array_class, length, in VMRuntime_newNonMovableArray()
102 mirror::Array* result = mirror::Array::Alloc<true>(soa.Self(), array_class, length, in VMRuntime_newUnpaddedArray()
113 mirror::Array* array = soa.Decode<mirror::Array*>(javaArray); in VMRuntime_addressOf()
/art/test/003-omnibus-opcodes/
Dexpected.txt51 Array check...
52 Array.checkRange32
53 Array.checkRange64
54 Array.checkNegAlloc
/art/runtime/
Dtransaction.h33 class Array; variable
56 void RecordWriteArray(mirror::Array* array, size_t index, uint64_t value)
121 void Undo(mirror::Array* obj) SHARED_LOCKS_REQUIRED(Locks::mutator_lock_);
128 void UndoArrayWrite(mirror::Array* array, Primitive::Type array_type, size_t index,
189 std::map<mirror::Array*, ArrayLog> array_logs_ GUARDED_BY(log_lock_);
Dtransaction.cc84 void Transaction::RecordWriteArray(mirror::Array* array, size_t index, uint64_t value) { in RecordWriteArray()
195 typedef std::pair<mirror::Array*, mirror::Array*> ArrayPair; in VisitArrayLogs()
199 mirror::Array* old_root = it.first; in VisitArrayLogs()
201 mirror::Array* new_root = old_root; in VisitArrayLogs()
210 mirror::Array* old_root = pair.first; in VisitArrayLogs()
211 mirror::Array* new_root = pair.second; in VisitArrayLogs()
269 field_offset.Uint32Value() == mirror::Array::LengthOffset().Uint32Value()) { in Undo()
377 void Transaction::ArrayLog::Undo(mirror::Array* array) { in Undo()
386 void Transaction::ArrayLog::UndoArrayWrite(mirror::Array* array, Primitive::Type array_type, in UndoArrayWrite()
/art/runtime/entrypoints/
Dentrypoint_utils.h33 class Array; variable
94 ALWAYS_INLINE static inline mirror::Array* AllocArrayFromCode(uint32_t type_idx,
102 ALWAYS_INLINE static inline mirror::Array* AllocArrayFromCodeResolved(mirror::Class* klass,
109 extern mirror::Array* CheckAndAllocArrayFromCode(uint32_t type_idx, mirror::ArtMethod* method,
115 extern mirror::Array* CheckAndAllocArrayFromCodeInstrumented(uint32_t type_idx,
Dentrypoint_utils.cc80 mirror::Array* CheckAndAllocArrayFromCode(uint32_t type_idx, mirror::ArtMethod* referrer, in CheckAndAllocArrayFromCode()
93 return mirror::Array::Alloc<false>(self, klass, component_count, klass->GetComponentSize(), in CheckAndAllocArrayFromCode()
98 mirror::Array* CheckAndAllocArrayFromCodeInstrumented(uint32_t type_idx, in CheckAndAllocArrayFromCodeInstrumented()
112 return mirror::Array::Alloc<true>(self, klass, component_count, klass->GetComponentSize(), in CheckAndAllocArrayFromCodeInstrumented()
Dentrypoint_utils-inl.h212 static inline mirror::Array* AllocArrayFromCode(uint32_t type_idx, in AllocArrayFromCode()
225 return mirror::Array::Alloc<kInstrumented>(self, klass, component_count, in AllocArrayFromCode()
229 return mirror::Array::Alloc<kInstrumented>(self, klass, component_count, in AllocArrayFromCode()
234 static inline mirror::Array* AllocArrayFromCodeResolved(mirror::Class* klass, in AllocArrayFromCodeResolved()
253 return mirror::Array::Alloc<kInstrumented>(self, klass, component_count, in AllocArrayFromCodeResolved()
/art/runtime/entrypoints/quick/
Dquick_alloc_entrypoints.cc57 extern "C" mirror::Array* artAllocArrayFromCode##suffix##suffix2( \
65 extern "C" mirror::Array* artAllocArrayFromCodeResolved##suffix##suffix2( \
73 extern "C" mirror::Array* artAllocArrayFromCodeWithAccessCheck##suffix##suffix2( \
81 extern "C" mirror::Array* artCheckAndAllocArrayFromCode##suffix##suffix2( \
92 extern "C" mirror::Array* artCheckAndAllocArrayFromCodeWithAccessCheck##suffix##suffix2( \
Dquick_fillarray_entrypoints.cc40 extern "C" int artHandleFillArrayDataFromCode(mirror::Array* array, in artHandleFillArrayDataFromCode()
/art/test/004-UnsafeTest/
Dunsafe_test.cc30 return mirror::Array::DataOffset( in Java_Main_vmArrayBaseOffset()
/art/test/003-omnibus-opcodes/src/
DMain.java46 Array.run(); in run()
/art/runtime/entrypoints/portable/
Dportable_fillarray_entrypoints.cc26 mirror::Array* array, in art_portable_fill_array_data_from_code()
/art/compiler/dex/quick/mips/
Dint_mips.cc488 int len_offset = mirror::Array::LengthOffset().Int32Value(); in GenArrayGet()
497 data_offset = mirror::Array::DataOffset(sizeof(int64_t)).Int32Value(); in GenArrayGet()
499 data_offset = mirror::Array::DataOffset(sizeof(int32_t)).Int32Value(); in GenArrayGet()
557 int len_offset = mirror::Array::LengthOffset().Int32Value(); in GenArrayPut()
561 data_offset = mirror::Array::DataOffset(sizeof(int64_t)).Int32Value(); in GenArrayPut()
563 data_offset = mirror::Array::DataOffset(sizeof(int32_t)).Int32Value(); in GenArrayPut()
/art/compiler/optimizing/
Dcode_generator_x86_64.cc724 size_t index_in_cache = mirror::Array::DataOffset(heap_reference_size).SizeValue() + in VisitInvokeStatic()
1094 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint8_t)).Uint32Value(); in VisitArrayGet()
1106 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int8_t)).Uint32Value(); in VisitArrayGet()
1118 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int16_t)).Uint32Value(); in VisitArrayGet()
1130 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint16_t)).Uint32Value(); in VisitArrayGet()
1144 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int32_t)).Uint32Value(); in VisitArrayGet()
1156 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int64_t)).Uint32Value(); in VisitArrayGet()
1202 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint8_t)).Uint32Value(); in VisitArraySet()
1215 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint16_t)).Uint32Value(); in VisitArraySet()
1227 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int32_t)).Uint32Value(); in VisitArraySet()
[all …]
Dcode_generator_arm.cc840 size_t index_in_cache = mirror::Array::DataOffset(heap_reference_size).Int32Value() + in VisitInvokeStatic()
1254 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint8_t)).Uint32Value(); in VisitArrayGet()
1267 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int8_t)).Uint32Value(); in VisitArrayGet()
1280 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int16_t)).Uint32Value(); in VisitArrayGet()
1293 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint16_t)).Uint32Value(); in VisitArrayGet()
1308 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int32_t)).Uint32Value(); in VisitArrayGet()
1321 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int64_t)).Uint32Value(); in VisitArrayGet()
1368 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint8_t)).Uint32Value(); in VisitArraySet()
1382 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint16_t)).Uint32Value(); in VisitArraySet()
1395 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int32_t)).Uint32Value(); in VisitArraySet()
[all …]
Dcode_generator_x86.cc782 size_t index_in_cache = mirror::Array::DataOffset(heap_reference_size).Int32Value() + in VisitInvokeStatic()
1249 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint8_t)).Uint32Value(); in VisitArrayGet()
1261 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int8_t)).Uint32Value(); in VisitArrayGet()
1273 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int16_t)).Uint32Value(); in VisitArrayGet()
1285 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint16_t)).Uint32Value(); in VisitArrayGet()
1298 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int32_t)).Uint32Value(); in VisitArrayGet()
1310 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int64_t)).Uint32Value(); in VisitArrayGet()
1366 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint8_t)).Uint32Value(); in VisitArraySet()
1379 uint32_t data_offset = mirror::Array::DataOffset(sizeof(uint16_t)).Uint32Value(); in VisitArraySet()
1391 uint32_t data_offset = mirror::Array::DataOffset(sizeof(int32_t)).Uint32Value(); in VisitArraySet()
[all …]
/art/test/201-built-in-exception-detail-messages/src/
DMain.java17 import java.lang.reflect.Array;
251 return Array.newInstance(c, 1); in makeArray()

123