Internal change

PiperOrigin-RevId: 304319643
diff --git a/ruy/build_defs.bzl b/ruy/build_defs.bzl
index 964ede3..9bccccf 100644
--- a/ruy/build_defs.bzl
+++ b/ruy/build_defs.bzl
@@ -1,8 +1,4 @@
-"""Build definitions for Ruy.
-
-In some cases these are used to configure specific targets for
-specific platforms, and dispatch is based on runtime capability detection.
-"""
+"""Build definitions for Ruy."""
 
 # 1. Enable -mfpu=neon unconditionally on ARM32. If it turns out that we need to support
 #    ARM32 without NEON then we'll implement runtime detection and dispatch at that point.
@@ -21,17 +17,11 @@
 
 # Used for targets that are compiled with extra features that are skipped at runtime if unavailable.
 def ruy_copts_skylake():
-    return select({
-        ":x86_64": ["-march=skylake-avx512"],
-        "//conditions:default": [],
-    })
+    return []
 
 # Used for targets that are compiled with extra features that are skipped at runtime if unavailable.
 def ruy_copts_avx2():
-    return select({
-        ":x86_64": ["-mavx2", "-mfma"],
-        "//conditions:default": [],
-    })
+    return []
 
 # TODO(b/147376783): SSE 4.2 and AVX-VNNI support is incomplete / placeholder.
 # Optimization is not finished. In particular the dimensions of the kernel
@@ -47,8 +37,4 @@
 #
 # Used for targets that are compiled with extra features that are skipped at runtime if unavailable.
 def ruy_copts_avxvnni():
-    return select({
-        # TODO(b/146494398): Reinstate flag, something like "-march=cascadelake".
-        ":x86_64": [],
-        "//conditions:default": [],
-    })
+    return []
diff --git a/ruy/build_defs.bzl.opensource b/ruy/build_defs.bzl.opensource
deleted file mode 100644
index 9bccccf..0000000
--- a/ruy/build_defs.bzl.opensource
+++ /dev/null
@@ -1,40 +0,0 @@
-"""Build definitions for Ruy."""
-
-# 1. Enable -mfpu=neon unconditionally on ARM32. If it turns out that we need to support
-#    ARM32 without NEON then we'll implement runtime detection and dispatch at that point.
-# 2. Explicitly pass -O3 on optimization configs where just "-c opt" means "optimize for code size".
-
-def ruy_copts_base():
-    return select({
-        ":armeabi-v7a": [
-            "-mfpu=neon",
-        ],
-        "//conditions:default": [],
-    }) + select({
-        ":optimized": ["-O3"],
-        "//conditions:default": [],
-    })
-
-# Used for targets that are compiled with extra features that are skipped at runtime if unavailable.
-def ruy_copts_skylake():
-    return []
-
-# Used for targets that are compiled with extra features that are skipped at runtime if unavailable.
-def ruy_copts_avx2():
-    return []
-
-# TODO(b/147376783): SSE 4.2 and AVX-VNNI support is incomplete / placeholder.
-# Optimization is not finished. In particular the dimensions of the kernel
-# blocks can be changed as desired.
-#
-# Used for targets that are compiled with extra features that are skipped at runtime if unavailable.
-def ruy_copts_sse42():
-    return []
-
-# TODO(b/147376783): SSE 4.2 and AVX-VNNI support is incomplete / placeholder.
-# Optimization is not finished. In particular the dimensions of the kernel
-# blocks can be changed as desired.
-#
-# Used for targets that are compiled with extra features that are skipped at runtime if unavailable.
-def ruy_copts_avxvnni():
-    return []
diff --git a/ruy/profiler/BUILD b/ruy/profiler/BUILD
index b0af802..5e9d9bd 100644
--- a/ruy/profiler/BUILD
+++ b/ruy/profiler/BUILD
@@ -10,6 +10,14 @@
     define_values = {"ruy_profiler": "true"},
 )
 
+# Used to build TFLite Micro RUY dependency for embedded targets outside of the
+# RUY source tree.
+filegroup(
+    name = "ruy_instrumentation_header",
+    srcs = ["instrumentation.h"],
+    visibility = ["//visibility:public"],
+)
+
 cc_library(
     name = "instrumentation",
     srcs = ["instrumentation.cc"],
diff --git a/ruy/ruy_test_ext.bzl b/ruy/ruy_test_ext.bzl
index 263121f..5701fff 100644
--- a/ruy/ruy_test_ext.bzl
+++ b/ruy/ruy_test_ext.bzl
@@ -1,19 +1,7 @@
 """Allows to specialize the ruy BUILD to availability of external libraries"""
 
 def ruy_test_ext_defines():
-    return select({
-        "//tools/cc_target_os:windows": [],
-        "//tools/cc_target_os:wasm": [],
-        "//tools/cc_target_os:chromiumos": ["RUY_TESTING_ON_CHROMIUMOS"],
-        "//conditions:default": ["RUY_TEST_EXTERNAL_PATHS"],
-    })
+    return []
 
 def ruy_test_ext_deps():
-    return select({
-        "//tools/cc_target_os:windows": [],
-        "//conditions:default": [
-            "//third_party/eigen3",
-            "//third_party/gemmlowp",
-            "//third_party/lapack:blas",
-        ],
-    })
+    return []
diff --git a/ruy/ruy_test_ext.bzl.opensource b/ruy/ruy_test_ext.bzl.opensource
deleted file mode 100644
index 5701fff..0000000
--- a/ruy/ruy_test_ext.bzl.opensource
+++ /dev/null
@@ -1,7 +0,0 @@
-"""Allows to specialize the ruy BUILD to availability of external libraries"""
-
-def ruy_test_ext_defines():
-    return []
-
-def ruy_test_ext_deps():
-    return []