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/string.h | |
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/string.h')
-rw-r--r-- | runtime/mirror/string.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/runtime/mirror/string.h b/runtime/mirror/string.h index 665446c1f4..116ecd1cab 100644 --- a/runtime/mirror/string.h +++ b/runtime/mirror/string.h @@ -118,7 +118,7 @@ class MANAGED String final : public Object { ObjPtr<String> Intern() REQUIRES_SHARED(Locks::mutator_lock_); - template <bool kIsInstrumented> + template <bool kIsInstrumented = true> ALWAYS_INLINE static ObjPtr<String> AllocFromByteArray(Thread* self, int32_t byte_length, Handle<ByteArray> array, @@ -127,7 +127,7 @@ class MANAGED String final : public Object { gc::AllocatorType allocator_type) REQUIRES_SHARED(Locks::mutator_lock_) REQUIRES(!Roles::uninterruptible_); - template <bool kIsInstrumented> + template <bool kIsInstrumented = true> ALWAYS_INLINE static ObjPtr<String> AllocFromCharArray(Thread* self, int32_t count, Handle<CharArray> array, @@ -135,7 +135,7 @@ class MANAGED String final : public Object { gc::AllocatorType allocator_type) REQUIRES_SHARED(Locks::mutator_lock_) REQUIRES(!Roles::uninterruptible_); - template <bool kIsInstrumented> + template <bool kIsInstrumented = true> ALWAYS_INLINE static ObjPtr<String> AllocFromString(Thread* self, int32_t string_length, Handle<String> string, @@ -143,7 +143,7 @@ class MANAGED String final : public Object { gc::AllocatorType allocator_type) REQUIRES_SHARED(Locks::mutator_lock_) REQUIRES(!Roles::uninterruptible_); - template <bool kIsInstrumented> + template <bool kIsInstrumented = true> ALWAYS_INLINE static ObjPtr<String> AllocEmptyString(Thread* self, gc::AllocatorType allocator_type) REQUIRES_SHARED(Locks::mutator_lock_) REQUIRES(!Roles::uninterruptible_); @@ -252,7 +252,7 @@ class MANAGED String final : public Object { SetField32<false, false>(OFFSET_OF_OBJECT_MEMBER(String, hash_code_), new_hash_code); } - template <bool kIsInstrumented, typename PreFenceVisitor> + template <bool kIsInstrumented = true, typename PreFenceVisitor> ALWAYS_INLINE static ObjPtr<String> Alloc(Thread* self, int32_t utf16_length_with_flag, gc::AllocatorType allocator_type, |