page.title=Porting the test framework @jd:body

In this document

Porting the deqp involves three steps: adapting base portability libraries, implementing test-framework platform-integration interfaces, and porting the execution service.

The table below lists locations for likely porting changes. Anything beyond them is likely to be exotic.

Location Description
framework/delibs/debase
framework/delibs/dethread
framework/delibs/deutil

Any necessary implementations of OS-specific code.

framework/qphelper/qpCrashHandler.c

Optional: Implementation for your OS.

framework/qphelper/qpWatchDog.c

Implementation for your OS. Current one is based on dethread and standard C library.

framework/platform

New platform port and application stub can be implemented as described in Test framework platform port.

Base portability libraries

The base portability libraries already support Windows, most Linux variants, Mac OS, iOS, and Android. If the test target runs on one of those operating systems, most likely there is no need to touch the base portability libraries at all.

Test framework platform port

The deqp test framework platform port requires two components: An application entry point and a platform interface implementation.

The application entry point is responsible for creating the platform object, creating a command line (tcu::CommandLine) object, opening a test log (tcu::TestLog), and iterating the test application (tcu::App). If the target OS supports a standard main() entry point, tcuMain.cpp can be used as the entry point implementation.

The deqp platform API is described in detail in the following files.

File Description
framework/common/tcuPlatform.hpp

Base class for all platform ports

framework/opengl/gluPlatform.hpp

OpenGL platform interface

framework/egl/egluPlatform.hpp

EGL platform interface

framework/platform/tcuMain.cpp

Standard application entry point

The base class for all platform ports is tcu::Platform. The platform port can optionally support GL- and EGL-specific interfaces. See the following table for an overview of what needs to be implemented to run the tests.

Module Interface

OpenGL (ES) test modules

GL platform interface

EGL test module

EGL platform interface

Detailed instructions for implementing platform ports are in the porting layer headers.

Test execution service

To use the deqp test execution infrastructure or command line executor, the test execution service must be available on the target. A portable C++ implementation of the service is provided in the execserver directory. The stand-alone binary is built as a part of the deqp test module build for PC targets. You can modify execserver/CMakeLists.txt to enable a build on other targets.

The C++ version of the test execution service accepts two command line parameters: