diff options
author | Vladimir Marko <vmarko@google.com> | 2019-05-16 16:47:08 +0100 |
---|---|---|
committer | Vladimir Marko <vmarko@google.com> | 2019-05-17 08:10:30 +0000 |
commit | 9b81ac36e161fd993eab17b43b93a96e8c63b5cc (patch) | |
tree | bac59dd8a62ae9f410c707a4086c330b8923a55b /runtime/mirror/array.cc | |
parent | 92ed90ca3897ae7861b22aa12740065152839649 (diff) |
Add default argument kIsInstrumented=true.
kIsInstrumented=false is reserved for use by specialized
entrypoints which are used only when we can ensure that
the code is not instrumented. So add the default argument
to simplify all other callers.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Change-Id: I3419795794fec9a1733ab3ad698b6415dbac679d
Diffstat (limited to 'runtime/mirror/array.cc')
-rw-r--r-- | runtime/mirror/array.cc | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/runtime/mirror/array.cc b/runtime/mirror/array.cc index d42f5a0099..9bff169191 100644 --- a/runtime/mirror/array.cc +++ b/runtime/mirror/array.cc @@ -54,8 +54,8 @@ static ObjPtr<Array> RecursiveCreateMultiArray(Thread* self, Handle<mirror::Class> h_component_type(hs.NewHandle(array_class->GetComponentType())); size_t component_size_shift = h_component_type->GetPrimitiveTypeSizeShift(); gc::AllocatorType allocator_type = Runtime::Current()->GetHeap()->GetCurrentAllocator(); - Handle<Array> new_array(hs.NewHandle(Array::Alloc<true>( - self, array_class.Get(), array_length, component_size_shift, allocator_type))); + Handle<Array> new_array(hs.NewHandle( + Array::Alloc(self, array_class.Get(), array_length, component_size_shift, allocator_type))); if (UNLIKELY(new_array == nullptr)) { CHECK(self->IsExceptionPending()); return nullptr; @@ -122,11 +122,11 @@ ObjPtr<Array> Array::CreateMultiArray(Thread* self, template<typename T> ObjPtr<PrimitiveArray<T>> PrimitiveArray<T>::Alloc(Thread* self, size_t length) { gc::AllocatorType allocator_type = Runtime::Current()->GetHeap()->GetCurrentAllocator(); - ObjPtr<Array> raw_array = Array::Alloc<true>(self, - GetClassRoot<PrimitiveArray<T>>(), - length, - ComponentSizeShiftWidth(sizeof(T)), - allocator_type); + ObjPtr<Array> raw_array = Array::Alloc(self, + GetClassRoot<PrimitiveArray<T>>(), + length, + ComponentSizeShiftWidth(sizeof(T)), + allocator_type); return ObjPtr<PrimitiveArray<T>>::DownCast(raw_array); } @@ -151,7 +151,7 @@ ObjPtr<Array> Array::CopyOf(Thread* self, int32_t new_length) { const auto component_size = klass->GetComponentSize(); const auto component_shift = klass->GetComponentSizeShift(); ObjPtr<Array> new_array = - Alloc<true>(self, klass, new_length, component_shift, allocator_type); // Invalidates klass. + Alloc(self, klass, new_length, component_shift, allocator_type); // Invalidates klass. if (LIKELY(new_array != nullptr)) { memcpy(new_array->GetRawData(component_size, 0), h_this->GetRawData(component_size, 0), |