Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Jun 1997 13:39:20 +0930 (CST)
From:      Michael Smith <msmith@atrad.adelaide.edu.au>
To:        mcgovern@spoon.beta.com (Brian J. McGovern)
Cc:        hackers@FreeBSD.ORG
Subject:   Re: Need help with fastest way to move data...
Message-ID:  <199706040409.NAA11449@genesis.atrad.adelaide.edu.au>
In-Reply-To: <199706040229.WAA21318@spoon.beta.com> from "Brian J. McGovern" at "Jun 3, 97 10:29:06 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
Brian J. McGovern stands accused of saying:
>
> Now, the big question... Is this the most efficient way to do this?
> Does memcpy and the like work best on long-aligned values. Would it
> be even MORE efficient to use larger structures, given sufficient
> data to move?

The best way to go is :

 - establish the largest linear chunk you can move.
 - call bcopy to move it.
 - repeat until done.

> I'm curious to hear comments, and see if anyone has any truely cool ideas.

Leave worrying about alignment etc. to the primitives; the moment you leave
the original platform everything is going to change anyway.

> 	-Brian

-- 
]] Mike Smith, Software Engineer        msmith@gsoft.com.au             [[
]] Genesis Software                     genesis@gsoft.com.au            [[
]] High-speed data acquisition and      (GSM mobile)     0411-222-496   [[
]] realtime instrument control.         (ph)          +61-8-8267-3493   [[
]] Unix hardware collector.             "Where are your PEZ?" The Tick  [[



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199706040409.NAA11449>