[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-24 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

David Tardon dtar...@redhat.com changed:

   What|Removed |Added

 Whiteboard|EasyHack DifficultyBeginner |EasyHack
   |SkillCpp TopicCleanup   |DifficultyInteresting
   |target:4.4.0|SkillCpp TopicCleanup
   ||target:4.4.0

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-23 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

--- Comment #5 from David Tardon dtar...@redhat.com ---
(In reply to comment #4)
 Fair cop - but for very high frequency things like the OOXML attributes /
 values etc. [ the ones tackled so far are ~never used sadly ;-] - I want
 intrusive pointers for 2x reasons:
 
 a) to avoid allocations and
 b) to avoid atomic interlock operations on ref counting
 
 We should never be allocating / ref / unref'ing one of two boolean values
 eg. ;-)

So I would say that tweaking the smart ptr. impl. goes in a wrong way. What is
needed is to avoid direct use of ctors and new/make_shared and instead use
creator functions than can do some extra work to avoid needless allocations.
E.g., someting like the following would ensure there are never more than 2
allocations of objects of OOXMLBooleanValue:

OOXMLValue::Pointer_t OOXMLBooleanValue::create(bool val)
{
if (val)
{
static OOXMLValue::Pointer_t aTrue(new OOXMLBooleanValue(val));
return aTrue;
}
else
{
static OOXMLValue::Pointer_t aFalse(new OOXMLBooleanValue(val));
return aFalse;
}
}

(Of course, for this to really work, clone() would have to be changed to return
Pointer_t as well. But I do not think that naked pointers are used anywhere at
all, so this is not a problem.)

OOXMLIntegerValue and the few others that wrap intergers could use some sort of
cache.

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-23 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

--- Comment #6 from Michael Meeks michael.me...@collabora.com ---
Sure - I just don't like 31337 interlocked atomic referencing on something that
is not thread safe, its pure waste =) either way - we can wait until we see
that in the profile again I guess. The fruit is so low-hanging here we can win
whatever we do.

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-22 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

--- Comment #4 from Michael Meeks michael.me...@collabora.com ---
Fair cop - but for very high frequency things like the OOXML attributes /
values etc. [ the ones tackled so far are ~never used sadly ;-] - I want
intrusive pointers for 2x reasons:

a) to avoid allocations and
b) to avoid atomic interlock operations on ref counting

We should never be allocating / ref / unref'ing one of two boolean values eg.
;-)

Otherwise make_shared seems like a great idea.

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-22 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

David Tardon dtar...@redhat.com changed:

   What|Removed |Added

 CC||dtar...@redhat.com

--- Comment #3 from David Tardon dtar...@redhat.com ---
(In reply to comment #0)
 The writerfilter imports DOCX files and it spends quite lot of un-necessary
 cycles allocating un-necessary things and then freeing them very shortly
 afterwards =)
 
 The use of boost::shared_ptr creates a chunk of waste here - it requires
 allocating an extra object to hold a ref-count; and we can easily do this
 just as well with an intrusive pointer that is part of the same
 object/allocation.

It does not, if the shared_ptr is created by boost::make_sharedFoo(...)
instead of boost::shared_ptr(new Foo(...)). Then there is only one allocation.

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

Commit Notification libreoffice-comm...@lists.freedesktop.org changed:

   What|Removed |Added

 Whiteboard|EasyHack DifficultyBeginner |EasyHack DifficultyBeginner
   |SkillCpp TopicCleanup   |SkillCpp TopicCleanup
   ||target:4.4.0

--- Comment #2 from Commit Notification 
libreoffice-comm...@lists.freedesktop.org ---
Fahad Al-Saidi committed a patch related to this issue.
It has been pushed to master:

http://cgit.freedesktop.org/libreoffice/core/commit/?id=c04a0895df86f40faef1bc093f7010f374df9d0b

fdo#80907 Implemented OOXMLFactory using boost::intrusive_ptr.



The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds
Affected users are encouraged to test the fix and report feedback.

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-04 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

Michael Meeks michael.me...@collabora.com changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
 Ever confirmed|0   |1

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-04 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

Michael Meeks michael.me...@collabora.com changed:

   What|Removed |Added

 Whiteboard||EasyHack DifficultyBeginner
   ||SkillCpp TopicCleanup

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-04 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

Michael Meeks michael.me...@collabora.com changed:

   What|Removed |Added

   See Also||https://bugs.freedesktop.or
   ||g/show_bug.cgi?id=80908

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs


[Libreoffice-bugs] [Bug 80907] Cleanup / performance issue ...

2014-07-04 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=80907

--- Comment #1 from Michael Meeks michael.me...@collabora.com ---
Created attachment 102262
  -- https://bugs.freedesktop.org/attachment.cgi?id=102262action=edit
kcachegrind picture

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs