This patch allows the OpenGLES rendering library to use Unix sockets instead of TCP ones when communicating with its clients. On certain benchmarks (e.g. 0xBench teapot), this provides a noticeable improvement (x1.05 fps) without any other changes. On practice, Unix sockets are faster than TCP sockets, even local ones. Also, this introduces a moderate amount of abstraction that will allow us to use Win32 named pipes on Windows (where TCP sockets are much slower than they are on Unix). Note that by default, TCP streams are still used. The client (emulator) must call the new API 'setStreamMode' to change it to STREAM_MODE_UNIX between 'initLibrary' and 'startOpenglRenderer' calls. + Adjust callers / user appropriately. Change-Id: I4105bbf07541f3146b50a58d1a5b51e8cf044fab
38 lines
1.0 KiB
Makefile
38 lines
1.0 KiB
Makefile
# This build script corresponds to a library containing many definitions
|
|
# common to both the guest and the host. They relate to
|
|
#
|
|
LOCAL_PATH := $(call my-dir)
|
|
|
|
commonSources := \
|
|
GLClientState.cpp \
|
|
GLSharedGroup.cpp \
|
|
glUtils.cpp \
|
|
SocketStream.cpp \
|
|
TcpStream.cpp \
|
|
TimeUtils.cpp
|
|
|
|
ifneq ($(HOST_OS),windows)
|
|
commonSources += UnixStream.cpp
|
|
endif
|
|
|
|
### CodecCommon guest ##############################################
|
|
$(call emugl-begin-static-library,libOpenglCodecCommon)
|
|
|
|
LOCAL_SRC_FILES := $(commonSources)
|
|
|
|
LOCAL_CFLAGS += -DLOG_TAG=\"eglCodecCommon\"
|
|
|
|
$(call emugl-export,SHARED_LIBRARIES,libcutils libutils)
|
|
$(call emugl-export,C_INCLUDES,$(LOCAL_PATH))
|
|
$(call emugl-end-module)
|
|
|
|
### OpenglCodecCommon host ##############################################
|
|
$(call emugl-begin-host-static-library,libOpenglCodecCommon)
|
|
|
|
LOCAL_SRC_FILES := $(commonSources)
|
|
|
|
$(call emugl-export,STATIC_LIBRARIES,libcutils)
|
|
$(call emugl-export,C_INCLUDES,$(LOCAL_PATH))
|
|
$(call emugl-end-module)
|
|
|