diff --git a/tensorflow/lite/delegates/gpu/gl/egl_context.h b/tensorflow/lite/delegates/gpu/gl/egl_context.h index 52dcfcb4067..72c53d2dd2e 100644 --- a/tensorflow/lite/delegates/gpu/gl/egl_context.h +++ b/tensorflow/lite/delegates/gpu/gl/egl_context.h @@ -16,8 +16,6 @@ limitations under the License. #ifndef TENSORFLOW_LITE_DELEGATES_GPU_GL_EGL_CONTEXT_H_ #define TENSORFLOW_LITE_DELEGATES_GPU_GL_EGL_CONTEXT_H_ -#include - #include "tensorflow/lite/delegates/gpu/common/status.h" #include "tensorflow/lite/delegates/gpu/gl/portable_egl.h" diff --git a/tensorflow/lite/tools/make/Makefile b/tensorflow/lite/tools/make/Makefile index f67094f37b4..4219aa5c319 100644 --- a/tensorflow/lite/tools/make/Makefile +++ b/tensorflow/lite/tools/make/Makefile @@ -39,6 +39,7 @@ INCLUDES := \ -I$(MAKEFILE_DIR)/downloads/neon_2_sse \ -I$(MAKEFILE_DIR)/downloads/farmhash/src \ -I$(MAKEFILE_DIR)/downloads/flatbuffers/include \ +-I$(MAKEFILE_DIR)/downloads/fp16/include \ -I$(OBJDIR) # This is at the end so any globally-installed frameworks like protobuf don't # override local versions in the source tree. @@ -162,7 +163,7 @@ ifeq ($(TARGET),generic-aarch64) endif ifeq ($(BUILD_WITH_NNAPI),true) CORE_CC_ALL_SRCS += tensorflow/lite/delegates/nnapi/nnapi_delegate.cc - CORE_CC_ALL_SRCS += tensorflow/lite/delegates/nnapi/quant_lstm_sup.cc + CORE_CC_ALL_SRCS += tensorflow/lite/delegates/nnapi/quant_lstm_sup.cc CORE_CC_ALL_SRCS += tensorflow/lite/nnapi/nnapi_implementation.cc CORE_CC_ALL_SRCS += tensorflow/lite/nnapi/nnapi_util.cc LIBS += -lrt @@ -179,7 +180,6 @@ else CORE_CC_EXCLUDE_SRCS += tensorflow/lite/minimal_logging_ios.cc endif - # Filter out all the excluded files. TF_LITE_CC_SRCS := $(filter-out $(CORE_CC_EXCLUDE_SRCS), $(CORE_CC_ALL_SRCS)) @@ -215,7 +215,7 @@ ALL_SRCS := \ $(PROFILER_SUMMARIZER_SRCS) \ $(TF_LITE_CC_SRCS) \ $(BENCHMARK_LIB_SRCS) \ - $(CMD_LINE_TOOLS_SRCS) + $(CMD_LINE_TOOLS_SRCS) # Where compiled objects are stored. GENDIR := $(MAKEFILE_DIR)/gen/$(TARGET)_$(TARGET_ARCH)/ @@ -249,9 +249,14 @@ BENCHMARK_LIB_OBJS := $(addprefix $(OBJDIR), \ $(patsubst %.cc,%.o,$(patsubst %.c,%.o,$(BENCHMARK_LIB_SRCS)))) # For normal manually-created TensorFlow Lite C++ source files. +$(OBJDIR)%.o: %.cpp + @mkdir -p $(dir $@) + $(CXX) $(CXXFLAGS) $(INCLUDES) -c $< -o $@ + $(OBJDIR)%.o: %.cc @mkdir -p $(dir $@) $(CXX) $(CXXFLAGS) $(INCLUDES) -c $< -o $@ + # For normal manually-created TensorFlow Lite C source files. $(OBJDIR)%.o: %.c @mkdir -p $(dir $@) diff --git a/tensorflow/lite/tools/make/download_dependencies.sh b/tensorflow/lite/tools/make/download_dependencies.sh index 74a8248ce46..0925adc61c0 100755 --- a/tensorflow/lite/tools/make/download_dependencies.sh +++ b/tensorflow/lite/tools/make/download_dependencies.sh @@ -41,6 +41,7 @@ FARMHASH_URL="https://storage.googleapis.com/mirror.tensorflow.org/github.com/go FARMHASH_SHA="$(eval echo $(grep '# SHARED_FARMHASH_SHA' "${BZL_FILE_PATH}" | grep -o '\".*\"'))" FLATBUFFERS_URL="https://storage.googleapis.com/mirror.tensorflow.org/github.com/google/flatbuffers/archive/v1.11.0.tar.gz" FFT2D_URL="https://storage.googleapis.com/mirror.tensorflow.org/www.kurims.kyoto-u.ac.jp/~ooura/fft2d.tgz" +FP16_URL="https://github.com/Maratyszcza/FP16/archive/febbb1c163726b5db24bed55cc9dc42529068997.zip" # TODO(petewarden): Some new code in Eigen triggers a clang bug with iOS arm64, # so work around it by patching the source. @@ -104,6 +105,7 @@ download_and_extract "${NEON_2_SSE_URL}" "${DOWNLOADS_DIR}/neon_2_sse" download_and_extract "${FARMHASH_URL}" "${DOWNLOADS_DIR}/farmhash" "${FARMHASH_SHA}" download_and_extract "${FLATBUFFERS_URL}" "${DOWNLOADS_DIR}/flatbuffers" download_and_extract "${FFT2D_URL}" "${DOWNLOADS_DIR}/fft2d" +download_and_extract "${FP16_URL}" "${DOWNLOADS_DIR}/fp16" replace_by_sed 's#static uint32x4_t p4ui_CONJ_XOR = vld1q_u32( conj_XOR_DATA );#static uint32x4_t p4ui_CONJ_XOR; // = vld1q_u32( conj_XOR_DATA ); - Removed by script#' \ "${DOWNLOADS_DIR}/eigen/Eigen/src/Core/arch/NEON/Complex.h"