pycousin / gnome-mplayer

Automatically exported from code.google.com/p/gnome-mplayer
GNU General Public License v2.0
0 stars 0 forks source link

gnome-mpalyer about 2x slower than mplayer/VLC #286

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
gnome-mplayer (and gecko-mediaplayer) use about twice as much CPU time as
the others.

I ran oprofile whilst streaming the same video to all three players on my
system:

gnome-mplayer
mplayer
vlc

I'm not too knowledgeable about how to interpret the results, but it's
clear that gnome-mplayer is spending more time copying data in the kernel
(perhaps to communicate with mplayer?)

$ opreport session:gnome-mplayer -l /usr/bin/mplayer

1706713  80.8656  mplayer                  /usr/bin/mplayer
227634   10.7855  vmlinux                  copy_from_user
94760     4.4898  libc-2.10.1.so           memcpy
12610     0.5975  vmlinux                  read_hpet
7696      0.3646  radeon                   /radeon
1999      0.0947  libc-2.10.1.so           memset
1675      0.0794  vmlinux                  ioread8
...

$ opreport session:gnome-mplayer -l /usr/bin/mplayer

835659   95.6463  mplayer                  /usr/bin/mplayer
5562      0.6366  vmlinux                  read_hpet
4789      0.5481  libc-2.10.1.so           memcpy
1310      0.1499  libc-2.10.1.so           memset
1171      0.1340  vmlinux                  ioread8

$ opreport session:vlc -l

765272   57.3407  libavcodec.so.52.20.0    vlc                     
/usr/lib/libavcodec.so.52.20.0
39014     2.9233  libc-2.10.1.so           Xorg                     memcpy
32573     2.4406  Xorg                     Xorg                    
/usr/bin/Xorg
32018     2.3991  libbandlimited_resampler_plugin.so vlc                  
   T.71
29239     2.1908  libasound.so.2.0.0       vlc                     
snd_pcm_lfloat_convert_float_integer
24361     1.8253  libmemcpymmxext_plugin.so vlc                     
fast_memcpy
22997     1.7231  libasound.so.2.0.0       vlc                     
linear_expand
17518     1.3126  libasound.so.2.0.0       vlc                     
mix_areas_32
13731     1.0288  vmlinux                  vmlinux                 
acpi_idle_enter_bm
12784     0.9579  vmlinux                  Xorg                     delay_tsc

As you can see, gnome-mplayer spends a significant amount of time in
copy_from_user() and memcpy(); there are also a little more than twice the
number of samples taken while profiling gnome-mplayer, but I'm not certain
that's a valid interpretation, though gnome-mplayer does seem to use twice
the CPU% 

Original issue reported on code.google.com by mfwit...@gmail.com on 19 Sep 2009 at 9:14

GoogleCodeExporter commented 8 years ago
I think you are benchmarking actually mplayer in this case (which is used by
gnome-mplayer, but not part of it). I have done some performance testing of just
gnome-mplayer and I think it uses the machine pretty lightly.

Original comment by kdeko...@gmail.com on 20 Sep 2009 at 2:24

GoogleCodeExporter commented 8 years ago
You're missing the point; the fact remains that gnome-mplayer takes more CPU 
time (2x
on my system) to play a video than does straight mplayer or even vlc.

The oprofile data I provided suggests that the relationship between 
gnome-mplayer and
mplayer has fairly significant overhead because data must be copied around more 
than
the computation itself actually requires.

Original comment by mfwit...@gmail.com on 21 Sep 2009 at 12:26

GoogleCodeExporter commented 8 years ago
Does top show this? And yes I have done benchmarking on my machine and what I 
have
observed is usually a 1% overhead with using gnome-mplayer with mplayer. The 
video
output you chose can drastically affect these numbers so make sure you are 
using the
same values in both tests.

Original comment by kdeko...@gmail.com on 21 Sep 2009 at 12:45