This project implements a parallelized Trie library, PTrie, on CUDA to search for DNA patterns in a given text file. The program supports both parallel (GPU-based) and sequential (CPU-based) implementations to evaluate the speedup (CPU Time / GPU Time)
- Ensure having CUDA installed on the system
- To compile the program, run:
make
- After compiling, run the program with the following command:
./main <mode> <text_filename> <pattern_filename> <blockSize> - Commend-line arguments
<mode>:0: Run the parallel implementation (PTrie library) on the GPU1: Run the sequential implementation on the CPU
<text_filename>:- Path the the file containing the DNA text sequence
- Example:
DNA_text_100000000.txt
<pattern_filename>:- Path to the file containing DNA patterns to search for
- Example:
Patterns_3bp_10.txt
<blockSize>:- Only for parallel mode; this value does not affect the sequential code (
mode 0) - The size of each CUDA block, which determines GPU thread grouping
- Example: 256
- Only for parallel mode; this value does not affect the sequential code (