https://github.com/kayess/cpp-designing4performance
Slides and code for my talk at Pacific++ in 2018
https://github.com/kayess/cpp-designing4performance
conference-talk cpp17 example-code pacificplusplus pgasio postgres
Last synced: about 1 month ago
JSON representation
Slides and code for my talk at Pacific++ in 2018
- Host: GitHub
- URL: https://github.com/kayess/cpp-designing4performance
- Owner: KayEss
- License: other
- Created: 2018-10-23T00:36:11.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-10-23T10:03:04.000Z (over 7 years ago)
- Last Synced: 2025-01-08T16:07:51.706Z (over 1 year ago)
- Topics: conference-talk, cpp17, example-code, pacificplusplus, pgasio, postgres
- Language: C++
- Size: 682 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Designing APIs For Performance
This repository contains the code, scripts and slides for the talk at Pacific++ 2018.
The actual code that was run is in the `real` folder, and the code for the slides is in the `slides` folder.
## Building
Normal cmake rules apply:
```bash
git clone --recursive git@github.com:KayEss/cpp-designing4performance.git
mkdir cpp-designing4performance/build.tmp; cd cpp-designing4performance/build.tmp
ccmake .. -DCMAKE_BUILD_TYPE=Release -G Ninja
ninja
```
## The data
First you should get Postgres configured so that ident authentication works. You can check if this is the case or not by just typing `psql` and seeing if you can access the server without any further options.
On an Ubuntu machine something like the following should work (a superuser role):
```bash
sudo -u postgres createuser -ls $LOGNAME
sudo -u postgres createdb -o $LOGNAME $LOGNAME
psql
```
The command lines can be found in the slides. They assume the build directory is the current working directory.
### Movies
The film list is from the [daily list export](https://developers.themoviedb.org/3/getting-started/daily-file-exports) from [The Movie DB](https://www.themoviedb.org/). You'll need to fix up the file name in [movies/makedata.py](./movies/makedata.py). You'll also need to install the Python packages outlined in [movies/setup.pip](./movies/setup.pip). Running `pip install -r setup.pip` from that directory should suffice (assumes Python 3 is the default).
### `pgbench`
Use pgbench to create the table and data for the `pgbench_accounts`. For the talk the following was used:
```bash
pgbench -i -s 20
```