Re: excessive use of gettimeofday(2) and other syscalls

2011-09-11 Thread Paul Ambrose
Sorry, my previous test is not accurate. I use  both firefox and chromium to
open 13 same web pages( two of them are from www.sina.com.cn, other from
groups.google.com, wiki.sun.com and freebsd.org,  both web browsers use
libcrossflash to drive linux flash plugin, not linuxulator on my amd64
8.2-stable , sorry I can not have access to youtube.com or facebook.com, I'm
in china),
and this is the result:
...
[root@lateaxfreebsd sys]# dtrace -n 'syscall::gettimeofday:entry / execname
== "chrome" || execname == "firefox-bin"|| execname == "plugin-container" /
{ @[execname] = count() } profile:::tick-1 { exit(0); } '
dtrace: description 'syscall::gettimeofday:entry ' matched 2 probes
CPU ID FUNCTION:NAME
1 97 :tick-1

plugin-container 7802
chrome 8403
firefox-bin 215777


if I close the two sina.com.cn tab( the big page), then
.
[root@lateaxfreebsd sys]# dtrace -n 'syscall::gettimeofday:entry / execname
== "chrome" || execname == "firefox-bin"|| execname == "plugin-container" /
{ @[execname] = count() } profile:::tick-1 { exit(0); } '
dtrace: description 'syscall::gettimeofday:entry ' matched 2 probes
CPU ID FUNCTION:NAME
1 97 :tick-1

chrome 65
plugin-container 2145
firefox-bin 268932

I think I can drive conclusion that chromium is much better than firefox
when rendering same page set, especially on static pages only 65 per second.
If we add opera to the list( opera not using flash plugin), it seems
opera does NOT use gettimeofday
.
[root@lateaxfreebsd sys]# dtrace -n 'syscall::gettimeofday:entry / execname
== "chrome" || execname == "firefox-bin"|| execname == "plugin-container" ||
execname == "opera" / { @[execname, probefunc] = count() } profile:::tick-1
{ exit(0); } '
dtrace: description 'syscall::gettimeofday:entry ' matched 2 probes
CPU ID FUNCTION:NAME
0 97 :tick-1

chrome gettimeofday 7632
plugin-container gettimeofday 8107
firefox-bin gettimeofday 232142


but it use more clock_gettime
.
[root@lateaxfreebsd sys]# dtrace -n 'syscall::clock_gettime:entry / execname
== "chrome" || execname == "firefox-bin"|| execname == "plugin-container" ||
execname == "opera" / { @[execname, probefunc] = count() } profile:::tick-1
{ exit(0); } '
dtrace: description 'syscall::clock_gettime:entry ' matched 2 probes
CPU ID FUNCTION:NAME
1 97 :tick-1

firefox-bin clock_gettime 634
chrome clock_gettime 839
plugin-container clock_gettime 1040
opera clock_gettime 14978


2011/9/10 Alexander Best 

