DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD Installation and Upgrading

FreeBSD Installation and Upgrading Installing and upgrading FreeBSD.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 21st October 2008
KernelPanic KernelPanic is offline
Port Guard
 
Join Date: May 2008
Posts: 19
Thanked 0 Times in 0 Posts
Default Optimizations for Xeon E5320?

Any suggested CPU optimizations for FreeBSD 7 i386 system with dual Xeon E5320? Its a Clovertown core with 2x4MB of L2 Cache?

I have none right now. Using Google I found this:

/etc/make.conf
CPUTYPE?=nocona
Reply With Quote
  #2   (View Single Post)  
Old 21st October 2008
graudeejs's Avatar
graudeejs graudeejs is offline
Real Name: Aldis Berjoza
formerly killasmurf86
 
Join Date: Jul 2008
Location: Riga, Latvia
Posts: 588
Thanked 29 Times in 26 Posts
Default

That's probably all you should do...
DO NOT edit any flags
or you will face not only KernelPanics but many different panics as well

build custom smp kernel
Reply With Quote
  #3   (View Single Post)  
Old 21st October 2008
KernelPanic KernelPanic is offline
Port Guard
 
Join Date: May 2008
Posts: 19
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by killasmurf86 View Post
That's probably all you should do...
DO NOT edit any flags
or you will face not only KernelPanics but many different panics as well

build custom smp kernel
For my custom SMP kernel I suck in GENERIC and then do the following:


# Old CPUs
nocpu I486_CPU
nocpu I586_CPU

# Change the scheduler
nooptions SCHED_4BSD
options SCHED_ULE

# I do not have AGP
nodevice agp
Reply With Quote
  #4   (View Single Post)  
Old 21st October 2008
graudeejs's Avatar
graudeejs graudeejs is offline
Real Name: Aldis Berjoza
formerly killasmurf86
 
Join Date: Jul 2008
Location: Riga, Latvia
Posts: 588
Thanked 29 Times in 26 Posts
Default

Quote:
Originally Posted by KernelPanic View Post
For my custom SMP kernel I suck in GENERIC and then do the following:


# Old CPUs
nocpu I486_CPU
nocpu I586_CPU

# Change the scheduler
nooptions SCHED_4BSD
options SCHED_ULE

# I do not have AGP
nodevice agp
wth is that?
if you want to disable something from generic
use # to comment line
Code:
# Old CPUs
#cpu   I486_CPU
#cpu   I586_CPU 
cpu   I686_CPU 

# Change the scheduler
#options       SCHED_4BSD
options SCHED_ULE

# I do not have AGP
#device        agp

Last edited by graudeejs; 21st October 2008 at 09:43 PM.
Reply With Quote
  #5   (View Single Post)  
Old 21st October 2008
richardpl richardpl is offline
Spam Deminer
 
Join Date: May 2008
Location: Croatia
Posts: 284
Thanked 25 Times in 24 Posts
Default

Wait for 7.1 RELEASE or track 7 STABLE.
Building custom kernel for 7.0 RELEASE is of very little gain.
Reply With Quote
  #6   (View Single Post)  
Old 21st October 2008
KernelPanic KernelPanic is offline
Port Guard
 
Join Date: May 2008
Posts: 19
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by richardpl View Post
Wait for 7.1 RELEASE or track 7 STABLE.
Building custom kernel for 7.0 RELEASE is of very little gain.
That is the idea.
Reply With Quote
  #7   (View Single Post)  
Old 21st October 2008
phoenix's Avatar
phoenix phoenix is offline
Risen from the ashes
 
Join Date: May 2008
Posts: 699
Thanked 90 Times in 81 Posts
Default

Quote:
Originally Posted by killasmurf86 View Post
wtf is that?
No need to curse. That's the recommended method for those that want to build kernels based on GENERIC, in such a way that any updates to GENERIC are also updates to their kernel.

Just include GENERIC in the config file. Any devices/options you don't want, you disable via nodevice/nooption. That way, when devices/options are added to GENERIC they are automatically added to your custom kernel as well.

See the SMP config file for the include syntax.
__________________
Freddie

Help for FreeBSD: Handbook, FAQ, man pages, mailing lists.
Reply With Quote
  #8   (View Single Post)  
Old 21st October 2008
phoenix's Avatar
phoenix phoenix is offline
Risen from the ashes
 
Join Date: May 2008
Posts: 699
Thanked 90 Times in 81 Posts
Default

Quote:
Originally Posted by KernelPanic View Post
For my custom SMP kernel I suck in GENERIC and then do the following:

# Old CPUs
nocpu I486_CPU
nocpu I586_CPU
Leave i586. It enables some in-kernel copy speedup functions. Improves memory allocations and copying of data around in the kernel. Don't remember the specifics of it, but it's faster than just i686.
__________________
Freddie

Help for FreeBSD: Handbook, FAQ, man pages, mailing lists.
Reply With Quote
  #9   (View Single Post)  
Old 21st October 2008
graudeejs's Avatar
graudeejs graudeejs is offline
Real Name: Aldis Berjoza
formerly killasmurf86
 
Join Date: Jul 2008
Location: Riga, Latvia
Posts: 588
Thanked 29 Times in 26 Posts
Default

Quote:
Originally Posted by phoenix View Post
No need to curse.
sorry mate [Shame on me]
Reply With Quote
Old 21st October 2008
TerryP's Avatar
TerryP TerryP is offline
Arp Constable
 
