summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 7b65cbb)
raw | patch | inline | side by side (parent: 7b65cbb)
author | Ajay Jayaraj <ajayj@ti.com> | |
Wed, 4 Jul 2018 02:43:42 +0000 (21:43 -0500) | ||
committer | Ajay Jayaraj <ajayj@ti.com> | |
Thu, 5 Jul 2018 15:41:23 +0000 (10:41 -0500) |
* By default, the OpenCL runtime is configured with sufficient memory to
offload TIDL networks to 2 devices. On devices with 4 EVEs (e.g.
AM5729), the amount of memory available to the runtime must be
increased. Refer the User's Guide, section "Insufficient OpenCL global
memory" for details
* Documentation
- Add a section on the "test" example
- Include a note on the need to increase the default OpenCL global
memory for 4 devices.
(MCT-1008)
offload TIDL networks to 2 devices. On devices with 4 EVEs (e.g.
AM5729), the amount of memory available to the runtime must be
increased. Refer the User's Guide, section "Insufficient OpenCL global
memory" for details
* Documentation
- Add a section on the "test" example
- Include a note on the need to increase the default OpenCL global
memory for 4 devices.
(MCT-1008)
docs/source/example.rst | patch | blob | history | |
docs/source/using_api.rst | patch | blob | history | |
examples/test/main.cpp | patch | blob | history | |
makefile | patch | blob | history |
index eed7a43e450bff02f96b23ad60c36c6f1ae9a3e7..ff7f125a1c985efe5a888e7480fe3ee1a02f3023 100644 (file)
--- a/docs/source/example.rst
+++ b/docs/source/example.rst
DSP: 21.1 ms 22.3 ms 5.62 %
====================== ==================== ============
+Test
+----
+This example is used to test pre-converted networks included in the TIDL API package (``test/testvecs/config/tidl_models``). When run without any arguments, the program ``test_tidl`` will run all available networks on the C66x DSPs and EVEs available on the SoC. Use the ``-c`` option to specify a single network. Run ``test_tidl -h`` for details.
+
Running Examples
----------------
index 51ca13f53d0c304de74edfb910d9fc1c0a302bf3..b2c909e03666bc4ae93877fe22b77c84a1b33125 100644 (file)
uint32_t num_eve = Executor::GetNumDevices(DeviceType::EVE);
uint32_t num_dsp = Executor::GetNumDevices(DeviceType::DSP);
+.. note::
+ By default, the OpenCL runtime is configured with sufficient global memory
+ (via CMEM) to offload TIDL networks to 2 OpenCL devices. On devices where
+ ``Executor::GetNumDevices`` returns 4 (E.g. AM5729 with 4 EVE OpenCL
+ devices) the amount of memory available to the runtime must be increased.
+ Refer :ref:`opencl-global-memory` for details
+
Step 2
======
Create a Configuration object by reading it from a file or by initializing it directly. The example below parses a configuration file and initializes the Configuration object. See ``examples/test/testvecs/config/infer`` for examples of configuration files.
diff --git a/examples/test/main.cpp b/examples/test/main.cpp
index 968b0fed4feab762a4f219374902df8020719ab7..bc87855ab6fbcb381103bf2d439cd88fb74e440e 100644 (file)
--- a/examples/test/main.cpp
+++ b/examples/test/main.cpp
{
if (num_eve > 0)
{
- //TODO: Use memory availability to determine # devices
// Run on 2 devices because there is not enough CMEM available by
// default
- if (num_eve = 4) num_eve = 2;
+ if (num_eve = 4)
+ {
+ std::cout
+ << "Running on 2 EVE devices instead of the available 4 "
+ << "due to insufficient OpenCL global memory. Refer the "
+ << "TIDL API User's Guide, Frequently Asked Questions, "
+ << "Section \"Insufficient OpenCL global memory\" for details "
+ << "on increasing the amount of CMEM available for OpenCL."
+ << std::endl;
+ num_eve = 2;
+ }
status = RunAllConfigurations(num_eve, DeviceType::EVE);
status &= RunMultipleExecutors(
"testvecs/config/infer/tidl_config_j11_v2.txt",
diff --git a/makefile b/makefile
index f8ea211dae89a620f8b9b7df884f09480663280d..e94e5869ce12a1360de5c214039be59570b69ffd 100644 (file)
--- a/makefile
+++ b/makefile
ifneq (,$(findstring 86, $(shell uname -m)))
DEST_DIR ?= $(CURDIR)/install/am57
VIEWER_TARGET=x86
+ifeq ($(TARGET_ROOTDIR),)
+$(error Set TARGET_ROOTDIR to the ARM Linux devkit/filesystem)
+endif
else
VIEWER_TARGET=arm
endif