> On Fri Sep  9 11, Alexander Best wrote:
> > On Fri Sep  9 11, Dieter BSD wrote:
> > > >> Firefox 5 and 6 has more gettimeofday call than 2 per second on
> my
> > > >> amd64-8.2-stable box.
> > >
> > > > i don't see why chromium needs
> > > > to call gettimeofday(2) or any library function that triggers it more
> > > > than 3000 times a second.
> > >
> > > What the  are web browsers doing that they "need" the clock
> > > so often?
> > >
> > > I suspect the answer is the same as why firefox uses significant
> amounts
> > > of CPU when it should be idle, why it uses memory without bound
> > > (I actually had to add ulimit to my shell's rc file :-( ), and
> > > so on.
> > >
> > > Using "links -g",
> > > "ktrace -di -tc -p6951; sleep 1; ktrace -C; kdump|wc -l"
> > > gives a typical count of 300-400, highest count seen: 1454.
> >
> > well that measurement is probably unfair. my measurements included all
> opened
> > tabs (~ 15), running plugins and extensions. if i disable all of those
> extra
> > stuff and use only a single tab, chromium produces less syscalls than
> links:
> >
> > 270
>
> ...however sites such as facebook produce a much higher syscall peek under
> chromium. with only one tab opened with youtube.com in it, chromium has a
> typical syscall count of 700-2000. i guess this is due to stuff like js,
> html5
> and friends.
>
> if i enable the flash plugins with only 1 single tab (youtube.com), the
> syscall
> count climbs to ~ 8000 with a peak at 19000 when youtube.com wasn't
> completely
> loaded. so the high syscall count is not only chromiums fault, but a
> combination of chromium, flash and the linuxulator.
>
> i believe further linuxulator improvements might reduce syscalls in this
> scenario.
>
> also with chromium 15, the syscall count is supposed to drop quite
> noticably
> (as mentioned in a previous message).
>
> cheers.
> alex
>
> >
> > cheers.
> > alex
> >
> > >
> > > What we need, is a sanely written web browser that has the
> > > features we need. Unfortunately the last time I checked,
> > > links and dillo both lacked features needed for online
> > > shopping/banking.
> ___
> freebsd-hackers@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"
>
__

man bzip2 - suggest we add to See Also

2011-09-11 Thread b. f.
>
> I suggest we should add a See Also section to man bzip2,
>
> FreeBSD-8.2-RELEASE & current man bzip2
> .../-current/src/contrib/bzip2/bzip2.1
>
> adding URLs
> http://www.7-zip.org/download.html  ->
> http://www.freshports.org/archivers/p7zip/
>
> as currently no reference is made to 7zip or 7-zip

I'm a bit confused -- are you recommending this because you think that
users should be aware of the the other compression methods/archive
formats that 7zip uses, so that they can investigate alternatives, or
just because it is a Windows program that can decompress bzipped
files?  In either case, I don't see any reason to single out 7zip --
we have xz(1) in the base system now, and there are other, arguably
better compression methods in Ports. And there is a lot of
Windows-based software that can decompress bzip2, including Windows
ports of bzip2 itself.  I don't think that the bzip2 manpage is the
appropriate place to add this kind of information.  (Perhaps the
FreeBSD Handbook, in a section about working with files typically
found on FreeBSD or other Unixen in Windows, or in libarchive(5), if
it were changed to support the 7zip archive format.) And I don't think
that -hackers is the appropriate list for this proposal -- -doc seems
to be the right place.

b.
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"


Re: man bzip2 - suggest we add to See Also

2011-09-11 Thread Julian H. Stacey
"b. f." wrote:
> >
> > I suggest we should add a See Also section to man bzip2,
> >
> > FreeBSD-8.2-RELEASE & current man bzip2
> > .../-current/src/contrib/bzip2/bzip2.1
> >
> > adding URLs
> > http://www.7-zip.org/download.html  ->
> > http://www.freshports.org/archivers/p7zip/
> >
> > as currently no reference is made to 7zip or 7-zip
> 
> I'm a bit confused -- are you recommending this because you think that
> users should be aware of the the other compression methods/archive
> formats that 7zip uses, so that they can investigate alternatives, or
> just because it is a Windows program that can decompress bzipped
> files?

Yes.
If FreeBSD users happen to export .bz2 files to Microsoft users,
uts nice to be able to tell MS users at least 1 MS program that can 
access the format.

> In either case, I don't see any reason to single out 7zip --
> we have xz(1) in the base system now, and there are other, arguably
> better compression methods in Ports. And there is a lot of
> Windows-based software that can decompress bzip2, including Windows
> ports of bzip2 itself.

OK didnt know that. by all means add a URL.

> I don't think that the bzip2 manpage is the
> appropriate place to add this kind of information.  (Perhaps the
> FreeBSD Handbook, in a section about working with files typically
> found on FreeBSD or other Unixen in Windows, or in libarchive(5), if
> it were changed to support the 7zip archive format.) And I don't think
> that -hackers is the appropriate list for this proposal -- -doc seems
> to be the right place.

Well I'm an old Unix hand, I have much more faith in the man command,
that works on machines even if no net connected. (& easy to edit,
& format without the tool chain from hell that doc uses) hence I
suggested adding a URL in see also of man.

Cos' if eg I get a phone call from an MS [l]user saying "what do I
do with your .bz2?" I would first by reflex type man bzip2 /See
Also.  & not first connect to net & mouse around to docs.

Cheers,
Julian
-- 
Julian Stacey, BSD Unix Linux C Sys Eng Consultants Munich http://berklix.com
 Reply below, not above;  Indent with "> ";  Cumulative like a play script.
 Format: Plain text. Not HTML, multipart/alternative, base64, quoted-printable.
 http://www.softwarefreedomday.org 17th Sept,  http://berklix.org/sfd/ Oct.
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"


Re: man bzip2 - suggest we add to See Also

2011-09-11 Thread Chris Rees
On 11 September 2011 13:19, Julian H. Stacey  wrote:
> "b. f." wrote:
>> >
>> > I suggest we should add a See Also section to man bzip2,
>> >
>> >         FreeBSD-8.2-RELEASE & current man bzip2
>> >                 .../-current/src/contrib/bzip2/bzip2.1
>> >
>> > adding URLs
>> >         http://www.7-zip.org/download.html      ->
>> >         http://www.freshports.org/archivers/p7zip/
>> >
>> > as currently no reference is made to 7zip or 7-zip
>>
>> I'm a bit confused -- are you recommending this because you think that
>> users should be aware of the the other compression methods/archive
>> formats that 7zip uses, so that they can investigate alternatives, or
>> just because it is a Windows program that can decompress bzipped
>> files?
>
> Yes.
> If FreeBSD users happen to export .bz2 files to Microsoft users,
> uts nice to be able to tell MS users at least 1 MS program that can
> access the format.
>
>> In either case, I don't see any reason to single out 7zip --
>> we have xz(1) in the base system now, and there are other, arguably
>> better compression methods in Ports. And there is a lot of
>> Windows-based software that can decompress bzip2, including Windows
>> ports of bzip2 itself.
>
> OK didnt know that. by all means add a URL.
>
>> I don't think that the bzip2 manpage is the
>> appropriate place to add this kind of information.  (Perhaps the
>> FreeBSD Handbook, in a section about working with files typically
>> found on FreeBSD or other Unixen in Windows, or in libarchive(5), if
>> it were changed to support the 7zip archive format.) And I don't think
>> that -hackers is the appropriate list for this proposal -- -doc seems
>> to be the right place.
>
> Well I'm an old Unix hand, I have much more faith in the man command,
> that works on machines even if no net connected. (& easy to edit,
> & format without the tool chain from hell that doc uses) hence I
> suggested adding a URL in see also of man.
>
> Cos' if eg I get a phone call from an MS [l]user saying "what do I
> do with your .bz2?" I would first by reflex type man bzip2 /See
> Also.  & not first connect to net & mouse around to docs.
>

Do we usually add a Windows analogue of our commands to the man page?
I would have thought that Google is definitely the most appropriate
medium for finding that out.

Chris
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"


Re: man bzip2 - suggest we add to See Also

2011-09-11 Thread Julian H. Stacey
Hi,
Repost of mine, with restored
cc: Julian Seward 
as I just noticed (while later answering Chris Rees), that
Julian Seward 
( author of imported code in src/ ) mistakenly dropped by 
bf1...@gmail.com
(so Chris inherited depleted CC line from b f)

Reference:
> From: "Julian H. Stacey"  
> Date: Sun, 11 Sep 2011 14:19:33 +0200 
> 

"Julian H. Stacey" wrote:
> "b. f." wrote:
> > >
> > > I suggest we should add a See Also section to man bzip2,
> > >
> > > FreeBSD-8.2-RELEASE & current man bzip2
> > > .../-current/src/contrib/bzip2/bzip2.1
> > >
> > > adding URLs
> > > http://www.7-zip.org/download.html  ->
> > > http://www.freshports.org/archivers/p7zip/
> > >
> > > as currently no reference is made to 7zip or 7-zip
> > 
> > I'm a bit confused -- are you recommending this because you think that
> > users should be aware of the the other compression methods/archive
> > formats that 7zip uses, so that they can investigate alternatives, or
> > just because it is a Windows program that can decompress bzipped
> > files?
> 
> Yes.
> If FreeBSD users happen to export .bz2 files to Microsoft users,
> uts nice to be able to tell MS users at least 1 MS program that can 
> access the format.
> 
> > In either case, I don't see any reason to single out 7zip --
> > we have xz(1) in the base system now, and there are other, arguably
> > better compression methods in Ports. And there is a lot of
> > Windows-based software that can decompress bzip2, including Windows
> > ports of bzip2 itself.
> 
> OK didnt know that. by all means add a URL.
> 
> > I don't think that the bzip2 manpage is the
> > appropriate place to add this kind of information.  (Perhaps the
> > FreeBSD Handbook, in a section about working with files typically
> > found on FreeBSD or other Unixen in Windows, or in libarchive(5), if
> > it were changed to support the 7zip archive format.) And I don't think
> > that -hackers is the appropriate list for this proposal -- -doc seems
> > to be the right place.
> 
> Well I'm an old Unix hand, I have much more faith in the man command,
> that works on machines even if no net connected. (& easy to edit,
> & format without the tool chain from hell that doc uses) hence I
> suggested adding a URL in see also of man.
> 
> Cos' if eg I get a phone call from an MS [l]user saying "what do I
> do with your .bz2?" I would first by reflex type man bzip2 /See
> Also.  & not first connect to net & mouse around to docs.
> 
> Cheers,
> Julian
> -- 
> Julian Stacey, BSD Unix Linux C Sys Eng Consultants Munich http://berklix.com
>  Reply below, not above;  Indent with "> ";  Cumulative like a play script.
>  Format: Plain text. Not HTML, multipart/alternative, base64, 
> quoted-printable.
>  http://www.softwarefreedomday.org 17th Sept,  http://berklix.org/sfd/ Oct.


Cheers,
Julian
-- 
Julian Stacey, BSD Unix Linux C Sys Eng Consultants Munich http://berklix.com
 Reply below, not above;  Indent with "> ";  Cumulative like a play script.
 Format: Plain text. Not HTML, multipart/alternative, base64, quoted-printable.
 http://www.softwarefreedomday.org 17th Sept,  http://berklix.org/sfd/ Oct.
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"


Re: man bzip2 - suggest we add to See Also

2011-09-11 Thread Julian H. Stacey
Chris Rees wrote:
> On 11 September 2011 13:19, Julian H. Stacey  wrote:
> > "b. f." wrote:
> >> >
> >> > I suggest we should add a See Also section to man bzip2,
> >> >
> >> >         FreeBSD-8.2-RELEASE & current man bzip2
> >> >                 .../-current/src/contrib/bzip2/bzip2.1
> >> >
> >> > adding URLs
> >> >         http://www.7-zip.org/download.html      ->
> >> >         http://www.freshports.org/archivers/p7zip/
> >> >
> >> > as currently no reference is made to 7zip or 7-zip
> >>
> >> I'm a bit confused -- are you recommending this because you think that
> >> users should be aware of the the other compression methods/archive
> >> formats that 7zip uses, so that they can investigate alternatives, or
> >> just because it is a Windows program that can decompress bzipped
> >> files?
> >
> > Yes.
> > If FreeBSD users happen to export .bz2 files to Microsoft users,
> > uts nice to be able to tell MS users at least 1 MS program that can
> > access the format.
> >
> >> In either case, I don't see any reason to single out 7zip --
> >> we have xz(1) in the base system now, and there are other, arguably
> >> better compression methods in Ports. And there is a lot of
> >> Windows-based software that can decompress bzip2, including Windows
> >> ports of bzip2 itself.
> >
> > OK didnt know that. by all means add a URL.
> >
> >> I don't think that the bzip2 manpage is the
> >> appropriate place to add this kind of information.  (Perhaps the
> >> FreeBSD Handbook, in a section about working with files typically
> >> found on FreeBSD or other Unixen in Windows, or in libarchive(5), if
> >> it were changed to support the 7zip archive format.) And I don't think
> >> that -hackers is the appropriate list for this proposal -- -doc seems
> >> to be the right place.
> >
> > Well I'm an old Unix hand, I have much more faith in the man command,
> > that works on machines even if no net connected. (& easy to edit,
> > & format without the tool chain from hell that doc uses) hence I
> > suggested adding a URL in see also of man.
> >
> > Cos' if eg I get a phone call from an MS [l]user saying "what do I
> > do with your .bz2?" I would first by reflex type man bzip2 /See
> > Also.  & not first connect to net & mouse around to docs.
> >
> 
> Do we usually add a Windows analogue of our commands to the man page?
> I would have thought that Google is definitely the most appropriate
> medium for finding that out.
> 
> Chris

Good point. Consisteny; that would probably tilt to Not adding any URLs;
but many Unix commands don't have direct comparable commands, so
there's not so many commands to be consistent with I suppose, 

tar might be a related tool to be consistent with, but
bsdtar is quite new, & hasn't had much time to accumulate URLs
to compatible tools on other OS's, though it does have a section Standards.

Google & other search engines help discovery, (that's how I
found bzip2 compression method listed on minux3.org in last URL).

I guess author of imported code will decide:
Julian Seward 

Cheers,
Julian
-- 
Julian Stacey, BSD Unix Linux C Sys Eng Consultants Munich http://berklix.com
 Reply below, not above;  Indent with "> ";  Cumulative like a play script.
 Format: Plain text. Not HTML, multipart/alternative, base64, quoted-printable.
 http://www.softwarefreedomday.org 17th Sept,  http://berklix.org/sfd/ Oct.
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"