Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 31 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,34 @@
**University of Pennsylvania, CIS 565: GPU Programming and Architecture,
Project 1 - Flocking**
Project 1 - Flocking
====================
**University of Pennsylvania, CIS 565: GPU Programming and Architecture**

* (TODO) YOUR NAME HERE
* (TODO) [LinkedIn](), [personal website](), [twitter](), etc.
* Tested on: (TODO) Windows 22, i7-2222 @ 2.22GHz 22GB, GTX 222 222MB (Moore 2222 Lab)
Dhruv Karthik: [LinkedIn](https://www.linkedin.com/in/dhruv_karthik/)

### (TODO: Your README)
Tested on: Windows 10 Home, Intel(R) Core(TM) i7-8700 CPU @ 3.20GHz, 16GM, GTX 2070 - Compute Capability 7.5
____________________________________________________________________________________
![Developer](https://img.shields.io/badge/Developer-Dhruv-0f97ff.svg?style=flat) ![CUDA 10.1](https://img.shields.io/badge/CUDA-10.1-yellow.svg) ![Built](https://img.shields.io/appveyor/ci/gruntjs/grunt.svg) ![Issues](https://img.shields.io/badge/issues-none-green.svg)
____________________________________________________________________________________

Include screenshots, analysis, etc. (Remember, this is public, so don't put
anything here that you don't want to share with the world.)
| 10,000 Boids | 70,000 Boids |
| ------------- | ----------- |
| ![](images/10KBoids.gif) | ![](images/70kboids.gif) |

# Runtime Analysis
![FPS w/ Visuals Increasing Num_Boids](images/fpsnumboids_vis.png)
![FPS w/ Visuals Increasing BlockSize](images/fpsblocksize_vis.png)
![FPS w/ NoVisuals Increasing Num_Boids](images/fpsnumboids_novis.png)
![FPS w/ NoVisuals Increasing BlockSize](images/fpsblocksize_novis.png)

# Questions
**For each implementation, how does changing the number of boids affect performance? Why do you think this is?**
On average, more boids decreased the performance.
1. *Naive*: More boids directly increases the iters of the for loop that iterates over all the boids, thereby increasing runtime
2. *Scattered & Coherent*: While better than the Naive algorithm, both of these algorithms would suffer if several boids were clustered together. High boid density in certain cells would increase the runtime of the for loop iterating over all boids.

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

Negligible, and uncorellated. However, the coherent grid consistently performed twice as well as the scattered grid.

**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?**

I expected performance improvements, but not to this level. I was surpised by the fact that merely not indexing into another array could provide (on occasion) almost double the runtime. However, I later learnt that memory access adds a large overhead to
Binary file added images/10KBoids.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/70kboids.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/fpsblocksize_novis.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/fpsblocksize_vis.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/fpsnumboids_novis.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/fpsnumboids_vis.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/glslUtility.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* @file glslUtility.cpp
* @brief A utility namespace for loading GLSL shaders.
* @authors Varun Sampath, Patrick Cozzi, Karl Li
* @authors Varun Sampath, Patrick Cozzi, Karl L
* @date 2012
* @copyright University of Pennsylvania
*/
Expand Down
Loading