Re: FreeBSD cache memory allocation

2007-11-14 Thread icantthinkofone

Heiko Wundram (Beenic) wrote:

Am Mittwoch, 14. November 2007 17:04:37 schrieb icantthinkofone:
  

Ivan Voras wrote:


icantthinkofone wrote:
  

Someone I can't stand said this about FreeBSD.  Though I know C, I don't
know anything about it and would love to respond.
[QUOTE]The kernel is really lacking some features. They need a method to
set precise type of memory cache but BSD doesn't provide way to specify
memory cache.

For that reason MS has the beautiful
MmAllocateContigousMemorySpecifyCache()[/QUOTE]


Well, I know there's contigmalloc(9) in FreeBSD but you will get a
better answer if you ask this question on [EMAIL PROTECTED]
  

That's what I thought but not sure if they were equivalent.
I'm not signed up over there but I will now.  Thanks.



That's not entirely true. MmAllocateContiguousMemorySpecifyCache does 
something that's currently not (easily) possible with FreeBSD, namely set up 
an MTRR entry (i.e. a specific caching state) specifically for the portion of 
contiguous memory being allocated (normally, the driver wants to set the 
memory to uncached if using this call).


This is something that the NVIDIA driver development guys have wanted to have 
for a long time (for performance reasons) in the FreeBSD kernel, and there's 
someone developing a patch to implement this (AFAICT from reading some 
websites), but it doesn't seem like it's finished so far.


Read up on the NVIDIA requirements to develop an accelerated graphics driver 
on AMD64 to get more details on this (there's a "workaround" on i386, but 
that depends on the specific system's pre-setup MTRR records from the BIOS; 
this one of the reasons there's an accelerated graphics driver for i386 and 
not for AMD64).


  
I thought that might be the case.  (I did ask about this on 'hackers'). 
Is it possible Nvidia is trying to make FreeBSD work like Windows, in a 
sense?  iow, they used this function in their driver and now everyone 
has to use it?  Or is this really a fault of FreeBSD?

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: FreeBSD cache memory allocation

2007-11-14 Thread Heiko Wundram (Beenic)
Am Mittwoch, 14. November 2007 17:04:37 schrieb icantthinkofone:
> Ivan Voras wrote:
> > icantthinkofone wrote:
> >> Someone I can't stand said this about FreeBSD.  Though I know C, I don't
> >> know anything about it and would love to respond.
> >> [QUOTE]The kernel is really lacking some features. They need a method to
> >> set precise type of memory cache but BSD doesn't provide way to specify
> >> memory cache.
> >>
> >> For that reason MS has the beautiful
> >> MmAllocateContigousMemorySpecifyCache()[/QUOTE]
> >
> > Well, I know there's contigmalloc(9) in FreeBSD but you will get a
> > better answer if you ask this question on [EMAIL PROTECTED]
>
> That's what I thought but not sure if they were equivalent.
> I'm not signed up over there but I will now.  Thanks.

That's not entirely true. MmAllocateContiguousMemorySpecifyCache does 
something that's currently not (easily) possible with FreeBSD, namely set up 
an MTRR entry (i.e. a specific caching state) specifically for the portion of 
contiguous memory being allocated (normally, the driver wants to set the 
memory to uncached if using this call).

This is something that the NVIDIA driver development guys have wanted to have 
for a long time (for performance reasons) in the FreeBSD kernel, and there's 
someone developing a patch to implement this (AFAICT from reading some 
websites), but it doesn't seem like it's finished so far.

Read up on the NVIDIA requirements to develop an accelerated graphics driver 
on AMD64 to get more details on this (there's a "workaround" on i386, but 
that depends on the specific system's pre-setup MTRR records from the BIOS; 
this one of the reasons there's an accelerated graphics driver for i386 and 
not for AMD64).

-- 
Heiko Wundram
Product & Application Development
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: FreeBSD cache memory allocation

2007-11-14 Thread icantthinkofone

Ivan Voras wrote:

icantthinkofone wrote:
  

Someone I can't stand said this about FreeBSD.  Though I know C, I don't
know anything about it and would love to respond.
[QUOTE]The kernel is really lacking some features. They need a method to
set precise type of memory cache but BSD doesn't provide way to specify
memory cache.

For that reason MS has the beautiful
MmAllocateContigousMemorySpecifyCache()[/QUOTE]



Well, I know there's contigmalloc(9) in FreeBSD but you will get a
better answer if you ask this question on [EMAIL PROTECTED]

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

  
That's what I thought but not sure if they were equivalent. 
I'm not signed up over there but I will now.  Thanks.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: FreeBSD cache memory allocation

2007-11-14 Thread Ivan Voras
icantthinkofone wrote:
> Someone I can't stand said this about FreeBSD.  Though I know C, I don't
> know anything about it and would love to respond.
> [QUOTE]The kernel is really lacking some features. They need a method to
> set precise type of memory cache but BSD doesn't provide way to specify
> memory cache.
> 
> For that reason MS has the beautiful
> MmAllocateContigousMemorySpecifyCache()[/QUOTE]

Well, I know there's contigmalloc(9) in FreeBSD but you will get a
better answer if you ask this question on [EMAIL PROTECTED]

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


FreeBSD cache memory allocation

2007-11-13 Thread icantthinkofone
Someone I can't stand said this about FreeBSD.  Though I know C, I don't 
know anything about it and would love to respond.
[QUOTE]The kernel is really lacking some features. They need a method to 
set precise type of memory cache but BSD doesn't provide way to specify 
memory cache.


For that reason MS has the beautiful 
MmAllocateContigousMemorySpecifyCache()[/QUOTE]

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"