Join Date: May 2008
Location: USofA
Posts: 1,547
Thanked 112 Times in 104 Posts
Default

Eh, stupid question...

'include GENERIC' as in the sense of actually puting that in the file, or # cat GENERIC CUSTOM > THEKERNCONF
__________________
My Journal

Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''.
Reply With Quote
Old 22nd October 2008
phoenix's Avatar
phoenix phoenix is offline
Risen from the ashes
 
Join Date: May 2008
Posts: 699
Thanked 90 Times in 81 Posts
Default

Have a look at the SMP kernel config file. It's basically 3 lines: 1 to include GENERIC, 1 for SMP, and one for APIC.
__________________
Freddie

Help for FreeBSD: Handbook, FAQ, man pages, mailing lists.
Reply With Quote
Old 22nd October 2008
TerryP's Avatar
TerryP TerryP is offline
Arp Constable
 
Join Date: May 2008
Location: USofA
Posts: 1,547
Thanked 112 Times in 104 Posts
Default

The generic kernel is an SMP kernel now, but taking a quick grep of PAE, I see what you mean -> sorry, and thanks!
__________________
My Journal

Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''.
Reply With Quote
Old 24th October 2008
phoenix's Avatar
phoenix phoenix is offline
Risen from the ashes
 
Join Date: May 2008
Posts: 699
Thanked 90 Times in 81 Posts
Default

Hrm, you're right. Somehow I missed that change (GENERIC going SMP).
__________________
Freddie

Help for FreeBSD: Handbook, FAQ, man pages, mailing lists.
Reply With Quote
Old 24th October 2008
richardpl richardpl is offline
Spam Deminer
 
Join Date: May 2008
Location: Croatia
Posts: 284
Thanked 25 Times in 24 Posts
Default

Quote:
Originally Posted by phoenix View Post
Leave i586. It enables some in-kernel copy speedup functions. Improves memory allocations and copying of data around in the kernel. Don't remember the specifics of it, but it's faster than just i686.
Are you sure, do you have more information about this?
Only interesting info I found is about npx(4) and i586, and that is applicable for older machines. I use core2 CPU without i586, and performance is not decreased comparing with GENERIC.
Reply With Quote
Old 24th October 2008
phoenix's Avatar
phoenix phoenix is offline
Risen from the ashes
 
Join Date: May 2008
Posts: 699
Thanked 90 Times in 81 Posts
Default

There's a thread about this from 2005 that shows memory accesses to be faster on P3 CPUs when I586_CPU and I686_CPU are enabled in the kernel config, compared to just I686_CPU.

Doing a google search for "matt dillon I586_CPU" brings up more hits.

It seems I585_CPU enables a few features that I686_CPU doesn't, even on CPUs newer than the Pentium.
__________________
Freddie

Help for FreeBSD: Handbook, FAQ, man pages, mailing lists.
Reply With Quote
Old 24th October 2008
richardpl richardpl is offline
Spam Deminer
 
Join Date: May 2008
Location: Croatia
Posts: 284
Thanked 25 Times in 24 Posts
Default

That is obsolete information (there is no hard evidence), but I will explore this.
Reply With Quote
Old 24th October 2008
TerryP's Avatar
TerryP TerryP is offline
Arp Constable
 
Join Date: May 2008
Location: USofA
Posts: 1,547
Thanked 112 Times in 104 Posts
Default

Please post back or sort a thread if you turn anything (recent) up richard, thanks.
__________________
My Journal

Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''.
Reply With Quote
Old 24th October 2008
phoenix's Avatar
phoenix phoenix is offline
Risen from the ashes
 
Join Date: May 2008
Posts: 699
Thanked 90 Times in 81 Posts
Default

It might be "obsolete" in that it is old, but there hasn't been any mention of enabling bcopy and similar operations in the FreeBSD kernel when using I686_CPU. Granted, this may not make a difference on Athlon64/Opteron/Core/Core2 CPUs. I haven't heard/read anything about this subject since that thread, though. Guess someone with access to a few different CPUs will have to benchmark kernels with combinations of I586_CPU and I686_CPU.
__________________
Freddie

Help for FreeBSD: Handbook, FAQ, man pages, mailing lists.
Reply With Quote
Old 27th October 2008
richardpl richardpl is offline
Spam Deminer
 
Join Date: May 2008
Location: Croatia
Posts: 284
Thanked 25 Times in 24 Posts
Default

Here is short overview where I586_CPU is used in kernel:

http://fxr.watson.org/fxr/search?string=586_CPU

I can't see anything that 586 have and that 686 lack.
Reply With Quote
Old 28th October 2008
phoenix's Avatar
phoenix phoenix is offline
Risen from the ashes
 
Join Date: May 2008
Posts: 699
Thanked 90 Times in 81 Posts
Default

This page shows all the different copy functions configured when I586_CPU is enabled. There are no entries for I686_CPU in there, which tells me that all the optimisations are enabled for I585_CPU and not for I686_CPU. Haven't looked through any of the other pages in that list just yet.
__________________
Freddie

Help for FreeBSD: Handbook, FAQ, man pages, mailing lists.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
optimizations in kernel and apps chill FreeBSD General 5 1st October 2008 05:49 AM
quick question about optimizations in /etc/make.conf thevirtuesofxen FreeBSD Installation and Upgrading 7 15th July 2008 10:29 AM


All times are GMT. The time now is 11:29 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick