Skip to content

[compiler-rt] intercept macOs's freadlink call. #83679

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 25, 2024

Conversation

devnexen
Copy link
Member

@devnexen devnexen commented Mar 2, 2024

available since macOs Ventura.

@llvmbot
Copy link
Member

llvmbot commented Mar 2, 2024

@llvm/pr-subscribers-compiler-rt-sanitizer

Author: David CARLIER (devnexen)

Changes

available since macOs Ventura.


Full diff: https://github.com/llvm/llvm-project/pull/83679.diff

3 Files Affected:

  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors.inc (+19)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h (+1)
  • (added) compiler-rt/test/sanitizer_common/TestCases/Darwin/freadlink.c (+29)
diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors.inc b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors.inc
index 3ecdb55cdbf72f..9a43ada118da8a 100644
--- a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors.inc
+++ b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors.inc
@@ -10250,6 +10250,24 @@ INTERCEPTOR(int, cpuset_getaffinity, int level, int which, __int64_t id, SIZE_T
 #define INIT_CPUSET_GETAFFINITY
 #endif
 
+#if SANITIZER_INTERCEPT_FREADLINK
+INTERCEPTOR(SSIZE_T, freadlink, int fd, char *buf, SIZE_T bufsiz) {
+  void* ctx;
+  COMMON_INTERCEPTOR_ENTER(ctx, freadlink, fd, buf, bufsiz);
+  COMMON_INTERCEPTOR_FD_ACCESS(ctx, fd);
+  SSIZE_T res = REAL(freadlink)(fd, buf, bufsiz);
+  if (res > 0)
+    COMMON_INTERCEPTOR_WRITE_RANGE(ctx, buf, res);
+  if (res >= 0 && fd > 0)
+    COMMON_INTERCEPTOR_FD_ACQUIRE(ctx, fd);
+  return res;
+}
+
+#define INIT_FREADLINK COMMON_INTERCEPT_FUNCTION(freadlink)
+#else
+#define INIT_FREADLINK
+#endif
+
 #include "sanitizer_common_interceptors_netbsd_compat.inc"
 
 namespace __sanitizer {
@@ -10569,6 +10587,7 @@ static void InitializeCommonInterceptors() {
   INIT___XUNAME;
   INIT_ARGP_PARSE;
   INIT_CPUSET_GETAFFINITY;
+  INIT_FREADLINK;
 
   INIT___PRINTF_CHK;
 }
diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h b/compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h
index de55c736d0e144..42a06b3cc6f4d3 100644
--- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h
+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h
@@ -598,6 +598,7 @@
 #define SANITIZER_INTERCEPT_PROCCTL SI_FREEBSD
 #define SANITIZER_INTERCEPT_ARGP_PARSE SI_GLIBC
 #define SANITIZER_INTERCEPT_CPUSET_GETAFFINITY SI_FREEBSD
+#define SANITIZER_INTERCEPT_FREADLINK SI_MAC
 
 // This macro gives a way for downstream users to override the above
 // interceptor macros irrespective of the platform they are on. They have
diff --git a/compiler-rt/test/sanitizer_common/TestCases/Darwin/freadlink.c b/compiler-rt/test/sanitizer_common/TestCases/Darwin/freadlink.c
new file mode 100644
index 00000000000000..53658cdb66aa3d
--- /dev/null
+++ b/compiler-rt/test/sanitizer_common/TestCases/Darwin/freadlink.c
@@ -0,0 +1,29 @@
+// RUN: %clang -O0 %s -o %t && %run %t
+
+#include <assert.h>
+#include <fcntl.h>
+#include <limits.h>
+#include <stdio.h>
+#include <string.h>
+#include <sys/types.h>
+#include <unistd.h>
+
+int main(int argc, char **argv) {
+  char symlink_path[PATH_MAX];
+  snprintf(symlink_path, sizeof(symlink_path), "%s_%d.symlink", argv[0],
+           getpid());
+  remove(symlink_path);
+  int res = symlink(argv[0], symlink_path);
+  assert(!res);
+
+  int fd;
+  char readlink_path[PATH_MAX];
+  fd = open(symlink_path, O_RDONLY);
+  ssize_t res2 = freadlink(fd, readlink_path, sizeof(readlink_path));
+  assert(res2 >= 0);
+  readlink_path[res2] = '\0';
+  assert(!strcmp(readlink_path, argv[0]));
+  close(fd);
+
+  return 0;
+}

Copy link

github-actions bot commented Mar 2, 2024

✅ With the latest revision this PR passed the C/C++ code formatter.

@devnexen devnexen force-pushed the freadlink_macos_intercept branch from e166d0f to a3b9d38 Compare March 2, 2024 15:53
@devnexen devnexen force-pushed the freadlink_macos_intercept branch from a3b9d38 to 9a8cbae Compare September 8, 2024 05:50
@devnexen devnexen requested a review from vitalybuka September 8, 2024 05:50
available since macOs Ventura.
@devnexen devnexen force-pushed the freadlink_macos_intercept branch from 9a8cbae to da32a6f Compare September 16, 2024 07:49
@devnexen devnexen requested a review from vitalybuka September 24, 2024 08:44
@devnexen devnexen merged commit a6ea0b0 into llvm:main Sep 25, 2024
7 checks passed
@Zentrik
Copy link
Contributor

Zentrik commented Sep 25, 2024

Is this intended to break the build on Mac versions earlier than Ventura? Has llvm raised the minimum required version of Mac os from 10.14?

@devnexen
Copy link
Member Author

Was unintended, thankfully we can check mac os sdk version. I ll produce a fix shortly.

devnexen added a commit to devnexen/llvm-project that referenced this pull request Sep 25, 2024
devnexen added a commit to devnexen/llvm-project that referenced this pull request Sep 25, 2024
@expcov
Copy link

expcov commented Sep 28, 2024

This commit seems to have prevented builds on macOS Big Sur.

Undefined symbols for architecture arm64:
  "_freadlink", referenced from:
      _wrap_freadlink in tsan_interceptors_posix.cpp.o
      substitution_freadlink in tsan_interceptors_posix.cpp.o
     (maybe you meant: _wrap_freadlink)
ld: symbol(s) not found for architecture arm64

@devnexen
Copy link
Member Author

which commit ? this one or this one ?

@expcov
Copy link

expcov commented Sep 28, 2024

This one.
I tried compiling on the main branch and the build fails when applying a6ea0b0.

    | | | | | | | | | * 1d5277c271bc - (origin/revert-109553-users/MaskRay/spr/llvm-objdump-print-even-if-a-data-mapping-symbol-is-active) Revert "[llvm-objdump] Print ... even if a data mapping symbol is active" (2024/09/25 19:14:39) <Justin Bogner>
    | |_|_|_|_|_|_|_|/  
    |/| | | | | | | |   
    * | | | | | | | | 2b0a708f41dd - [Clang] Set target in test (#110068) (2024/09/26 03:48:26) <Sirraide>
    * | | | | | | | | 3d01af78a968 - [nfc][ctx_prof] Remove unnecessary include (2024/09/25 18:42:47) <Mircea Trofin>
    * | | | | | | | | f4fa16f14b3e - [Clang] Bugfixes and improved support for `AttributedType`s in lambdas (#85325) (2024/09/26 03:24:53) <Sirraide>
    * | | | | | | | | 3d424e8aacf5 - [SPIR-V] Support for multiple DebugCompilationUnit in DI (#109645) (2024/09/25 18:08:55) <bwlodarcz>
    * | | | | | | | | 4ffb747aa4e6 - [SPIR-V][NFC] More efficient getPaddedLen (#105823) (2024/09/25 18:07:55) <bwlodarcz>
    * | | | | | | | | 0f85c3e08456 - [libc] Fix missing dependency on the nvlink-wrapper (#110056) (2024/09/25 18:04:10) <Joseph Huber>
    * | | | | | | | | 661666d43ab9 - [AMDGPU] Move renamedInGFX9 from TableGen to SIInstrInfo helper function/macro to free up a bit slot (#82787) (2024/09/25 20:38:51) <Corbin Robeck>
    * | | | | | | | | 0813c76d4008 - [gn build] Port 165a912807ee (2024/09/26 00:04:50) <LLVM GN Syncbot>
    * | | | | | | | | 165a912807ee - [SandboxIR][NFC] Move Context class into a separate file (#110049) (2024/09/25 17:04:20) <vporpo>
    * | | | | | | | | 9bc26e9e8eb7 - [NVPTX] Support !"cluster_dim_{x,y,z}" metadata (#109548) (2024/09/25 16:49:02) <Alex MacLean>
    * | | | | | | | | 13809b3d9592 - [SandboxIR] Fix failing unittest introduced by 51039101cf32 (2024/09/25 16:38:46) <Vasileios Porpodas>
    * | | | | | | | | cf1de0a7b47b - [RISCV] Reuse Factor variable instead of hardcoding 2 in other places. NFC (2024/09/25 16:36:18) <Craig Topper>
    * | | | | | | | | 3e65c30eee4d - [Lint][AMDGPU] No store to const addrspace (#109181) (2024/09/25 19:18:17) <jofrn>
    * | | | | | | | | a068b974b199 - [VPlan] Implement VPWidenLoad/StoreEVLRecipe::computeCost().  (#109644) (2024/09/26 07:10:25) <Elvis Wang>
    * | | | | | | | | 51039101cf32 - [SandboxIR] Add more functions to sandboxir:Instruction class. (#110050) (2024/09/25 16:09:13) <Sriraman Tallam>
    * | | | | | | | | e7d68c903be0 - [libc] Fix errno_macros.h include paths. (#110057) (2024/09/25 15:46:29) <Michael Jones>
    * | | | | | | | | eab63b5a8cf2 - [libc] Fix %m on CPUs with float128 but no int128 (#110053) (2024/09/25 15:30:47) <Michael Jones>
    * | | | | | | | | c8365feed7af - [ctx_prof] Simple ICP criteria during module inliner (#109881) (2024/09/25 15:05:52) <Mircea Trofin>
    * | | | | | | | | 4db0cc4c5582 - [BOLT] Allow sections in --print-only flag (#109622) (2024/09/25 23:44:06) <Maksim Panchenko>
    * | | | | | | | | 1bfca99909c2 - [SLP]Initial support for non-power-of-2 (but still whole register) number of elements in operands. (2024/09/25 14:38:17) <Alexey Bataev>
    * | | | | | | | | fea159671ae1 - [llvm][cmake] Do not emit error on `libc`'s use of project + runtime build (#110038) (2024/09/25 14:32:29) <Joseph Huber>
    * | | | | | | | | b856c9fc6ab9 - [sanitizer] Extract SANITIZER_FREEBSD version of ThreadDescriptorSizeFallback (#109743) (2024/09/25 14:24:01) <Vitaly Buka>
    * | | | | | | | | 6fb39ac77bb2 - [BOLT][merge-fdata] Initialize YAML profile header (#109613) (2024/09/25 23:18:34) <Maksim Panchenko>
    * | | | | | | | | 924b3904b741 - [gn build] Port 7e5df5bcc3be (2024/09/25 21:03:28) <LLVM GN Syncbot>
    * | | | | | | | | 7e5df5bcc3be - [SandboxIR] Implement Module (#109716) (2024/09/25 14:02:52) <vporpo>
    * | | | | | | | | 7645d9c77d39 - [mlir][scf] Fix loop iteration calculation for negative step in LoopPipelining (#110035) (2024/09/25 13:32:12) <SJW>
    * | | | | | | | | 29b92d07746f - Revert "[SLP]Initial support for non-power-of-2 (but still whole register) number of elements in operands." (2024/09/25 22:05:10) <Nikita Popov>
    * | | | | | | | | c3201ddaeac0 - [flang][NFC] Refactor to remove .inc file containing shared code (#109874) (2024/09/25 14:04:38) <Tarun Prabhu>
    * | | | | | | | | eb48aac7d40e - [Clang] Automatically link the `compiler-rt` for GPUs if present (#109152) (2024/09/25 12:58:10) <Joseph Huber>
    * | | | | | | | | 8588c6ec545a - [gn build] Port eba21accf221 (2024/09/25 15:47:42) <Nico Weber>
    * | | | | | | | | b935d312f13a - [libc][math] Reapply and fix issignaling macro. (#110011) (2024/09/25 15:39:55) <Shourya Goel>
    * | | | | | | | | 2b125e899b64 - [LV] Don't pass loop preheader to getOrCreateVectorTripCount (NFCI). (2024/09/25 20:39:05) <Florian Hahn>
    * | | | | | | | | 639a0afa9955 - Revert "Deprecate the `-fbasic-block-sections=labels` option. (#107494)" (2024/09/25 12:34:43) <Kazu Hirata>
    * | | | | | | | | 1911a50fae8a - Deprecate the `-fbasic-block-sections=labels` option. (#107494) (2024/09/25 12:03:38) <Rahman Lavaee>
    * | | | | | | | | 6786928c4fe1 - [Core] Skip over target name in intrinsic name lookup (#109971) (2024/09/25 12:01:43) <Rahul Joshi>
    * | | | | | | | | 2f43e6595556 - [LLVM][TableGen] Check name conflicts between target dep and independent intrinsics  (#109826) (2024/09/25 12:01:17) <Rahul Joshi>
    * | | | | | | | | c3334dad732e - [rtsan] Add exit statistics (#109885) (2024/09/25 11:59:11) <Chris Apple>
    * | | | | | | | | 0f521931b85e - LLVMContext: add getSyncScopeName() to lookup individual scope name (#109484) (2024/09/25 11:13:56) <gonzalobg>
    * | | | | | | | | c71bfc59ee1c - [clang] Fix FileManagerTest (2024/09/25 10:54:40) <Jan Svoboda>
    * | | | | | | | | f172c31a578f - [RISCV] Lower memory ops and VP splat for zvfhmin and zvfbfmin (#109387) (2024/09/26 01:47:46) <Luke Lau>
    * | | | | | | | | eba21accf221 - [SandboxIR][Utils] Implement getMemoryLocation() (#109724) (2024/09/25 10:43:36) <vporpo>
    * | | | | | | | | 394f59c203c7 - [NVPTX] Add Read/Write/SideEffect attributes to atomic instructions (#109665) (2024/09/25 10:39:03) <Lewis Crawford>
    * | | | | | | | | b1aea98cfa35 - [clang] Make deprecations of some `FileManager` APIs formal (#110014) (2024/09/25 10:36:44) <Jan Svoboda>
    * | | | | | | | | abe0dd195a3b - [llvm-objdump] Print ... even if a data mapping symbol is active (2024/09/25 10:32:40) <Fangrui Song>
    * | | | | | | | | 3c348bf54358 - [RISCV] Fold (fmv_x_h/w (load)) to an integer load. (#109900) (2024/09/25 10:29:44) <Craig Topper>
    * | | | | | | | | 72307ba61595 - [ELF] Pass Ctx & to Driver (2024/09/25 10:22:13) <Fangrui Song>
    * | | | | | | | | b3b6141ba110 - [lldb] Fix two formatv issues in LDB_LOG (NFC) (2024/09/25 10:17:09) <Jonas Devlieghere>
    * | | | | | | | | a280275cff49 - [compiler-rt] Fix #83679 for macos sdk < 13.0 (#109946) (2024/09/25 18:11:02) <David CARLIER>
    * | | | | | | | | 660ddb3a9357 - [PS4,PS5][Driver] Pass `-L<sdk>/target/lib -L.` to linker (#109796) (2024/09/25 18:08:32) <Edd Dawson>
    * | | | | | | | | 1c1bb7749860 - [libc++abi] Fix issue when building the demangler in C++11 (2024/09/25 12:41:09) <Louis Dionne>
    * | | | | | | | | 78c6506543de - [libc++] Disable the clang-tidy checks to get CI back (#109989) (2024/09/25 12:40:14) <Louis Dionne>
    * | | | | | | | | cebb7c010854 - [clang-tidy] modernize-use-nullptr matches "NULL" in templates (#109169) (2024/09/25 09:25:46) <Thomas Köppe>
    * | | | | | | | | d01e336336f2 - [Driver] Enable ASan on Solaris/SPARC (#107403) (2024/09/25 18:15:45) <Rainer Orth>
    * | | | | | | | | fff03b07c604 -     Fix "[AArch64] Implement intrinsics for SME2 FSCALE" (#109999) (2024/09/25 17:00:40) <Lukacma>
    * | | | | | | | | aae7ac668588 - [VPlan] Remove VPIteration, update to use directly VPLane instead (NFC) (2024/09/25 16:44:42) <Florian Hahn>
    * | | | | | | | | 556ec4a72614 - [SLP] Pass operand info to getCmpSelInstrInfo (#109998) (2024/09/25 08:17:55) <Philip Reames>
    * | | | | | | | | 808c498f52c8 - Revert "[libc][math] Implement issignaling macro." (#109992) (2024/09/25 10:58:08) <lntue>
    * | | | | | | | | 88945db4dfae - [AMDGPU][SIPreEmitPeephole] pre-commit tests: mustRetainExeczBranch: use a cost model (#109816) (2024/09/25 16:57:08) <Juan Manuel Martinez Caamaño>
    * | | | | | | | | 11c423f9bebc - [clang-tidy] Add support for bsl::optional (#101450) (2024/09/25 10:54:31) <Chris Cotter>
    * | | | | | | | | 97189492a1a7 - The real option name and not the alias used is displayed in msgs when using a config file (#107613) (2024/09/25 10:51:55) <Sean Perry>
    * | | | | | | | | 4cb61c20ef38 - Revert "[NVPTX] deprecate nvvm.rotate.* intrinsics, cleanup funnel-shift handling (#107655)" (2024/09/25 14:50:26) <Dmitry Chernenkov>
    * | | | | | | | | 9a0e281e8ccf - Revert "[NVVM] Upgrade nvvm.ptr.* intrinics to addrspace cast (#109710)" (2024/09/25 14:50:26) <Dmitry Chernenkov>
    * | | | | | | | | 74dcf0b595d4 - [SystemZ][z/OS] Open text files in text mode (#109972) (2024/09/25 10:49:45) <Abhina Sree>
    * | | | | | | | | a024a0ceedae - [clang][bytecode] Override InConstantContext flag for immediate calls (#109967) (2024/09/25 16:46:46) <Timm Baeder>
    * | | | | | | | | 3be8e3ad0c42 - [flang] translate pure and elemental attribute in FIR (#109954) (2024/09/25 16:45:47) <jeanPerier>
    * | | | | | | | | 6fae8b8a4266 - [rtsan][NFC] Rename RTSAN_LINK_LIBS to RTSAN_DYNAMIC_LIBS (#109991) (2024/09/25 07:44:30) <Chris Apple>
    * | | | | | | | | 6b109a34cced - [SLP]Initial support for non-power-of-2 (but still whole register) number of elements in operands. (2024/09/25 10:43:27) <Alexey Bataev>
    * | | | | | | | | a514457e62e9 - Mark tests as unsupported when targeting z/OS (#107916) (2024/09/25 10:43:02) <Sean Perry>
    * | | | | | | | | ac802a3148cc - [libc][math] Implement issignaling macro. (#109615) (2024/09/25 10:35:20) <Shourya Goel>
    * | | | | | | | | 26e0b5077236 - [lldb][lldb-dap] Fix compilation error on 32 bit platforms (2024/09/25 14:31:57) <David Spickett>
    * | | | | | | | | d2885743630f - [TTI][RISCV] Model cost of loading constants arms of selects and compares (#109824) (2024/09/25 07:25:57) <Philip Reames>
    * | | | | | | | | 3469db82b5c8 - [SLP]Add subvector vectorization for non-load nodes (2024/09/25 10:23:41) <Alexey Bataev>
    * | | | | | | | | aea066849928 - [lldb][test] Use tools from llvm instead of compiler tools (#109961) (2024/09/25 16:19:02) <Vladislav Dzhidzhoev>
    * | | | | | | | | e9cb44090ff7 - [X86][GlobalISel] Enable scalar versions of G_UITOFP and G_FPTOUI (#100079) (2024/09/25 16:15:36) <Evgenii Kudriashov>
    * | | | | | | | | 3477eb722fe0 - [rtsan][NFC] Move away from system include style for local headers (#109977) (2024/09/25 07:15:08) <Chris Apple>
    * | | | | | | | | cd6f4cc6e646 - [LLD][COFF][NFC] Use CHPE version 2 in tests (#109872) (2024/09/25 16:13:31) <Jacek Caban>
    * | | | | | | | | 22829f757dc7 - [PS4,PS5][Driver] Fix typo in comment (NFC) (#109980) (2024/09/25 14:43:45) <Edd Dawson>
    * | | | | | | | | 35ae7ee925e0 - Remove spurious ; in ElimAvailExtern.cpp (2024/09/25 06:40:42) <Mircea Trofin>
    * | | | | | | | | 02c138f8d1d6 - [AArch64] Implement intrinsics for SME2 FSCALE (#100128) (2024/09/25 14:34:00) <Lukacma>
    * | | | | | | | | 817e742ba554 - Revert "[NFC] Switch a number of DenseMaps to SmallDenseMaps for speedup (#109417)" (2024/09/25 14:31:30) <Jeremy Morse>
    * | | | | | | | | 3f37c517fbc4 - [NFC] Switch a number of DenseMaps to SmallDenseMaps for speedup (#109417) (2024/09/25 14:22:23) <Jeremy Morse>
    * | | | | | | | | 4be1c19a9fbd - [VPlan] Adjust AnyOf after creating ComputeReductionResult (NFC). (2024/09/25 14:13:50) <Florian Hahn>
    * | | | | | | | | fd88121a58da - [rtsan] Link in proper CXX ABI library (#109715) (2024/09/25 06:09:30) <Chris Apple>
    * | | | | | | | | 8e9011b3b8dc - [LV][NFC]Fix formatting (2024/09/25 06:05:35) <Alexey Bataev>
    * | | | | | | | | ab0e8d0678f1 - [AMDGPU] Fix failing test after #109958 (#109964) (2024/09/25 15:02:23) <sstipano>
    * | | | | | | | | 60ed2361c091 - [LV][EVL]Explicitly model AVL as sub, original TC, EVL_PHI. (2024/09/25 08:58:29) <Alexey Bataev>
    * | | | | | | | | 5ef02a3fd475 - [InstCombine] Fall through to computeKnownBits() for sdiv by -1 (2024/09/25 14:23:06) <Nikita Popov>
    * | | | | | | | | 1e67e4bbba2a - [SystemZ][z/OS] z/OS does not support nanosleep, use usleep instead (#109823) (2024/09/25 08:21:29) <Abhina Sree>
    * | | | | | | | | 59693ea6d182 - [ConstantFPRange] Remove `ConstantFPRange::toKnownFPClass` (#109960) (2024/09/25 20:20:03) <Yingwei Zheng>
    * | | | | | | | | fe06a6daae6b - Reland: [clang] Diagnose dangling issues for the "Container<GSLPointer>" case. #107213 (#108344) (2024/09/25 14:12:49) <Haojian Wu>
    * | | | | | | | | 1c984b86b389 - [LLVM][TableGen] Adopt !listflatten for Intrinsic type signature (#109884) (2024/09/25 04:50:09) <Rahul Joshi>
    * | | | | | | | | 786dc5a2da9b - [lldb-dap] Simplify `readMemory` (#109485) (2024/09/25 13:49:42) <Adrian Vogelsgesang>
    * | | | | | | | | 2a29d24ba94d - [ADT] Use perfect forwarding in SmallSet::insert() (#108590) (2024/09/25 12:43:41) <Victor Campos>
    * | | | | | | | | 9583215d55b6 - [RISCV] Add splat tests for zvfbfmin and without zfhmin/zfbfmin. NFC (2024/09/25 19:41:17) <Luke Lau>
    * | | | | | | | | b40ff5ac2d40 - [AMDGPU][StructurizeCFG] Maintain branch MD_prof metadata (#109813) (2024/09/25 13:15:23) <Juan Manuel Martinez Caamaño>
    * | | | | | | | | f5838cc17ffb - [clang-tools-extra] Don't flush llvm::raw_string_ostream (NFC) (2024/09/25 06:12:45) <Youngsuk Kim>
    * | | | | | | | | dc2d0d5e1a4e - [Xtensa] Add basic support for inline asm constraints. (#108986) (2024/09/25 14:02:58) <Andrei Safronov>
    * | | | | | | | | 4f951503b9b6 - Reland "[AMDGPU][GlobalIsel] Use isRegisterClassType for G_FREEZE and G_IMPLICIT_DEF (#101331)" (#109958) (2024/09/25 13:02:29) <sstipano>
    * | | | | | | | | f43ad88ae1ad - [RISCV] Handle zvfhmin and zvfbfmin promotion to f32 in half arith costs (#108361) (2024/09/25 18:50:16) <Luke Lau>
    * | | | | | | | | 63b534be1765 - [RISCV] Fold vmv.x.s into load from stack (#109774) (2024/09/25 18:49:52) <Luke Lau>
    * | | | | | | | | 8ea0dbab2e62 - [mlir] Remove spurious CMake dependencies for convert-vector-to-llvm (NFC) (2024/09/25 03:48:46) <Mehdi Amini>
    * | | | | | | | | de70b959b152 - [AMDGPU] Fix typo in promoteUniformOpToI32 (#109942) (2024/09/25 12:42:57) <Pierre van Houtryve>
    * | | | | | | | | e4688b98cd2b - [SimplifyCFG] Avoid increasing too many phi entries when removing empty blocks (#104887) (2024/09/25 12:41:13) <Chengjun>
    * | | | | | | | | ce6c236c965d - [ADT][NFC] Simplify SmallSet (#109412) (2024/09/25 11:23:58) <Victor Campos>
    * | | | | | | | | 0c31ea5a09d8 - [Clang][SME2] Use tuple result of SME  builtins directly. (#109423) (2024/09/25 11:19:05) <Paul Walker>
    * | | | | | | | | 0ef24aa54953 - Fix for logic in combineExtract() (#108208) (2024/09/25 12:12:27) <Jonas Paulsson>
    * | | | | | | | | c71b212285bd - ProfDataUtils: Avoid dyn_extract + assert (NFC) (2024/09/25 13:55:16) <Matt Arsenault>
    * | | | | | | | | 5a038230b0a6 - [llvm][cmake] Error when a runtime is in LLVM_ENABLE_PROJECTS and LLVM_ENABLE_RUNTIMES (#109791) (2024/09/25 10:34:21) <David Spickett>
    * | | | | | | | | 5ee2deac0c3b - [lldb][AArch64][Linux] Add Floating Point Mode Register (#106695) (2024/09/25 10:27:57) <David Spickett>
    * | | | | | | | | 02f46d7fb8b2 - Revert "[Clang][LLVM][AArch64] Add intrinsic for LUTI4 SME2 instruction (#97755)" (2024/09/25 09:25:28) <Caroline Concatto>
    * | | | | | | | | b7ea2643cefe - [llvm][docs] Fix RISCVUsage docs build error (2024/09/25 10:21:45) <David Spickett>
    * | | | | | | | | 4d459136f50b - [llvm][docs] Update the project and runtimes lists (#109788) (2024/09/25 10:16:58) <David Spickett>
    * | | | | | | | | c93e29439b1a - [lldb] fix vFile:open, vFile:unlink error codes (#106950) (2024/09/25 10:13:40) <dlav-sc>
    * | | | | | | | | 706821ba8ff9 - [lldb][test] Skip TestConcurrentVFork on all Linux (2024/09/25 10:08:10) <David Spickett>
    * | | | | | | | | bbb3679ad8e5 - [SPIRV] Fix compilation error 'use of parameter from containing function' when building PR #106429 with gcc (#109924) (2024/09/25 11:06:17) <Vyacheslav Levytskyy>
    * | | | | | | | | f1bbabd6289a - [ARM] Lower arm_neon_vbsl to ARMISD::VBSP and fold (vbsl x, y, y) to y (#109761) (2024/09/25 10:03:39) <David Green>
    * | | | | | | | | 5a191e3cd904 - [RISCV][test] Correct +experimental-ztso attr to +ztso in test (2024/09/25 09:55:58) <Alex Bradbury>
    * | | | | | | | | 445d8b2d10b2 - [Clang][LLVM][AArch64] Add intrinsic for LUTI4 SME2 instruction (#97755) (2024/09/25 09:53:23) <CarolineConcatto>
    * | | | | | | | | 53907ed5081b - [clang][codegen] Don't mark "int" TBAA on FP libcalls with indirect args (#108853) (2024/09/25 09:50:55) <Benjamin Maxwell>
    * | | | | | | | | d853adee004d - [MIR] Fix return value when computed properties conflict with given prop (#109923) (2024/09/25 10:47:14) <Dominik Montada>
    * | | | | | | | | 850ee790cfca - [Bazel] Port fa824dc0dd960214865b03d8f56b18bb93e4a88b (2024/09/25 08:32:55) <Dmitry Chernenkov>
    * | | | | | | | | a36aca5e189e - [sancov] Avoid repeated map lookups (NFC) (#109906) (2024/09/25 01:32:31) <Kazu Hirata>
    * | | | | | | | | c3fc763dc165 - [MCA] Avoid repeated hash lookups (NFC) (#109905) (2024/09/25 01:31:33) <Kazu Hirata>
    * | | | | | | | | ec6003063900 - [DWARFLinker] Avoid repeated hash lookups (NFC) (#109904) (2024/09/25 01:30:40) <Kazu Hirata>
    * | | | | | | | | ba3d174d3f9e - [FuzzMutate] Avoid repeated hash lookups (NFC) (#109903) (2024/09/25 01:30:03) <Kazu Hirata>
    * | | | | | | | | 99cd4cb1231a - [LLD][MINGW] Add `--undefined-glob` flag support (#109866) (2024/09/25 11:29:40) <Miguel A. Arroyo>
    * | | | | | | | | c58e51ac9786 - [ConstantFPRange] Suppress unused result warnings. NFC. (#109921) (2024/09/25 16:21:38) <Yingwei Zheng>
    * | | | | | | | | b8d1bae64846 - [CmpInstAnalysis] Return decomposed bit test as struct (NFC) (#109819) (2024/09/25 10:14:15) <Nikita Popov>
    * | | | | | | | | cda0cb393930 - [NFC][LoopVectorize] Remove unused argument from fixupIVUsers (#109789) (2024/09/25 08:56:37) <David Sherwood>
    * | | | | | | | | 4f90e75bdc15 - [AMDGPU] Do not count implicit VGPRs in SIInsertWaitcnts (#109049) (2024/09/25 00:41:49) <Stanislav Mekhanoshin>
    * | | | | | | | | 8e3cde04cbf1 - [LoongArch][test] Add float-point atomic load/store tests. NFC (2024/09/25 15:39:22) <WANG Rui>
    * | | | | | | | | b7b945b09cdd - LiveRangeCalc: Pass output stream to verify (2024/09/25 11:36:54) <Matt Arsenault>
    * | | | | | | | | 0259f9271159 - [mlir][memref] Add builder that infers `reinterpret_cast` result type (#109432) (2024/09/25 09:33:15) <Matthias Springer>
    * | | | | | | | | 2ccac07bf22d - [C++20][Modules] Fix crash when function and lambda inside loaded from different modules (#109167) (2024/09/25 08:31:49) <Dmitry Polukhin>
    * | | | | | | | | ae7b454f98ba - Revert "[MLIR] Make `OneShotModuleBufferize` use `OpInterface`" (#109919) (2024/09/25 09:17:49) <Matthias Springer>
    * | | | | | | | | 90c14748638f - [SDAG] Honor signed arguments in floating point libcalls (#109134) (2024/09/25 11:09:50) <Timothy Pearson>
    * | | | | | | | | d7c6e9438363 - [AMDGPU][StructurizeCFG] pre-commit tests: maintain branch_weights metadata (#109812) (2024/09/25 08:57:18) <Juan Manuel Martinez Caamaño>
    * | | | | | | | | 7c825f0d6a6d - [gn build] Port fa824dc0dd96 (2024/09/25 06:37:47) <LLVM GN Syncbot>
    * | | | | | | | | df6822f4eb81 - [lldb] Fix error reporting in SBTarget::ReadMemory (#109764) (2024/09/25 08:31:42) <Pavel Labath>
NG  * | | | | | | | | a6ea0b0d2973 - [compiler-rt] intercept macOs's freadlink call. (#83679) (2024/09/25 07:28:07) <David CARLIER>
OK  * | | | | | | | | c08a4376442a - [GlobalISel] Fix a warning (2024/09/24 23:24:31) <Kazu Hirata>
    * | | | | | | | | 832297ca32f4 - Fix compatibility version in test (#97128) (2024/09/24 23:22:20) <Richard Smith>
    * | | | | | | | | 1cdcec5884fb - [clang][bytecode] Handle vector comma op (#109827) (2024/09/25 14:09:06) <yronglin>
    * | | | | | | | | 1cb12fa9edd7 - [GlobalISel] Combine unmerge(unmerge()) if the result is legal. (#109606) (2024/09/25 07:04:09) <David Green>
    * | | | | | | | | c2fd3b76f216 - [ASan][test] XFAIL stack overflow tests on Linux/sparc64 (#109773) (2024/09/25 08:03:12) <Rainer Orth>
    * | | | | | | | | 416f101111e0 - [clang] Use std::optional::value_or (NFC) (#109894) (2024/09/24 23:01:45) <Kazu Hirata>
    * | | | | | | | | 4bd3a62cd600 - [clang][bytecode] Fix diagnosing std::construct_at with wrong type (#109828) (2024/09/25 08:00:32) <Timm Baeder>
    * | | | | | | | | d8f555d62546 - [UBSan] Diagnose assumption violation (#104741) (2024/09/25 13:59:10) <Yingwei Zheng>
    * | | | | | | | | fa824dc0dd96 - [LLVM][IR] Add constant range support for floating-point types (#86483) (2024/09/25 13:58:23) <Yingwei Zheng>
    * | | | | | | | | 915fe84c6d78 - [ctx_prof] Simplify ingestContext (NFC) (#109902) (2024/09/24 22:53:16) <Kazu Hirata>
    * | | | | | | | | e1365ce2220d - [clang][bytecode][NFC] Add type assertions to ArrayElem{,Pop} (#109829) (2024/09/25 07:44:05) <Timm Baeder>
    * | | | | | | | | 470e5afe6969 - [bazel] Port f586b1e3f42788025aa6f55be70c5e361cc8b529 (#109908) (2024/09/24 22:35:50) <Keith Smiley>
    * | | | | | | | | f586b1e3f427 - [MLIR] Make `OneShotModuleBufferize` use `OpInterface` (#107295) (2024/09/25 07:27:21) <Tzung-Han Juang>
    * | | | | | | | | 614aeda93b22 - [RISCV] Mark Zacas as non-experimental (#109651) (2024/09/25 06:14:43) <Alex Bradbury>
    * | | | | | | | | c92137e474d5 - [NFC][TableGen] Adopt scaled indent in PredicateExpander (#109801) (2024/09/24 22:05:51) <Rahul Joshi>
    * | | | | | | | | 74d9f7ce80e8 - [llvm] Use std::optional::value_or (NFC) (#109890) (2024/09/24 21:49:06) <Kazu Hirata>
    * | | | | | | | | d0878f13dffa - [RISCV] Use RVVBitsPerBlock in assignRVVStackObjectOffsets and adjustReg. NFC (#109848) (2024/09/24 21:36:55) <Craig Topper>
    * | | | | | | | | 3b8c78a61045 - [RISCV] Enable f16 vget/vset/vcreate/vlmul_ext/vlmul_trunc/vundefined intrinsics with Zvfhmin. (#109889) (2024/09/24 21:36:14) <Craig Topper>
    * | | | | | | | | b2180481ec2d - [hwasan] Consider order of mapping copts (#109621) (2024/09/24 21:11:13) <Vitaly Buka>
    * | | | | | | | | cfe1adc42a5e - Reland: [DirectX] Add atan2 intrinsic and expand for DXIL backend (p1) (#109878) (2024/09/25 00:06:13) <Tex Riddell>
    * | | | | | | | | 81dac7d613c9 - [Flang][OpenMP] Add Semantic Checks for Atomic Capture Construct (#108516) (2024/09/25 09:29:44) <harishch4>
    | | | | | | | | | * 26682b7661d4 - (origin/users/Akshat-Oke/port-si-pre-allocate-wwm) [NewPM][AMDGPU] Port SIPreAllocateWWMRegs to NPM (2024/09/25 11:36:43) <Akshat Oke>
    | | | | | | | | | * 3d8720930eaf - (origin/users/Akshat-Oke/09-25-_amdgpu_add_tests_for_sipreallocatewwmregs) [AMDGPU] Add tests for SIPreAllocateWWMRegs (2024/09/25 11:22:20) <Akshat Oke>
    | | | | | | | | | * 22bb8f0e0708 - (origin/users/Akshat-Oke/port-lrm) [NewPM][CodeGen] Port LiveRegMatrix to NPM (2024/09/25 10:50:07) <Akshat Oke>
    | | | | | | | | | * ea4b201efb96 - (origin/users/Akshat-Oke/update-dep) Update correct dependency (2024/09/24 08:58:45) <Akshat Oke>
    | | | | | | | | | * 091304c8ffee - (origin/users/Akshat-Oke/port-vrm) [NewPM][CodeGen] Port VirtRegMap to NPM (2024/09/24 08:58:45) <Akshat Oke>
    | | | | | | | | | | *   9bc6c9ea6290 - (origin/users/MaskRay/spr/riscv-restore-dw_eh_pe_uleb128-call-site-encoding-for-gcc_except_table) rebase (2024/09/24 20:57:34) <Fangrui Song>
    | | | | | | | | | | |\  
    | |_|_|_|_|_|_|_|_|_|/  
    |/| | | | | | | | | |   
OK  * | | | | | | | | | | d50eaac12f0c - (HEAD) Revert "[clang][CodeGen] Zero init unspecified fields in initializers in C" (#109898) (2024/09/24 20:31:54) <Eli Friedman>
    * | | | | | | | | | | 18b9d49ce337 - lldb: get lldb API tests working with newer Android NDKs (2024/09/24 20:00:34) <Andrew Rogers>
    * | | | | | | | | | | fa627d98e875 - [flang][cuda] Add entry point for alloc/free and simple copy (#109867) (2024/09/24 20:00:11) <Valentin Clement (バレンタイン クレメン)>
    | | | | | | | | | | * faf0bcf968a2 - [𝘀𝗽𝗿] initial version (2024/01/07 22:43:57) <Fangrui Song>```

@devnexen
Copy link
Member Author

It is already an old commit did you try to update ? Why I mentioned the other commit it s because it s supposed to fix it.

@expcov
Copy link

expcov commented Sep 28, 2024

I got the code for the main branch on Sept 28th and the build is failing. I think it is not fixed properly as it seems to include the following commits.

a280275cff49 - [compiler-rt] Fix #83679 for macos sdk < 13.0 (#109946) (2024/09/25 18:11:02) <David CARLIER>

@devnexen
Copy link
Member Author

Ok thanks for confirming, looking into it.

devnexen added a commit to devnexen/llvm-project that referenced this pull request Sep 28, 2024
using __MAC_OS_X_VERSION_MIN_REQUIRED instead.
devnexen added a commit to devnexen/llvm-project that referenced this pull request Sep 28, 2024
using __MAC_OS_X_VERSION_MIN_REQUIRED instead.
devnexen added a commit that referenced this pull request Sep 29, 2024
using __MAC_OS_X_VERSION_MIN_REQUIRED instead.
@zmodem
Copy link
Collaborator

zmodem commented Oct 2, 2024

The lit test has been failing since it landed, see e.g. https://green.lab.llvm.org/job/llvm.org/job/clang-stage1-RA/2276/testReport/

I'll revert until this can be fixed.

zmodem added a commit that referenced this pull request Oct 2, 2024
The lit test has been failing on green dragon since it landed,
e.g. https://green.lab.llvm.org/job/llvm.org/job/clang-stage1-RA/2276/testReport/

This reverts commit a6ea0b0 and
follow-up commits ce72c76,
a280275, and
d705bd2.
Sterling-Augustine pushed a commit to Sterling-Augustine/llvm-project that referenced this pull request Oct 3, 2024
The lit test has been failing on green dragon since it landed,
e.g. https://green.lab.llvm.org/job/llvm.org/job/clang-stage1-RA/2276/testReport/

This reverts commit a6ea0b0 and
follow-up commits ce72c76,
a280275, and
d705bd2.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants