Update 20200922

I have tested LibreOffice for a while.
It did cause Xorg memory explosion again as explained below.
I am excerpting my own personal notes here, please bear with the rough form of 
it.
The graph that I will attach next will show the point.

I started using a LibreOFfice program at 2020-09-06; this was a relaunch after
the last comment.

At timestamp = 20200921T2330, I checked Xorg memory usage tonight
after leaving LibreOffice open for over 11 days: Xorg RSS became
swollen to over 1 GB!

    xorg RSS ... 1182768 kiB

The "free" status was terrible:

                  total        used        free      shared  buff/cache   
available
    Mem:       12144888     9761024      596696      710552     1787168     
1353420
    Swap:       1808384     1477752      330632

Three major users of Xorg memory:

    LibreOffice Writer ( PID:1760594 ):
            pixmap bytes  : 334753205
    1 - xfwm4 ( PID:1477670 ):
            pixmap bytes  : 141633828
    Mozilla Firefox ( PID:1816946 ):
            pixmap bytes  : 44090522

The total of all three is ~520 MB.
LibreOffice alone is eating up over 334 MB of RAM!

NOTE: I did not use LibreOffice every day on this machine.
But I left that program open since it was opened on Sept 6.
I used the LO Writer occasionally to make notes now and then.


Now I am closing the LibreOffice program, see what happened.
Before LibreOffice doc was closed, the mem usage status was:

   LibreOffice pixmap bytes usage dropped to 286360981  (pixmap bytes)
   xfwm4  ....                               131834529  (pixmap bytes)
   firefox ....                               44090522  (pixmap bytes)
   xorg RSS ....                               1203568 kiB  => misleading, too 
much dumped to swap!

Let's close LibreOffice; after closing (time marker = 20200922T0006) the
usage:

   xfwm4  ....                                98517409
   firefox ....                               44090522
   xorg RSS ....                               1192256 kiB

A few observations:

* As you can see above, xorg RSS was NOT significantly reduced even after I 
closed
  the LibreOffice.  That was not the case with Firefox or with Xpra;
  the memory usage dropped as soon as I closed those programs.

* I also remember from my past observations that *when this Xorg
  memory explosion occurred*, the RSS of the xorg server is way higher than the 
(rough) sum total of the pixmap memory consumption
  reported by xrestop.
  My fuzzy memory has it at about a factor of 4:

      RSS(Xorg) ~ 4x sum(pixmap bytes reported by xrestop)

  The example above did not quite support that though, but still, it
  is a factor of more than two!

* I also looked at smaps:
  (ref: smaps-1600747980-20200922T001300.txt).
  That file indicates the largest memory occupied is in the heap:

      $ grep -e '^[0-9a-f]' -e 'Dirty' smaps-1600747980-20200922T001300.txt
      ...
      55aa90005000-55aad31ae000 rw-p 00000000 00:00 0                          
[heap]
      Shared_Dirty:          0 kB
      Private_Dirty:   1078916 kB
      ...


Now I closed Firefox as well: (after closure, timestamp: 20200922T0034)

   xfwm4  ....                                61755763
   xorg RSS ....                               1149028 kiB

Again, it looks like firefox X pixmap memory was freed ok (xorg RSS
dropped by ~50 MB), but not much lower.

-- 
You received this bug notification because you are a member of Ubuntu-X,
which is subscribed to xorg-server in Ubuntu.
https://bugs.launchpad.net/bugs/1884850

Title:
  Xorg server uses unacceptably large amounts of memory (and keep
  growing)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/xorg-server/+bug/1884850/+subscriptions

_______________________________________________
Mailing list: https://launchpad.net/~ubuntu-x-swat
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~ubuntu-x-swat
More help   : https://help.launchpad.net/ListHelp

Reply via email to