[PATCH] D156095: [Bazel] Introduce `//compiler-rt:profile`

NAKAMURA Takumi via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 24 03:45:47 PDT 2023


chapuni created this revision.
Herald added subscribers: Enna1, dberris.
Herald added a project: All.
chapuni requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

At the moment, provide only `profile` at first.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D156095

Files:
  utils/bazel/llvm-project-overlay/compiler-rt/BUILD.bazel


Index: utils/bazel/llvm-project-overlay/compiler-rt/BUILD.bazel
===================================================================
--- /dev/null
+++ utils/bazel/llvm-project-overlay/compiler-rt/BUILD.bazel
@@ -0,0 +1,43 @@
+# This file is licensed under the Apache License v2.0 with LLVM Exceptions.
+# See https://llvm.org/LICENSE.txt for license information.
+# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+
+package(
+    default_visibility = ["//visibility:public"],
+    features = ["layering_check"],
+)
+
+licenses(["notice"])
+
+cc_library(
+    name = "config",
+    defines = [
+        "COMPILER_RT_HAS_ATOMICS=1",
+        "COMPILER_RT_HAS_FCNTL_LCK=1",
+        "COMPILER_RT_HAS_UNAME=1",
+    ],
+)
+
+cc_library(
+    name = "profile",
+    srcs = glob([
+        "lib/profile/*.c",
+        "lib/profile/*.h",
+    ], exclude = [
+        "lib/profile/WindowsMMap.c",
+    ]),
+    hdrs = glob([
+        "include/profile/*.inc",
+    ]),
+    includes = [
+        "include",
+    ],
+    copts = [
+        "-Wno-pedantic",
+        "-Wno-strict-prototypes",
+    ],
+    deps = [
+        ":config",
+    ],
+    linkstatic = True,
+)


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D156095.543456.patch
Type: text/x-patch
Size: 1167 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230724/238f1e9f/attachment.bin>


More information about the llvm-commits mailing list