From 6be9ae8aa1d3b164f3953dbc1cb7f0f1c1976d9b Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Sun, 16 Feb 2020 13:05:12 +0200 Subject: inline some acquire/release calls because these are all on the hot path, and in the best case, with enough inlining, the compiler can skip the call altogether and just do a locked CMPXHG instruction Change-Id: I099d6385f602e40e1767f9f1002b7514ecf436e5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88775 Tested-by: Jenkins Reviewed-by: Noel Grandin --- include/comphelper/weak.hxx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'include/comphelper/weak.hxx') diff --git a/include/comphelper/weak.hxx b/include/comphelper/weak.hxx index f094225cb32c..f53ea8d7f562 100644 --- a/include/comphelper/weak.hxx +++ b/include/comphelper/weak.hxx @@ -46,8 +46,11 @@ public: OWeakTypeObject & operator =(OWeakTypeObject &&) = default; virtual css::uno::Any SAL_CALL queryInterface(const css::uno::Type & rType ) override; - virtual void SAL_CALL acquire() throw () override; - virtual void SAL_CALL release() throw () override; + virtual void SAL_CALL acquire() throw () override + { ::cppu::OWeakObject::acquire(); } + virtual void SAL_CALL release() throw () override + { ::cppu::OWeakObject::release(); } + virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes( ) override; virtual css::uno::Sequence< ::sal_Int8 > SAL_CALL getImplementationId( ) override; -- cgit