https://github.com/kautenja/fast-cpu-transpose
A parallel, recursive, and cache-oblivious Matrix initialization and transposition method
https://github.com/kautenja/fast-cpu-transpose
cache-oblivious matrix parallel-algorithm recursive-transpose
Last synced: 6 months ago
JSON representation
A parallel, recursive, and cache-oblivious Matrix initialization and transposition method
- Host: GitHub
- URL: https://github.com/kautenja/fast-cpu-transpose
- Owner: Kautenja
- License: mit
- Created: 2017-11-07T16:41:23.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2020-08-05T23:00:07.000Z (about 5 years ago)
- Last Synced: 2025-02-14T10:18:26.942Z (8 months ago)
- Topics: cache-oblivious, matrix, parallel-algorithm, recursive-transpose
- Language: Jupyter Notebook
- Homepage:
- Size: 2.8 MB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Fast CPU Transpose
[![Build Status][build-status]][build-server]
[build-status]: https://travis-ci.org/Kautenja/fast-cpu-transpose.svg?branch=master
[build-server]: https://travis-ci.org/Kautenja/fast-cpu-transposeCompleted for Lab 3 of COMP7300, Advanced Computer Architecture, at Auburn University.
## Usage
### Compilation
The code uses threads with `-pthread` flag. The usage of the `-Ofast` flag
enables all compile-time optimizations.```shell
cc -Ofast -pthread -o
```##### Example
```shell
cc -Ofast -pthread rowwise.c -o rowwise
```### Test Automation
The 5 test runs are automated with a shell script. Make sure the permissions
are set correctly first by executing the following from the top level of the
project:```shell
chmod 0755 ./run.sh
```A test can be executed using the following command from the top level:
```shell
./run.sh
```This will route the shell output to a file in the [`build`](./build) directory
called `.out`. Note that the `.c` **IS NOT** included in this
command.##### Example
To run the default provided code (adjusted for 7 tests):
```shell
./run.sh myInitializeMatrix
```#### [`rowwise.c`](./rowwise.c)
contains the code for row-wise initialization and transpose. To compile and run
the row-wise initialization (and optimized transposition):```shell
mkdir -p build
cc -Ofast -pthread rowwise.c -o build/rowwise
./build/rowwise
```To compile and run the 5 consecutive tests saving the output to a file:
```shell
./run.sh rowwise
```#### [`columnwise.c`](columnwise.c)
contains the code for column-wsie intialization and transpose. To compile and
run the column-wise initialization (and optimized transposition):```shell
mkdir -p build
cc -Ofast -pthread columnwise.c -o build/columnwise
./build/columnwise
```To compile and run the 5 consecutive tests saving the output to a file:
```shell
./run.sh columnwise
```