Re: ZFS committed to the FreeBSD base.
- From: "Rick C. Petty" <rick-freebsd@xxxxxxxxxxxxxxxxx>
- Date: Thu, 12 Apr 2007 11:06:03 -0500
On Thu, Apr 12, 2007 at 10:54:17AM +0200, Dag-Erling Sm?rgrav wrote:
Our native atomic operations are all defined as either macros or
static inline functions in machine/atomic.h, so we can easily make
this choice at compile time based on a config option.
Is there any way we could make the choice at boot time, by checking for
presence of the CX8 feature? Either as something like:
extern int feature_cx8; /* or MIB variable */
#define CMPXCHG8(a) (feature_cx8 ? { _asm "..." } : emulate_cmpxch8(a))
Otherwise something like ZFS which utilizes this feature a lot could
check the MIB variable and set different fn ptr in its device structure,
or something along those lines. Of course, that would require compiling
the same code twice essentially, but it had the advantage that it would
work on non-CX8 systems and that it would be fast on systems with CX8.
-- Rick C. Petty
_______________________________________________
freebsd-current@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscribe@xxxxxxxxxxx"
- Follow-Ups:
- Re: ZFS committed to the FreeBSD base.
- From: Daniel Cheng
- Re: ZFS committed to the FreeBSD base.
- From: Craig Boston
- Re: ZFS committed to the FreeBSD base.
- References:
- ZFS committed to the FreeBSD base.
- From: Pawel Jakub Dawidek
- Re: ZFS committed to the FreeBSD base.
- From: Dag-Erling Smørgrav
- Re: ZFS committed to the FreeBSD base.
- From: Bernd Walter
- Re: ZFS committed to the FreeBSD base.
- From: Dag-Erling Smørgrav
- Re: ZFS committed to the FreeBSD base.
- From: David Schultz
- Re: ZFS committed to the FreeBSD base.
- From: Peter Jeremy
- Re: ZFS committed to the FreeBSD base.
- From: Dag-Erling Smørgrav
- ZFS committed to the FreeBSD base.
- Prev by Date: twa(4) panics upon load
- Next by Date: Re: CPU utilization
- Previous by thread: Re: ZFS committed to the FreeBSD base.
- Next by thread: Re: ZFS committed to the FreeBSD base.
- Index(es):