time-to-botec/C/README.md

17 lines
1010 B
Markdown
Raw Normal View History

2023-06-02 22:00:49 +00:00
# Time to BOTEC in C
This repository contains a few implementations of a simple botec (back-of-the-envelope) calculation in C:
2023-06-02 22:26:05 +00:00
- In the folder C-01-simple/, you can see a simple implementation, which passes large arrays around
2023-06-02 22:00:49 +00:00
- In the folder C-02-better-algorithm-one-thread/ you can see a better implementations, that passes around pointers to functions, which makes the implementation more efficient
2023-06-02 22:26:05 +00:00
- The top level samples.c uses the algorithm improvements in C-02..., and also implements multithreading using OpenMP
2023-06-02 22:00:49 +00:00
## To do
- [ ] Add Windows/Powershell time-measuring commands
- [ ] Add CUDA?
2023-06-03 07:42:48 +00:00
- [x] Added results of perf. `rand_r` seems like a big chunk of it, but I'm hesitant to use lower-quality random numbers
2023-06-02 22:25:03 +00:00
- [x] Update repository with correct timing
2023-06-02 22:00:49 +00:00
- [x] Use better profiling approach to capture timing with 1M samples.
- [x] See if program can be reworded so as to use multithreading effectively, e.g., so that you see speed gains proportional to the number of threads used