Skip to content

WeiyuDu/Project1-CUDA-Flocking

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

42 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

University of Pennsylvania, CIS 565: GPU Programming and Architecture, Project 1 - Flocking

  • Weiyu Du
  • Tested on: CETS virtual lab MOR100B-09, Intel(R) Core(TM) i7-6700 CPU @ 3.40GHz

Boids Simulation

Performance Analysis

  1. Plot of number of boids versus frame rate without visualization (x axis: 5000, 10000, 20000, 50000)

2) Plot of number of boids versus frame rate with visualization (x axis: 5000, 10000, 20000, 50000)

3) Plot of block size versus frame rate (without visualization, x axis: 128, 256, 512, 1024)

Questions

  1. For each implementation, how does changing the number of boids affect performance? Why do you think this is?

Performance decreases as the number of boids increases. This is because more boids require more threads for kernels that require significant operations, for example kernUpdateVelNeighborSearch, kernUpdatePos, kernComputeIndices.

  1. For each implementation, how does changing the block count and block size affect performance? Why do you think this is?

Performance does not change as block size increase. This is because larger block size would only require more threads for kernels that have very simple operation, for example kernResetIntBuffer.

  1. For the coherent uniform grid: did you experience any performance improvements with the more coherent uniform grid? Was this the outcome you expected? Why or why not?

Yes, I experienced performance improvements with coherent uniform grid from scattered grid, but not as significant as from naive to scattered grid. This is the outcome I expect because we cut out the time to access dev_particleArrayIndices memory for each thread, which improves performance.

  1. Did changing cell width and checking 27 vs 8 neighboring cells affect performance? Why or why not?

It does not affect performance much. We still have the same number of threads.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Cuda 42.1%
  • C++ 38.5%
  • CMake 17.4%
  • Other 2.0%