summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sal/rtl/strimp.hxx10
-rw-r--r--sal/rtl/ustring.cxx3
2 files changed, 13 insertions, 0 deletions
diff --git a/sal/rtl/strimp.hxx b/sal/rtl/strimp.hxx
index 544d5796560f..997d72c4c814 100644
--- a/sal/rtl/strimp.hxx
+++ b/sal/rtl/strimp.hxx
@@ -56,15 +56,25 @@ sal_Bool rtl_ImplIsWhitespace( sal_Unicode c );
# define PROBE_NAME(n,b) PROBE_SNAME(n,b)
# define PROBE_NEW PROBE_NAME (new_string,RTL_LOG_STRING_BITS)
# define PROBE_DEL PROBE_NAME (delete_string,RTL_LOG_STRING_BITS)
+# define PROBE_INTERN_NEW PROBE_NAME (new_string_intern,RTL_LOG_STRING_BITS)
+# define PROBE_INTERN_DEL PROBE_NAME (delete_string_intern,RTL_LOG_STRING_BITS)
# define RTL_LOG_STRING_NEW(s) \
DTRACE_PROBE4(libreoffice, PROBE_NEW, s, \
(s)->refCount, (s)->length, (s)->buffer)
# define RTL_LOG_STRING_DELETE(s) \
DTRACE_PROBE4(libreoffice, PROBE_DEL, s, \
(s)->refCount, (s)->length, (s)->buffer)
+# define RTL_LOG_STRING_INTERN_NEW(s,o) \
+ DTRACE_PROBE5(libreoffice, PROBE_INTERN_NEW, s, \
+ (s)->refCount, (s)->length, (s)->buffer, o)
+# define RTL_LOG_STRING_INTERN_DELETE(s) \
+ DTRACE_PROBE4(libreoffice, PROBE_INTERN_DEL, s, \
+ (s)->refCount, (s)->length, (s)->buffer)
#else
# define RTL_LOG_STRING_NEW(s)
# define RTL_LOG_STRING_DELETE(s)
+# define RTL_LOG_STRING_INTERN_NEW(s,o)
+# define RTL_LOG_STRING_INTERN_DELETE(s)
#endif /* USE_SDT_PROBES */
#endif /* INCLUDED_RTL_SOURCE_STRIMP_HXX */
diff --git a/sal/rtl/ustring.cxx b/sal/rtl/ustring.cxx
index 1c02dfc9d041..abf9db7b388b 100644
--- a/sal/rtl/ustring.cxx
+++ b/sal/rtl/ustring.cxx
@@ -817,6 +817,8 @@ static void rtl_ustring_intern_internal( rtl_uString ** newStr,
osl_releaseMutex( pPoolMutex );
+ RTL_LOG_STRING_INTERN_NEW(*newStr, str);
+
if( can_return && *newStr != str )
{ /* we dupped, then found a match */
rtl_freeMemory( str );
@@ -947,6 +949,7 @@ internRelease (rtl_uString *pThis)
if ( SAL_STRING_REFCOUNT(
osl_atomic_decrement( &(pThis->refCount) ) ) == 0)
{
+ RTL_LOG_STRING_INTERN_DELETE(pThis);
pPoolMutex = getInternMutex();
osl_acquireMutex( pPoolMutex );