Click here to Skip to main content
15,920,217 members
Home / Discussions / Algorithms
   

Algorithms

 
GeneralRe: Plotting large amount of data points Pin
cp987616-Oct-07 14:52
cp987616-Oct-07 14:52 
GeneralRe: Plotting large amount of data points Pin
Ri Qen-Sin23-Oct-07 14:59
Ri Qen-Sin23-Oct-07 14:59 
GeneralA Prayer for Archimedes Pin
Bassam Abdul-Baki10-Oct-07 6:44
professionalBassam Abdul-Baki10-Oct-07 6:44 
GeneralRe: A Prayer for Archimedes Pin
IdUnknown10-Oct-07 7:16
IdUnknown10-Oct-07 7:16 
GeneralRe: A Prayer for Archimedes Pin
Bassam Abdul-Baki10-Oct-07 7:26
professionalBassam Abdul-Baki10-Oct-07 7:26 
Questionfill memory with a pattern Pin
DQNOK10-Oct-07 5:21
professionalDQNOK10-Oct-07 5:21 
AnswerRe: fill memory with a pattern Pin
DQNOK11-Oct-07 7:35
professionalDQNOK11-Oct-07 7:35 
AnswerRe: fill memory with a pattern Pin
Alan Balkany24-Oct-07 4:13
Alan Balkany24-Oct-07 4:13 
You can use destructive overlap to write your fill pattern as fast as your CPU can go. Here's the algorithm:

1. Copy one instance of the pattern to target.
2. Copy memory from target to (target + patlen) with length (numRepeats - 1) * patlen. (This is one function call.)

I believe this is the most efficient algorithm possible. The implementation of memcpy will probably be more efficient than anything you could write in a higher-level language. Also you're copying from addresses you just wrote to, so they'll already be in the cache. This lets the CPU avoid getting these bytes from (relatively) slow external memory chips. This algorithm should fly like the wind!
GeneralRe: fill memory with a pattern Pin
DQNOK24-Oct-07 10:33
professionalDQNOK24-Oct-07 10:33 
GeneralRe: fill memory with a pattern Pin
DQNOK25-Oct-07 3:41
professionalDQNOK25-Oct-07 3:41 
QuestionAlgorithm to check how different are two files? Pin
bosfan9-Oct-07 22:01
bosfan9-Oct-07 22:01 
AnswerRe: Algorithm to check how different are two files? Pin
cp98769-Oct-07 22:56
cp98769-Oct-07 22:56 
GeneralRe: Algorithm to check how different are two files? Pin
bosfan9-Oct-07 23:18
bosfan9-Oct-07 23:18 
AnswerRe: Algorithm to check how different are two files? Pin
ScottM111-Oct-07 2:07
ScottM111-Oct-07 2:07 
GeneralRe: Algorithm to check how different are two files? Pin
ChandraRam11-Oct-07 2:25
ChandraRam11-Oct-07 2:25 
GeneralRe: Algorithm to check how different are two files? Pin
ScottM124-Oct-07 3:59
ScottM124-Oct-07 3:59 
AnswerRe: Algorithm to check how different are two files? Pin
chandu00413-Oct-07 0:30
chandu00413-Oct-07 0:30 
AnswerRe: Algorithm to check how different are two files? Pin
Gesown16-Oct-07 6:20
professionalGesown16-Oct-07 6:20 
Questiongenetic algorithms for image generation? Pin
Juraj Borza9-Oct-07 9:56
Juraj Borza9-Oct-07 9:56 
AnswerRe: genetic algorithms for image generation? Pin
Stan F. Form13-Oct-07 3:16
Stan F. Form13-Oct-07 3:16 
AnswerRe: genetic algorithms for image generation? Pin
Marshall15-Oct-07 9:26
Marshall15-Oct-07 9:26 
AnswerRe: genetic algorithms for image generation? Pin
Alan Balkany24-Oct-07 4:24
Alan Balkany24-Oct-07 4:24 
QuestionA simple question Pin
Ennis Ray Lynch, Jr.9-Oct-07 3:53
Ennis Ray Lynch, Jr.9-Oct-07 3:53 
AnswerRe: A simple question Pin
El Corazon9-Oct-07 4:47
El Corazon9-Oct-07 4:47 
GeneralRe: A simple question Pin
Ennis Ray Lynch, Jr.9-Oct-07 5:23
Ennis Ray Lynch, Jr.9-Oct-07 5:23 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.