Re: 3dnow, mmx, k6-2 optimizing?
Interesting. I just tried the settings you suggested, and it seems that -mcpu is depreciated for -mtune. ALWAYS check the documentation first. :-) Here's the details: http://gcc.gnu.org/onlinedocs/gcc-3.4.2/gcc/i386-and-x86_002d64-Options.html#i386-and-x86_002d64-Options Puna Puna Tannehill wrote: James Green wrote: Hi Puna, I had a k6-2 a few years back (before discovering BSD :) and did a lot of Linux From Scratch work on it. I found that passing -march=i586 -mcpu=i686 produced by far the best results for pretty much any C/C++ code. Of course the code produced will not run on anything but a k6-2, which as I understand it is a 686 core with 586 interface/timings, and likewise if memory serves specifying only -march=i586 or -march=i686 (implying -mcpu=i586 or -mcpu=i686 respectively) won't run on the k6-2 either. Definitely a trade off between speed and (total lack of) portablility. Again that was gcc-2.9x days... Interesting. Was there an option for -march=k6-2 at that time? Were the results based on a comparison of that setting and the ones you mention above? Do you happen to know if there is a particular benchmarking program that might be useful to testing different compiles in FreeBSD? I've also seen recommendations using '586/mmx' and 'k7', but it seems interesting that someone would create a 'k6-2' flag if there were not significant and benefitial optimizations that would be applied. Of course, whether anyone coded for that particular processor is probably extemely rare, so I can see how the -march -mcpu combination you suggested would probably be a better choice. Here are the relavent bits from dmesg (Compaq Presario 1692): CPU: AMD-K6(tm) 3D processor (432.98-MHz 586-class CPU) Origin = AuthenticAMD Id = 0x58c Stepping = 12 Features=0x8021bfFPU,VME,DE,PSE,TSC,MSR,MCE,CX8,PGE,MMX AMD Features=0x8800SYSCALL,3DNow! K6-family MTRR support enabled (2 registers) As far as ports such as Xorg/Xfree86, I am not entirely clear on CFLAGS inheritance, but AFAIK Xorg/Xfree don't gain much/anything from optimisation over than your usual -O2 and friends. I understand that this is down to whether they have been written to make use of these cpu functions/optimisations. On the other hand though, it is the specific applications that run under X, such as mplayer that tend to be written to make use of mmx, sse, 3dnow etc. because for graphics it makes a _big_ difference. Generally you find toggles in the Makefile to enable/force certain optimisation. Definitely worth looking at. According to the latest GCC, you can use -m3dnow -mmmx and it is of some benefit when comiling XF86 (and hopefully Xorg). I can't find the page offhand, but it was in the GCC Documentation, and I posted it in other responses of this same thread. I haven't been able to test it yet, as I'm still compiling Xorg as we speak. Puna On Mon, 2004-09-13 at 17:07, Puna Tannehill wrote: I've been looking for possible flags, optimizations, really anything that would help me setup my laptop to use mmx and 3dnow. I've updated /etc/make.conf to -march to the drum of a k6-2, but I'm not even sure if mmx and 3dnow are being taken into consideration for compiling and such, especially for Xorg. I did some googling and found people who used CFLAGS like -mmmx and -m3dnow, but when I run with those options, they fail and said to be invalid. they don't appear in 'man gcc' which should have been the first place i looked. I'm not finding anything in terms of compiling or configuring Xorg to use 3dnow or mmx, or even how to check to see if they are automatically detected and used. Any thoughts? Puna ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-mobile To unsubscribe, send any mail to [EMAIL PROTECTED] ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
kern.ipc.maxpipekva exceeded, error
On a freshly rebuild v5.3-BETA4... A failed compile of sysutils/fastest_cvsup led me to run 'make clean' before trying again. It took over 5 minutes to run make clean, and at the very end I got the following: # make clean kern.ipc.maxpipekva exceeded; see tuning(7) Pipe call failed: Too many open files in system Pipe call failed: Too many open files in system === Cleaning for libtool-1.5.8 === Cleaning for perl-5.8.5 === Cleaning for fastest_cvsup-0.2.8 There is nothing specifically in tuning about this particular knob, but from poking around I get the feeling that it's about memory management of the kernel IPC subsystem. Running 'sysctl kern.ipc.maxpipekva' shows: kern.ipc.maxpipekva=1257472 Hunting around on in the archives, I came up with people getting this error while doing very intensive compiles. Seems strange to me that I might get such an error on a 15min uptime, cold-booted machine and just doing a 'make clean'. And thoughts? Puna ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
3dnow, mmx, k6-2 optimizing?
I've been looking for possible flags, optimizations, really anything that would help me setup my laptop to use mmx and 3dnow. I've updated /etc/make.conf to -march to the drum of a k6-2, but I'm not even sure if mmx and 3dnow are being taken into consideration for compiling and such, especially for Xorg. I did some googling and found people who used CFLAGS like -mmmx and -m3dnow, but when I run with those options, they fail and said to be invalid. they don't appear in 'man gcc' which should have been the first place i looked. I'm not finding anything in terms of compiling or configuring Xorg to use 3dnow or mmx, or even how to check to see if they are automatically detected and used. Any thoughts? Puna ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: 3dnow, mmx, k6-2 optimizing?
Erik Trulsson wrote: On Mon, Sep 13, 2004 at 12:23:18PM -0500, Puna Tannehill wrote: I've been looking for possible flags, optimizations, really anything that would help me setup my laptop to use mmx and 3dnow. I've updated /etc/make.conf to -march to the drum of a k6-2, but I'm not even sure if mmx and 3dnow are being taken into consideration for compiling and such, especially for Xorg. I did some googling and found people who used CFLAGS like -mmmx and -m3dnow, but when I run with those options, they fail and said to be invalid. they don't appear in 'man gcc' which should have been the first place i looked. I'm not finding anything in terms of compiling or configuring Xorg to use 3dnow or mmx, or even how to check to see if they are automatically detected and used. Any thoughts? You do not say which version of FreeBSD or GCC you are using. Gcc 2.95 (which is what FreeBSD 4.x ships with) do not know about MMX or 3Dnow, and will not take advantage of them. Gcc 3.4 (which is what FreeBSD 5.x comes with) does know about MMX and 3DNow and will take advantage of them when invoked correctly. The switches you mention (-mmx and -m3dnow) are valid for gcc 3.4 but not for gcc 2.95. Apologies! I'm running v5.3-BETA3 with GCC v3.4.2. You can look at the GCC documentation found at http://gcc.gnu.org/onlinedocs/ to find out what options are supported by which versions of GCC. mmm, documentation... Thank you! I have added the options to CFLAGS in /etc/make.conf and am currently rebuilding world without any stops yet. Although, there is probably little or nothing outside of X windows that those options might help optimize. But I'll be rebuilding Xorg and XFCE right after I'm done with the world. For those who are following, here are the pages that I found most useful as reference materials: Intel 386 and AMD x86-64 Options: http://gcc.gnu.org/onlinedocs/gcc-3.4.1/gcc/i386-and-x86-64-Options.html#i386%20and%20x86-64%20Options X86 Built-in Functions: http://gcc.gnu.org/onlinedocs/gcc-3.4.1/gcc/X86-Built-in-Functions.html#X86%20Built-in%20Functions Puna --- Pinky, are you pondering what I'm pondering? I think so Brain, but burlap chaffs me so... ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: 3dnow, mmx, k6-2 optimizing?
Conrad J. Sabatier wrote: On Mon, 13 Sep 2004 12:23:18 -0500, Puna Tannehill [EMAIL PROTECTED] wrote: I've been looking for possible flags, optimizations, really anything that would help me setup my laptop to use mmx and 3dnow. I've updated /etc/make.conf to -march to the drum of a k6-2, but I'm not even sure if mmx and 3dnow are being taken into consideration for compiling and such, especially for Xorg. I did some googling and found people who used CFLAGS like -mmmx and -m3dnow, but when I run with those options, they fail and said to be invalid. they don't appear in 'man gcc' which should have been the first place i looked. I'm not finding anything in terms of compiling or configuring Xorg to use 3dnow or mmx, or even how to check to see if they are automatically detected and used. Any thoughts? Puna I don't know why those flags would not be working for you; I've been using them for quite some time now on my Athlon (32-bit) box. One oddity I just noticed very recently is that, with the recent patches to make, the CPUTYPE variable seems to be ignored now, which is why I explicitly added the -march flag to CFLAGS. Also, note that I don't use -mmmx -m3dnow for kernel builds; you don't want to be doing this, as it can easily break things in the kernel, but for general builds and port builds, it's fine: CPUTYPE?=athlon I had that problem too. The '?=' should be just '='. I see in the notes that '?=' is for compiling for different machine, but I don't do that so I just left is as 'CPUTYPE=' and it added the -march accordingly. CFLAGS= -O3 -pipe -march=athlon -mmmx -m3dnow # buildkernel variables settings KERNCONF=CUSTOM COPTFLAGS= -O3 -pipe -march=athlon I see many people using a -O3, but I've never been able to use any optimization levels above -O without compile errors, or having problems with SSH. Just out of curiosity, do you see a significant different in performance with that level of optimization? Puna It's working for me now, I'm not sure why it was failing before. Puna ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Updating 5.2.1 Release #
Scott wrote: Hi, I completed my first update (upgrade?) of a 5.2.1 fresh FreeBSD install. I followed a couple how-to's, the handbook, and Absolute BSD as my guides. My machine is a 1.8Ghz AMD. Here is my supfile: *default host=cvsup15.us.FreeBSD.org *default base=/usr *default prefix=/usr *default release=cvs tag=RELENG_5_2_1_RELEASE *default delete use-rel-suffix *default compress src-all ports-all tag=. Everything seemed to go without a hitch. I did: 1. cvsup mysupfile 2. make buildworld 3. make buildkernel 4. make installkernel 5. make installworld The system is up and seems to be running fine, but here's my question: uname -a shows: FreeBSD 5.2.1-Release #0: I was expecting the release (version, revision# ?) number to be greater than #0. I think I've seen where the latest revision is #9 or so? Do I need to tell it to get the latest revision somehow? Do I need to change the cvs tag= to something else to get up to date? I thought the #number indicated the number of times the server has been rebooted based upon the last time the kernel was recompiled. Being that it is #0, it was your first book. Reboot the machine and check the number again. Puna Thanks for your time, Scott ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED] ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Updating 5.2.1 Release #
Matthew Seaman wrote: On Thu, Jul 29, 2004 at 09:37:35AM -0500, Puna Tannehill wrote: Scott wrote: uname -a shows: FreeBSD 5.2.1-Release #0: I was expecting the release (version, revision# ?) number to be greater than #0. I think I've seen where the latest revision is #9 or so? Do I need to tell it to get the latest revision somehow? Do I need to change the cvs tag= to something else to get up to date? I thought the #number indicated the number of times the server has been rebooted based upon the last time the kernel was recompiled. Being that it is #0, it was your first book. Reboot the machine and check the number again. I believe that the #n is the number of times the kernel has been re-compiled since the last time the system was installed. It's probably not a very interesting datum except to kernel hackers who need to do a lot of recompiling. Oh right right. Thank you for the correction. I'm still wiping the sleep from my eyes. Actually, it might be an fun indicator of how many 15-20 minute chunks of time one can never get back. heehee hmm ~sighs and sips coffee~ Puna What the original poster was thinking of is the patchlevel that gets incremented every time a new security (or nowadays: errata) patch is applied to any of the -RELEASE branches. That modifies the OS name (ie. the output of 'uname -r'), so instead of: 5.2.1-RELEASE it says (at the latest count): 5.2.1-RELEASE-p9 See /usr/src/sys/conf/newvers.sh for the file that controls all that. Cheers, Matthew ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Why BSD?
It's also about quality of the underlying work. On average, Linux base code runs 10% faster under FreeBSD. Linux works toward patches for what everyone wants because it competes for the Windows market share. FreeBSD works toward solutions because it competes with no one. Jonathan T. Sage wrote: Chris wrote: On Friday 23 January 2004 10:40 pm, Jeff Elkins wrote: This is not a troll. I've installed FreeBSD 5.2 on a spare SCSI drive and am compiling kernels, updating ports, etc,etc. Thus far, other than some minor hassles, it's equivilent to my Debian sid. I have to ask: Why FreeBSD rather than Linux? Honest question. Thanks, Jeff Show us your feet! If they are Hobbit-like, it's a Troll *Laffs* Hah! Honestly though Jeff - You sound like an experienced user, at the risk of starting the war again, It really boils down to a lot of personal preference. We use freebsd because we like freebsd, we like the communitiy, etc, etc, etc. My choice boils down to 2 things. /usr/ports/.../... # make install and /usr/src # make world(ish) From the server standpoint, if you know what your doing, given enough time, you can do pretty much anything you could want to with either. ~jon ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]