Commit 6c41bb6f authored by Jens Korinth's avatar Jens Korinth
Browse files

Rebranding ThreadPoolComposer -> TaPaSCo

parent 7be62ffb
ThreadPoolComposer -- Getting Started Part 2 (Zynq) Tapasco -- Getting Started Part 2 (Zynq)
=================================================== ===================================================
This is the second part of the TPC tutorial, concerned with the Zynq platforms This is the second part of the TPC tutorial, concerned with the Zynq platforms
only. In this part we will load the bitstream generated in Part 1 to the FPGA only. In this part we will load the bitstream generated in Part 1 to the FPGA
...@@ -11,59 +11,59 @@ Preparing the system ...@@ -11,59 +11,59 @@ Preparing the system
By default, the TPC linux image has two users: By default, the TPC linux image has two users:
1. `root` (passwd: `root`) 1. `root` (passwd: `root`)
2. `tpc` (passwd: `tpctpc`) 2. `tapasco` (passwd: `tapascotapasco`)
Obviously this is an extremely insecure setup and should be changed immediately. Obviously this is an extremely insecure setup and should be changed immediately.
Login as `root`, then use the `passwd` program to change the root password. Login as `root`, then use the `passwd` program to change the root password.
Repeat for user `tpc`. Repeat for user `tapasco`.
The user `tpc` is `sudoer`, i.e., you can use the `sudo` program to temporarily The user `tapasco` is `sudoer`, i.e., you can use the `sudo` program to temporarily
gain root privileges. This is sufficient for TPC, but feel free to configure gain root privileges. This is sufficient for TPC, but feel free to configure
the system in any way you like. the system in any way you like.
Preparing the TPC libaries and driver Preparing the TPC libaries and driver
------------------------------------- -------------------------------------
The ThreadPoolComposer software stack consists of three layers: The Tapasco software stack consists of three layers:
1. TPC(++) API (`libtpc.so` / `libtpc.a`) 1. TPC(++) API (`libtapasco.so` / `libtapasco.a`)
2. Platform API (`libplatform.so` / `libplatform.a`) 2. Platform API (`libplatform.so` / `libplatform.a`)
3. Device Driver (`tpc-platform-zynq.ko`) 3. Device Driver (`tapasco-platform-zynq.ko`)
When you are using TPC, you will only need to concern yourself with TPC API, When you are using TPC, you will only need to concern yourself with TPC API,
the other layers will be hidden from the application point of view. the other layers will be hidden from the application point of view.
Nevertheless, they need to be available to build and run the application. Nevertheless, they need to be available to build and run the application.
To simplify the building of the libraries, there is a script in `$TPC_HOME/bin` To simplify the building of the libraries, there is a script in `$TAPASCO_HOME/bin`
called `tpc-build-libs`. It will compile all three layers: called `tapasco-build-libs`. It will compile all three layers:
[tpc@zed] ~ tpc-build-libs [tapasco@zed] ~ tapasco-build-libs
This will build the libraries for the zedboard in Release mode, you should see This will build the libraries for the zedboard in Release mode, you should see
several lines of status logs, e.g.: several lines of status logs, e.g.:
Building release mode libraries, pass 'debug' as first argument to build debug libs... Building release mode libraries, pass 'debug' as first argument to build debug libs...
KCPPFLAGS="-DNDEBUG -O3" make -C /home/tpc/linux-xlnx M=/home/tpc/threadpoolcomposer/2016.03/platform/zynq/module modules KCPPFLAGS="-DNDEBUG -O3" make -C /home/tapasco/linux-xlnx M=/home/tapasco/tapasco/2016.03/platform/zynq/module modules
make[1]: Entering directory '/home/tpc/linux-xlnx' make[1]: Entering directory '/home/tapasco/linux-xlnx'
CC [M] /home/tpc/threadpoolcomposer/2016.03/platform/zynq/module/zynq_module.o CC [M] /home/tapasco/tapasco/2016.03/platform/zynq/module/zynq_module.o
CC [M] /home/tpc/threadpoolcomposer/2016.03/platform/zynq/module/zynq_device.o CC [M] /home/tapasco/tapasco/2016.03/platform/zynq/module/zynq_device.o
CC [M] /home/tpc/threadpoolcomposer/2016.03/platform/zynq/module/zynq_dmamgmt.o CC [M] /home/tapasco/tapasco/2016.03/platform/zynq/module/zynq_dmamgmt.o
CC [M] /home/tpc/threadpoolcomposer/2016.03/platform/zynq/module/zynq_irq.o CC [M] /home/tapasco/tapasco/2016.03/platform/zynq/module/zynq_irq.o
CC [M] /home/tpc/threadpoolcomposer/2016.03/platform/zynq/module/zynq_ioctl.o CC [M] /home/tapasco/tapasco/2016.03/platform/zynq/module/zynq_ioctl.o
LD [M] /home/tpc/threadpoolcomposer/2016.03/platform/zynq/module/tpc-platform-zynq.o LD [M] /home/tapasco/tapasco/2016.03/platform/zynq/module/tapasco-platform-zynq.o
Building modules, stage 2. Building modules, stage 2.
MODPOST 1 modules MODPOST 1 modules
CC /home/tpc/threadpoolcomposer/2016.03/platform/zynq/module/tpc-platform-zynq.mod.o CC /home/tapasco/tapasco/2016.03/platform/zynq/module/tapasco-platform-zynq.mod.o
LD [M] /home/tpc/threadpoolcomposer/2016.03/platform/zynq/module/tpc-platform-zynq.ko LD [M] /home/tapasco/tapasco/2016.03/platform/zynq/module/tapasco-platform-zynq.ko
make[1]: Leaving directory '/home/tpc/linux-xlnx' make[1]: Leaving directory '/home/tapasco/linux-xlnx'
... ...
TPC is now ready! By default, the script will build the libraries in release TPC is now ready! By default, the script will build the libraries in release
mode, but you can switch to debug mode easily: mode, but you can switch to debug mode easily:
[tpc@zed] ~ tpc-build-libs --mode debug [tapasco@zed] ~ tapasco-build-libs --mode debug
Logging features are enabled in debug mode only, see the Debugging chapter at Logging features are enabled in debug mode only, see the Debugging chapter at
the end of this document. See also `tpc-build-libs --help` for more info. the end of this document. See also `tapasco-build-libs --help` for more info.
Loading bitstreams Loading bitstreams
------------------ ------------------
...@@ -71,24 +71,24 @@ The next step is to copy the bitstreams (.bit files) we have prepared in Part 1 ...@@ -71,24 +71,24 @@ The next step is to copy the bitstreams (.bit files) we have prepared in Part 1
to the device. Once you have copied the .bit file to the board (e.g., via to the device. Once you have copied the .bit file to the board (e.g., via
`scp`), you need to load it to the FPGA, then load the driver. `scp`), you need to load it to the FPGA, then load the driver.
For convenience, there is a script called `tpc-load-bitstream` in `$TPC_HOME/bin` For convenience, there is a script called `tapasco-load-bitstream` in `$TAPASCO_HOME/bin`
that simplifies this process, which can be called like this: that simplifies this process, which can be called like this:
[tpc@zed] ~ tpc-load-bitstream --reload-driver <PATH TO .bit FILE> [tapasco@zed] ~ tapasco-load-bitstream --reload-driver <PATH TO .bit FILE>
It will ask for the `sudo` password of the user `tpc` (loading the bitstream It will ask for the `sudo` password of the user `tapasco` (loading the bitstream
and driver requires root privilege). On the zedboard there is a blue status LED and driver requires root privilege). On the zedboard there is a blue status LED
(left of the OLED display) that indicates whether or not a valid bitstream is (left of the OLED display) that indicates whether or not a valid bitstream is
configured in the FPGA. configured in the FPGA.
If everything goes well, you should see some log messages similar to this: If everything goes well, you should see some log messages similar to this:
~/threadpoolcomposer/2016.03/platform/zynq/module ~/threadpoolcomposer/2016.03 ~/tapasco/2016.03/platform/zynq/module ~/tapasco/2016.03
[sudo] password for tpc: [sudo] password for tapasco:
Loading bitstream /home/tpc/basic_test.bd.bit ... Loading bitstream /home/tapasco/basic_test.bd.bit ...
Done! Done!
Loading kernel module ... Loading kernel module ...
~/threadpoolcomposer/2016.03 ~/tapasco/2016.03
Done. Done.
On the zedboard there is a bright blue LED (left of the OLED display) that will On the zedboard there is a bright blue LED (left of the OLED display) that will
...@@ -104,14 +104,14 @@ stall if no device in the fabric answers. ...@@ -104,14 +104,14 @@ stall if no device in the fabric answers.
Compiling TPC(++) API programs Compiling TPC(++) API programs
------------------------------ ------------------------------
Continuing the example from Part 1, we will now compile the Rot13 application Continuing the example from Part 1, we will now compile the Rot13 application
located in `$TPC_HOME/kernel/rot13`. C/C++ builds in TPC use `cmake`, a located in `$TAPASCO_HOME/kernel/rot13`. C/C++ builds in TPC use `cmake`, a
cross-platform Makefile generator (see [1]). The pattern you see below repeats cross-platform Makefile generator (see [1]). The pattern you see below repeats
for all CMake projects: for all CMake projects:
[tpc@zed] cd $TPC_HOME/kernel/rot13 && mkdir -p build && cd build [tapasco@zed] cd $TAPASCO_HOME/kernel/rot13 && mkdir -p build && cd build
[tpc@zed] cmake -DCMAKE_BUILD_TYPE=Release .. && make [tapasco@zed] cmake -DCMAKE_BUILD_TYPE=Release .. && make
This will create a `build` subdirectory in which the `tpc_rot13` application is This will create a `build` subdirectory in which the `tapasco_rot13` application is
begin build. You can also compile in debug mode by using `cmake ..` instead. begin build. You can also compile in debug mode by using `cmake ..` instead.
-- The C compiler identification is GNU 5.3.0 -- The C compiler identification is GNU 5.3.0
...@@ -130,23 +130,23 @@ begin build. You can also compile in debug mode by using `cmake ..` instead. ...@@ -130,23 +130,23 @@ begin build. You can also compile in debug mode by using `cmake ..` instead.
-- Detecting CXX compile features - done -- Detecting CXX compile features - done
-- Configuring done -- Configuring done
-- Generating done -- Generating done
-- Build files have been written to: /home/tpc/threadpoolcomposer/2016.03/kernel/rot13/build -- Build files have been written to: /home/tapasco/tapasco/2016.03/kernel/rot13/build
Scanning dependencies of target tpc-rot13 Scanning dependencies of target tapasco-rot13
[ 25%] Building CXX object CMakeFiles/tpc-rot13.dir/tpc_rot13.cpp.o [ 25%] Building CXX object CMakeFiles/tapasco-rot13.dir/tapasco_rot13.cpp.o
[ 50%] Linking CXX executable tpc-rot13 [ 50%] Linking CXX executable tapasco-rot13
[ 50%] Built target tpc-rot13 [ 50%] Built target tapasco-rot13
Scanning dependencies of target rot13 Scanning dependencies of target rot13
[ 75%] Building CXX object CMakeFiles/rot13.dir/rot13.cpp.o [ 75%] Building CXX object CMakeFiles/rot13.dir/rot13.cpp.o
[100%] Linking CXX executable rot13 [100%] Linking CXX executable rot13
[100%] Built target rot13 [100%] Built target rot13
Now there should be a `tpc-rot13` executable. As a first argument, pass a text Now there should be a `tapasco-rot13` executable. As a first argument, pass a text
file to be ciphered; there is an ASCII version of the Shakespeare play file to be ciphered; there is an ASCII version of the Shakespeare play
"All\'s well that ends well" in `~/allswell.txt`. Let us test the application "All\'s well that ends well" in `~/allswell.txt`. Let us test the application
by enciphering it twice, this should give the original text back: by enciphering it twice, this should give the original text back:
[tpc@zed] ~/threadpoolcomposer/2016.03/kernel/rot13 $ ./tpc-rot13 ~/allswell.txt > test.txt [tapasco@zed] ~/tapasco/2016.03/kernel/rot13 $ ./tapasco-rot13 ~/allswell.txt > test.txt
[tpc@zed] ~/threadpoolcomposer/2016.03/kernel/rot13 $ ./tpc-rot13 test.txt [tapasco@zed] ~/tapasco/2016.03/kernel/rot13 $ ./tapasco-rot13 test.txt
If everything goes well, the plain text should appear on the screen now. If everything goes well, the plain text should appear on the screen now.
...@@ -155,10 +155,10 @@ TPC libraries, load bitstream and driver and compile TPC API applications. Of ...@@ -155,10 +155,10 @@ TPC libraries, load bitstream and driver and compile TPC API applications. Of
course this does not give a complete overview of TPC, but hopefully it provides course this does not give a complete overview of TPC, but hopefully it provides
a solid starting point to start exploring. The Rot13 application is simple a solid starting point to start exploring. The Rot13 application is simple
enough to explore the basics; a next step could be the `basic_test` example in enough to explore the basics; a next step could be the `basic_test` example in
`$TPC_HOME/examples/basic_test`. There is a TPC configuration for three basic `$TAPASCO_HOME/examples/basic_test`. There is a TPC configuration for three basic
testing kernels, which perform read, write and r+w accesses on main memory testing kernels, which perform read, write and r+w accesses on main memory
respectively. Check out the kernels `arraysum`, `arrayinit` and `arrayupdate` in respectively. Check out the kernels `arraysum`, `arrayinit` and `arrayupdate` in
`$TPC_HOME/kernel` and try to run the example. `$TAPASCO_HOME/kernel` and try to run the example.
Debugging Debugging
--------- ---------
...@@ -174,47 +174,47 @@ First of all, switch to the release mode libraries only towards the end, when ...@@ -174,47 +174,47 @@ First of all, switch to the release mode libraries only towards the end, when
your application is running and stable. Until then, use the debug libraries. your application is running and stable. Until then, use the debug libraries.
To compile the libraries in debug mode, use: To compile the libraries in debug mode, use:
[tpc@zed] ~ tpc-build-libs --mode debug [tapasco@zed] ~ tapasco-build-libs --mode debug
This will enable logging in the libraries. Logging is controlled by four This will enable logging in the libraries. Logging is controlled by four
environment variables: environment variables:
1. `LIBPLATFORM_DEBUG` 1. `LIBPLATFORM_DEBUG`
2. `LIBPLATFORM_LOGFILE` 2. `LIBPLATFORM_LOGFILE`
3. `LIBTPC_DEBUG` 3. `LIBTAPASCO_DEBUG`
4. `LIBTPC_LOGFILE` 4. `LIBTAPASCO_LOGFILE`
The `_DEBUG` variables are a bit mask for various parts of the libraries; you The `_DEBUG` variables are a bit mask for various parts of the libraries; you
can turn on debug information selectively for each part. See can turn on debug information selectively for each part. See
`$TPC_HOME/arch/common/include/tpc_logging.h` and `$TAPASCO_HOME/arch/common/include/tapasco_logging.h` and
`$TPC_HOME/platform/common/include/platform_logging.h` for further information. `$TAPASCO_HOME/platform/common/include/platform_logging.h` for further information.
You can simply turn on all logs by using You can simply turn on all logs by using
[tpc@zed] ~ export LIBPLATFORM_DEBUG=-1 [tapasco@zed] ~ export LIBPLATFORM_DEBUG=-1
[tpc@zed] ~ export LIBTPC_DEBUG=-1 [tapasco@zed] ~ export LIBTAPASCO_DEBUG=-1
The `_LOGFILE` variables can be used to redirect the log output to logfiles The `_LOGFILE` variables can be used to redirect the log output to logfiles
(instead of stdout), e.g.: (instead of stdout), e.g.:
[tpc@zed] ~ export LIBTPC_LOGFILE=/home/tpc/libtpc.log [tapasco@zed] ~ export LIBTAPASCO_LOGFILE=/home/tapasco/libtapasco.log
[tpc@zed] ~ export LIBPLATFORM_LOGFILE=/home/tpc/libplatform.log [tapasco@zed] ~ export LIBPLATFORM_LOGFILE=/home/tapasco/libplatform.log
Usually this level of debug information is sufficient. But in case something is Usually this level of debug information is sufficient. But in case something is
going wrong on the driver level, you can also compile the device driver in debug going wrong on the driver level, you can also compile the device driver in debug
mode like this: mode like this:
[tpc@zed] ~ cd $TPC_HOME && ./buildLibs.py driver_debug [tapasco@zed] ~ cd $TAPASCO_HOME && ./buildLibs.py driver_debug
This will activate another bitmask in the driver; you can access it via the This will activate another bitmask in the driver; you can access it via the
sysfs file `/sys/module/tpc_platform_zynq/parameters/logging_level`. To activate sysfs file `/sys/module/tapasco_platform_zynq/parameters/logging_level`. To activate
all debug messages use: all debug messages use:
[tpc@zed] ~ sudo sh -c 'echo -1 > /sys/module/tpc_platform_zynq/parameters/logging_level' [tapasco@zed] ~ sudo sh -c 'echo -1 > /sys/module/tapasco_platform_zynq/parameters/logging_level'
You can see the log messages in the system log, accessible via `dmesg`: You can see the log messages in the system log, accessible via `dmesg`:
[tpc@zed] ~ dmesg --follow [tapasco@zed] ~ dmesg --follow
Run this command in a separate shell and you can see the log message during the Run this command in a separate shell and you can see the log message during the
execution of your application. execution of your application.
...@@ -228,7 +228,7 @@ with minimal runtime overhead. But the Zynq CPUs are severely limited in terms ...@@ -228,7 +228,7 @@ with minimal runtime overhead. But the Zynq CPUs are severely limited in terms
of performance, so a performance hit will be measurable for library logging, too. of performance, so a performance hit will be measurable for library logging, too.
So, for benchmarking always use the release mode of driver and libraries. So, for benchmarking always use the release mode of driver and libraries.
We hope ThreadPoolComposer is useful to you and can help to get your FPGA We hope Tapasco is useful to you and can help to get your FPGA
research started as quickly as possible! If you use TPC in your research we research started as quickly as possible! If you use TPC in your research we
kindly ask that you cite our FCCM 2015 paper (see [2]) in your papers. kindly ask that you cite our FCCM 2015 paper (see [2]) in your papers.
Even more importantly, let us know about issues with TPC and share your Even more importantly, let us know about issues with TPC and share your
...@@ -240,5 +240,5 @@ directly via email. ...@@ -240,5 +240,5 @@ directly via email.
Have fun! Have fun!
[1]: https://cmake.org/documentation/ [1]: https://cmake.org/documentation/
[2]: http://www.esa.informatik.tu-darmstadt.de/twiki/bin/view/Downloads/ThreadPoolComposer.html [2]: http://www.esa.informatik.tu-darmstadt.de/twiki/bin/view/Downloads/Tapasco.html
[3]: https://git.esa.informatik.tu-darmstadt.de/REPARA/threadpoolcomposer [3]: https://git.esa.informatik.tu-darmstadt.de/REPARA/tapasco
ThreadPoolComposer -- Getting Started Tapasco -- Getting Started
===================================== =====================================
This document will walk you through an example bitstream creation with TPC. This document will walk you through an example bitstream creation with TPC.
But first we will discuss some basic terminology and explain how TPC works But first we will discuss some basic terminology and explain how TPC works
...@@ -98,7 +98,7 @@ description files: ...@@ -98,7 +98,7 @@ description files:
of desired instances. Can be provided inline in the _Configuration_. of desired instances. Can be provided inline in the _Configuration_.
5. _Configuration Descriptions_ (any name) 5. _Configuration Descriptions_ (any name)
Can be provided as command line arguments to `tpc`, or (more conveniently) Can be provided as command line arguments to `tapasco`, or (more conveniently)
in a separate file. Contains all parameters for the current _Configuration_; in a separate file. Contains all parameters for the current _Configuration_;
the _Configuration_ determines for which _Platforms_, _Architectures_ and the _Configuration_ determines for which _Platforms_, _Architectures_ and
_Compositions_ bitstreams shall be generated, and configures optional _Compositions_ bitstreams shall be generated, and configures optional
...@@ -113,7 +113,7 @@ description file. ...@@ -113,7 +113,7 @@ description file.
Directory Structure Directory Structure
------------------- -------------------
All paths in TPC can be reconfigured using _Configuration_ parameters, but when All paths in TPC can be reconfigured using _Configuration_ parameters, but when
nothing else is specified, the default directory structure below `$TPC_HOME` is nothing else is specified, the default directory structure below `$TAPASCO_HOME` is
used: used:
* `arch` * `arch`
...@@ -135,7 +135,7 @@ used: ...@@ -135,7 +135,7 @@ used:
Base directory for _Architectures_; will be searched for Base directory for _Architectures_; will be searched for
`architecture.description`s. `architecture.description`s.
There are some more directories in `$TPC_HOME`, but only TPC developers need to There are some more directories in `$TAPASCO_HOME`, but only TPC developers need to
concern themselves with them. As a TPC user it is sufficient to understand the concern themselves with them. As a TPC user it is sufficient to understand the
directory structure above. Each base path can be reconfigured in the directory structure above. Each base path can be reconfigured in the
_Configuration_, which is most useful for _Kernels_, e.g., to switch between _Configuration_, which is most useful for _Kernels_, e.g., to switch between
...@@ -150,12 +150,12 @@ letters of the latin alphabet by an offset of 13 (with wrap-around). There are ...@@ -150,12 +150,12 @@ letters of the latin alphabet by an offset of 13 (with wrap-around). There are
documented uses of this "encryption" in the Roman Empire, where it was documented uses of this "encryption" in the Roman Empire, where it was
(presumably) used to keep people from reading messages "over the shoulder". (presumably) used to keep people from reading messages "over the shoulder".
We will use `itpc` to create a configuration file for us, so start it: We will use `itapasco` to create a configuration file for us, so start it:
1. `itpc` 1. `itapasco`
TPC should greet you with a menu similar to this: TPC should greet you with a menu similar to this:
Welcome to interactive ThreadPoolComposer Welcome to interactive Tapasco
***************************************** *****************************************
What would you like to do? What would you like to do?
...@@ -203,7 +203,7 @@ We will use `itpc` to create a configuration file for us, so start it: ...@@ -203,7 +203,7 @@ We will use `itpc` to create a configuration file for us, so start it:
l: rot13 l: rot13
Your choice: Your choice:
6. Next step is to build the composition, `itpc` lists the available _Kernels_ 6. Next step is to build the composition, `itapasco` lists the available _Kernels_
and _Cores_, choose `rot13` via the corresponding key. and _Cores_, choose `rot13` via the corresponding key.
Number of instances[> 0]: Number of instances[> 0]:
...@@ -215,7 +215,7 @@ We will use `itpc` to create a configuration file for us, so start it: ...@@ -215,7 +215,7 @@ We will use `itpc` to create a configuration file for us, so start it:
b: false b: false
Your choice: Your choice:
8. `itpc` will keep asking whether you want to add more kernels. Finish the 8. `itapasco` will keep asking whether you want to add more kernels. Finish the
composition by `b<RETURN>`. composition by `b<RETURN>`.
LED: Enabled[]: LED: Enabled[]:
...@@ -223,7 +223,7 @@ We will use `itpc` to create a configuration file for us, so start it: ...@@ -223,7 +223,7 @@ We will use `itpc` to create a configuration file for us, so start it:
b: false b: false
Your choice: Your choice:
9. Next, `itpc` will query all currently implemented feature of the _Platform_: 9. Next, `itapasco` will query all currently implemented feature of the _Platform_:
`LED` means that there\`s a simple controller for the on-board LEDs to `LED` means that there\`s a simple controller for the on-board LEDs to
to show the internal state (available on Zynq, VC709). to show the internal state (available on Zynq, VC709).
`OLED` is only available on zedboard, shows the number of interrupts that `OLED` is only available on zedboard, shows the number of interrupts that
...@@ -237,10 +237,10 @@ We will use `itpc` to create a configuration file for us, so start it: ...@@ -237,10 +237,10 @@ We will use `itpc` to create a configuration file for us, so start it:
Enter filename for configuration[]: Enter filename for configuration[]:
10. Finally, `itpc` asks for a file name for your configuration file. Choose 10. Finally, `itapasco` asks for a file name for your configuration file. Choose
anything you like, e.g., `test.cfg`. anything you like, e.g., `test.cfg`.
Run ThreadPoolComposer with this configuration now?[]: Run Tapasco with this configuration now?[]:
a: true a: true
b: false b: false
Your choice: Your choice:
...@@ -253,7 +253,7 @@ logfiles, you can watch them via `tail --follow <FILE>` on a separate shell, ...@@ -253,7 +253,7 @@ logfiles, you can watch them via `tail --follow <FILE>` on a separate shell,
if you like. if you like.
If everything went well, there should be a `.bit` file in If everything went well, there should be a `.bit` file in
`$TPC_HOME/bd/<YOUR BD>/baseline/zedboard` afterwards (refer to the logging `$TAPASCO_HOME/bd/<YOUR BD>/baseline/zedboard` afterwards (refer to the logging
output for the value of `<YOUR BD>` - if you had used an external _Composition_ output for the value of `<YOUR BD>` - if you had used an external _Composition_
description file, it would use that name instead of the hash). description file, it would use that name instead of the hash).
......
ThreadPoolComposer (TPC)! Tapasco (TPC)!
========================= =========================
<img src="icon/threadpoolcomposer_bw.png" alt="ThreadPoolComposer logo" width="300px"/> <img src="icon/tapasco_icon.png" alt="Tapasco logo"/>
System Requirements System Requirements
------------------- -------------------
......
...@@ -3,48 +3,48 @@ project(arch-baseline) ...@@ -3,48 +3,48 @@ project(arch-baseline)
set(CMAKE_INSTALL_PREFIX "..") set(CMAKE_INSTALL_PREFIX "..")
set(CMAKE_SKIP_RPATH true) set(CMAKE_SKIP_RPATH true)
if (NOT EXISTS "$ENV{TPC_HOME}") if (NOT EXISTS "$ENV{TAPASCO_HOME}")
message(FATAL_ERROR "Please set TPC_HOME environment variable to root directory of ThreadPoolComposer") message(FATAL_ERROR "Please set TAPASCO_HOME environment variable to root directory of Tapasco")
endif (NOT EXISTS "$ENV{TPC_HOME}") endif (NOT EXISTS "$ENV{TAPASCO_HOME}")
include ("$ENV{TPC_HOME}/cmake/ThreadPoolComposer.cmake") include ("$ENV{TAPASCO_HOME}/cmake/Tapasco.cmake")
set(SRCDIR "src") set(SRCDIR "src")
set(CMNDIR "../common/src") set(CMNDIR "../common/src")
set(GCMNDIR "${TPC_HOME}/common") set(GCMNDIR "${TAPASCO_HOME}/common")
set(PLATFORMDIR "${TPC_HOME}/platform") set(PLATFORMDIR "${TAPASCO_HOME}/platform")
set(LIBPLATFORM_STATIC "${TPC_HOME}/platform/lib/${TPC_TARGET}/static/libplatform.a") set(LIBPLATFORM_STATIC "${TAPASCO_HOME}/platform/lib/${TAPASCO_TARGET}/static/libplatform.a")
set(BASELINE_SOURCES "${SRCDIR}/tpc_init.c" set(BASELINE_SOURCES "${SRCDIR}/tapasco_init.c"
"${SRCDIR}/tpc_device.c" "${SRCDIR}/tapasco_device.c"
"${SRCDIR}/tpc_address_map.c") "${SRCDIR}/tapasco_address_map.c")
set(COMMON_SOURCES "${CMNDIR}/tpc_logging.c" set(COMMON_SOURCES "${CMNDIR}/tapasco_logging.c"
"${CMNDIR}/tpc_errors.c" "${CMNDIR}/tapasco_errors.c"
"${CMNDIR}/tpc_functions.c" "${CMNDIR}/tapasco_functions.c"
"${CMNDIR}/tpc_scheduler.c" "${CMNDIR}/tapasco_scheduler.c"
"${CMNDIR}/tpc_jobs.c" "${CMNDIR}/tapasco_jobs.c"
"${CMNDIR}/tpc_status.c" "${CMNDIR}/tapasco_status.c"
"${CMNDIR}/tpc_version.c" "${CMNDIR}/tapasco_version.c"
"${GCMNDIR}/src/gen_queue.c") "${GCMNDIR}/src/gen_queue.c")
set(TPC_LIBS_DIR "${TPC_HOME}/arch/lib") set(TAPASCO_LIBS_DIR "${TAPASCO_HOME}/arch/lib")
include_directories("include" "../common/include" "${PLATFORMDIR}/common/include" "${GCMNDIR}/include") include_directories("include" "../common/include" "${PLATFORMDIR}/common/include" "${GCMNDIR}/include")
link_directories("${PLATFORMDIR}/lib/${TPC_TARGET}") link_directories("${PLATFORMDIR}/lib/${TAPASCO_TARGET}")
add_definitions(-DUSE_ASSERTIONS) add_definitions(-DUSE_ASSERTIONS)
set_source_files_properties(${BASELINE_SOURCES} ${COMMON_SOURCES} PROPERTIES COMPILE_FLAGS "-g -O3 -Wall -Werror -std=gnu11") set_source_files_properties(${BASELINE_SOURCES} ${COMMON_SOURCES} PROPERTIES COMPILE_FLAGS "-g -O3 -Wall -Werror -std=gnu11")
add_library(tpc SHARED ${BASELINE_SOURCES} ${COMMON_SOURCES}) add_library(tapasco SHARED ${BASELINE_SOURCES} ${COMMON_SOURCES})
add_library(libtpc-static STATIC ${BASELINE_SOURCES} ${COMMON_SOURCES} ${LIBPLATFORM_STATIC}) add_library(libtapasco-static STATIC ${BASELINE_SOURCES} ${COMMON_SOURCES} ${LIBPLATFORM_STATIC})
target_link_libraries(tpc platform atomic pthread) target_link_libraries(tapasco platform atomic pthread)
set_target_properties(libtpc-static PROPERTIES OUTPUT_NAME tpc) set_target_properties(libtapasco-static PROPERTIES OUTPUT_NAME tapasco)
install(TARGETS tpc libtpc-static install(TARGETS tapasco libtapasco-static
LIBRARY DESTINATION "lib/${TPC_TARGET}" LIBRARY DESTINATION "lib/${TAPASCO_TARGET}"
ARCHIVE DESTINATION "lib/${TPC_TARGET}/static") ARCHIVE DESTINATION "lib/${TAPASCO_TARGET}/static")
get_filename_component(LIBSDIR "lib" REALPATH) get_filename_component(LIBSDIR "lib" REALPATH)
add_custom_command(OUTPUT ${TPC_LIBS_DIR} add_custom_command(OUTPUT ${TAPASCO_LIBS_DIR}
COMMAND ln;-fs;${LIBSDIR};${TPC_LIBS_DIR}) COMMAND ln;-fs;${LIBSDIR};${TAPASCO_LIBS_DIR})
add_custom_target(install_libs ALL DEPENDS tpc libtpc-static ${TPC_LIBS_DIR}) add_custom_target(install_libs ALL DEPENDS tapasco libtapasco-static ${TAPASCO_LIBS_DIR})
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
Proof-of-concept implementation of the most simple conceivable hardware Proof-of-concept implementation of the most simple conceivable hardware
threadpool implementation based on the AXI4-bus. Useful as baseline for future, threadpool implementation based on the AXI4-bus. Useful as baseline for future,
optimized architectures as well as for demonstration of the basic implementation optimized architectures as well as for demonstration of the basic implementation
of an Architecture for *ThreadpoolComposer*. of an Architecture for *Tapasco*.
## Building the TPC API library ## Building the TPC API library
Simply type `make` in this directory, and a directory `lib` should be created Simply type `make` in this directory, and a directory `lib` should be created
......
# #
# Copyright (C) 2014 Jens Korinth, TU Darmstadt # Copyright (C) 2014 Jens Korinth, TU Darmstadt
# #
# This file is part of ThreadPoolComposer (TPC). # This file is part of Tapasco (TPC).
# #
# ThreadPoolComposer is free software: you can redistribute it and/or modify # Tapasco is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by # it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation, either version 3 of the License, or # the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version. # (at your option) any later version.
# #
# ThreadPoolComposer is distributed in the hope that it will be useful, # Tapasco is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of # but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the