From owner-freebsd-current Fri May 5 17:30:57 2000 Delivered-To: freebsd-current@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id BC2C037B907 for ; Fri, 5 May 2000 17:30:52 -0700 (PDT) (envelope-from jmz@FreeBSD.org) Received: (from jmz@localhost) by freefall.freebsd.org (8.9.3/8.9.3) id RAA11795; Fri, 5 May 2000 17:30:52 -0700 (PDT) (envelope-from jmz@FreeBSD.org) Date: Fri, 5 May 2000 17:30:52 -0700 (PDT) Message-Id: <200005060030.RAA11795@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: jmz set sender to jmz@FreeBSD.org using -f From: Jean-Marc Zucconi To: current@FreeBSD.org Subject: Can someone explain this? X-Mailer: Emacs Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Here is something I don't understand: $ sh -c '/usr/bin/time ./a.out' 2.40 real 2.38 user 0.01 sys $ /usr/bin/time ./a.out 7.19 real 7.19 user 0.00 sys The same program is 3 times slower in the second case. The effect is systematic but depends on the program being run. I have seen inverse behavior with another program. Using time -l, I note that this seems to be related with a higher value of 'involuntary context switches' (3 times more switches in the slower case). Running -current (SMP) Here is my test program: main () { int i; double x, y, z; for (i = 0; i < 100000000; i++) z = y*x; } Jean-Marc -- Jean-Marc Zucconi PGP Key: finger jmz@FreeBSD.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message