Set proper optimization options (#2344)

- Use -O2 in release build of Caffe2 (Android defaults to -Os on ARMv7)
- Update NNPACK submodule to use the proper options for ukernels and layers
diff --git a/caffe2/CMakeLists.txt b/caffe2/CMakeLists.txt
index 2e50bc5..b1e9baf 100644
--- a/caffe2/CMakeLists.txt
+++ b/caffe2/CMakeLists.txt
@@ -118,6 +118,8 @@
 target_include_directories(caffe2 INTERFACE $<INSTALL_INTERFACE:include>)
 target_compile_options(caffe2 INTERFACE "-std=c++11")
 target_compile_options(caffe2 PRIVATE "-DCAFFE2_BUILD_MAIN_LIB")
+# Use -O2 for release builds (-O3 doesn't improve perf, and -Os results in perf regression)
+target_compile_options(caffe2 PRIVATE "$<$<OR:$<CONFIG:Release>,$<CONFIG:RelWithDebInfo>>:-O2>")
 install(TARGETS caffe2 EXPORT Caffe2Targets DESTINATION lib)
 caffe2_interface_library(caffe2 caffe2_library)
 list(APPEND Caffe2_MAIN_LIBS caffe2_library)
diff --git a/third_party/NNPACK b/third_party/NNPACK
index 83af25d..0872691 160000
--- a/third_party/NNPACK
+++ b/third_party/NNPACK
@@ -1 +1 @@
-Subproject commit 83af25db11883e160e65005f065f260488643c26
+Subproject commit 087269189207a63ab7084e6925ea511d8952fa59