[llvm-branch-commits] [llvm] [RISCV][MC] Warn if SEW/LMUL may not be compatible (PR #94313)

2024-06-10 Thread Pengcheng Wang via llvm-branch-commits
https://github.com/wangpc-pp updated https://github.com/llvm/llvm-project/pull/94313 >From 6e3d6329300e27a23481df3e6e01b9763a34d9d2 Mon Sep 17 00:00:00 2001 From: Wang Pengcheng Date: Thu, 6 Jun 2024 15:05:20 +0800 Subject: [PATCH 1/2] Address comments Created using spr 1.3.6-beta.1 --- .../T

[llvm-branch-commits] [llvm] [RISCV][MC] Warn if SEW/LMUL may not be compatible (PR #94313)

2024-06-10 Thread Pengcheng Wang via llvm-branch-commits
https://github.com/wangpc-pp updated https://github.com/llvm/llvm-project/pull/94313 >From 6e3d6329300e27a23481df3e6e01b9763a34d9d2 Mon Sep 17 00:00:00 2001 From: Wang Pengcheng Date: Thu, 6 Jun 2024 15:05:20 +0800 Subject: [PATCH 1/2] Address comments Created using spr 1.3.6-beta.1 --- .../T

[llvm-branch-commits] [clang] 809adec - Revert "[llvm][IR] Extend BranchWeightMetadata to track provenance of weights…"

2024-06-10 Thread via llvm-branch-commits
Author: Paul Kirth Date: 2024-06-10T16:43:14-07:00 New Revision: 809adec88edb2cdca5c97d612865c9789233d3c3 URL: https://github.com/llvm/llvm-project/commit/809adec88edb2cdca5c97d612865c9789233d3c3 DIFF: https://github.com/llvm/llvm-project/commit/809adec88edb2cdca5c97d612865c9789233d3c3.diff LO

[llvm-branch-commits] [msan] Handle blendv intrinsics (PR #94882)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94882 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [msan] Handle blendv intrinsics (PR #94882)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94882 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [msan] Handle blendv intrinsics (PR #94882)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
@@ -3357,6 +3357,37 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + Value *convertBlendvToSelectMask(IRBuilder<> &IRB, Value *C) { vitalybuka wrote: they are member of MemorySanitizerVisitor:: and access some fields

[llvm-branch-commits] [msan] Handle blendv intrinsics (PR #94882)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
@@ -3357,6 +3357,37 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + Value *convertBlendvToSelectMask(IRBuilder<> &IRB, Value *C) { vitalybuka wrote: CreateAppToShadowCast can't be static https://github.com/llvm/llvm

[llvm-branch-commits] [msan] Implement shadow propagation for _mm_dp_pd, _mm_dp_ps, _mm256_dp_ps (PR #94875)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
@@ -3287,6 +3287,76 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + // Convert `Mask` into ``. + Constant *createDppMask(unsigned Width, unsigned Mask) { +SmallVector R; +R.assign(Width, ConstantInt::getFalse(F.getContext()))

[llvm-branch-commits] [msan] Implement shadow propagation for _mm_dp_pd, _mm_dp_ps, _mm256_dp_ps (PR #94875)

2024-06-10 Thread Florian Mayer via llvm-branch-commits
@@ -3287,6 +3287,76 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + // Convert `Mask` into ``. + Constant *createDppMask(unsigned Width, unsigned Mask) { +SmallVector R; +R.assign(Width, ConstantInt::getFalse(F.getContext()))

[llvm-branch-commits] [msan] Implement shadow propagation for _mm_dp_pd, _mm_dp_ps, _mm256_dp_ps (PR #94875)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
@@ -3287,6 +3287,76 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + // Convert `Mask` into ``. + Constant *createDppMask(unsigned Width, unsigned Mask) { +SmallVector R; +R.assign(Width, ConstantInt::getFalse(F.getContext()))

[llvm-branch-commits] [clang] [clang] Implement pointer authentication for C++ virtual functions, v-tables, and VTTs (PR #94056)

2024-06-10 Thread Oliver Hunt via llvm-branch-commits
@@ -7037,8 +7036,64 @@ void ItaniumMangleContextImpl::mangleCXXDtorComdat(const CXXDestructorDecl *D, Mangler.mangle(GlobalDecl(D, Dtor_Comdat)); } +static void mangleOverrideDiscrimination(CXXNameMangler &mangler, + ASTContext &conte

[llvm-branch-commits] [libcxx] [libc++][TZDB] Finishes zoned_time member functions. (PR #95026)

2024-06-10 Thread Mark de Wever via llvm-branch-commits
https://github.com/mordante updated https://github.com/llvm/llvm-project/pull/95026 >From ad83e31016100fede20971e7ac16dbdd8137504d Mon Sep 17 00:00:00 2001 From: Mark de Wever Date: Wed, 17 Apr 2024 21:00:22 +0200 Subject: [PATCH] [libc++][TZDB] Finishes zoned_time member functions. Note the i

[llvm-branch-commits] [NFC][msan] Prepare function to extract main logic (PR #94880)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94880 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [NFC][msan] Prepare function to extract main logic (PR #94880)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94880 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [flang] [flang] Lower REDUCE intrinsic with DIM argument (PR #94771)

2024-06-10 Thread Valentin Clement バレンタイン クレメン via llvm-branch-commits
https://github.com/clementval updated https://github.com/llvm/llvm-project/pull/94771 >From 87a01d458650f4c6fd9b0456acbca51094bd127b Mon Sep 17 00:00:00 2001 From: Valentin Clement Date: Thu, 6 Jun 2024 14:17:44 -0700 Subject: [PATCH] [flang] Lower REDUCE intrinsic with DIM argument --- .../O

[llvm-branch-commits] [libcxx] [libc++][TZDB] Finishes zoned_time member functions. (PR #95026)

2024-06-10 Thread via llvm-branch-commits
llvmbot wrote: @llvm/pr-subscribers-libcxx Author: Mark de Wever (mordante) Changes Note the implementation of zoned_time& operator=(const local_time& lt); is not correct; however the wording cannot be easily implemented. It could be if the object caches the local_time assigne

[llvm-branch-commits] [libcxx] [libc++][TZDB] Finishes zoned_time member functions. (PR #95026)

2024-06-10 Thread Mark de Wever via llvm-branch-commits
https://github.com/mordante created https://github.com/llvm/llvm-project/pull/95026 Note the implementation of zoned_time& operator=(const local_time& lt); is not correct; however the wording cannot be easily implemented. It could be if the object caches the local_time assigned. However this

[llvm-branch-commits] [msan] Implement shadow propagation for _mm_dp_pd, _mm_dp_ps, _mm256_dp_ps (PR #94875)

2024-06-10 Thread Florian Mayer via llvm-branch-commits
https://github.com/fmayer edited https://github.com/llvm/llvm-project/pull/94875 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [msan] Implement shadow propagation for _mm_dp_pd, _mm_dp_ps, _mm256_dp_ps (PR #94875)

2024-06-10 Thread Florian Mayer via llvm-branch-commits
@@ -3287,6 +3287,76 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + // Convert `Mask` into ``. + Constant *createDppMask(unsigned Width, unsigned Mask) { +SmallVector R; +R.assign(Width, ConstantInt::getFalse(F.getContext()))

[llvm-branch-commits] [msan] Implement shadow propagation for _mm_dp_pd, _mm_dp_ps, _mm256_dp_ps (PR #94875)

2024-06-10 Thread Florian Mayer via llvm-branch-commits
@@ -3287,6 +3287,76 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + // Convert `Mask` into ``. + Constant *createDppMask(unsigned Width, unsigned Mask) { +SmallVector R; +R.assign(Width, ConstantInt::getFalse(F.getContext()))

[llvm-branch-commits] [msan] Implement shadow propagation for _mm_dp_pd, _mm_dp_ps, _mm256_dp_ps (PR #94875)

2024-06-10 Thread Florian Mayer via llvm-branch-commits
@@ -3287,6 +3287,76 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + // Convert `Mask` into ``. + Constant *createDppMask(unsigned Width, unsigned Mask) { +SmallVector R; +R.assign(Width, ConstantInt::getFalse(F.getContext()))

[llvm-branch-commits] [llvm] 0491cea - Revert "[MC][NFC] Make ELFUniquingMap a StringMap (#95006)"

2024-06-10 Thread via llvm-branch-commits
Author: aengelke Date: 2024-06-10T20:57:30+02:00 New Revision: 0491cea05e65c0f2fac9c268df01de65f437c2ba URL: https://github.com/llvm/llvm-project/commit/0491cea05e65c0f2fac9c268df01de65f437c2ba DIFF: https://github.com/llvm/llvm-project/commit/0491cea05e65c0f2fac9c268df01de65f437c2ba.diff LOG:

[llvm-branch-commits] [msan] Handle blendv intrinsics (PR #94882)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94882 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [msan] Handle blendv intrinsics (PR #94882)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94882 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [NFC][msan] Extract `handleSelectLikeInst` (PR #94881)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94881 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [NFC][msan] Extract `handleSelectLikeInst` (PR #94881)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94881 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [NFC][msan] Prepare function to extract main logic (PR #94880)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94880 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [msan] Implement shadow propagation for _mm_dp_pd, _mm_dp_ps, _mm256_dp_ps (PR #94875)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94875 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [NFC][msan] Prepare function to extract main logic (PR #94880)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94880 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [msan] Implement shadow propagation for _mm_dp_pd, _mm_dp_ps, _mm256_dp_ps (PR #94875)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/94875 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [NFC][msan] Prepare function to extract main logic (PR #94880)

2024-06-10 Thread Thurston Dang via llvm-branch-commits
https://github.com/thurstond approved this pull request. https://github.com/llvm/llvm-project/pull/94880 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [NFC][msan] Extract `handleSelectLikeInst` (PR #94881)

2024-06-10 Thread Thurston Dang via llvm-branch-commits
https://github.com/thurstond approved this pull request. https://github.com/llvm/llvm-project/pull/94881 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [NFC][msan] Extract `handleSelectLikeInst` (PR #94881)

2024-06-10 Thread Florian Mayer via llvm-branch-commits
https://github.com/fmayer approved this pull request. https://github.com/llvm/llvm-project/pull/94881 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [msan] Handle blendv intrinsics (PR #94882)

2024-06-10 Thread Florian Mayer via llvm-branch-commits
@@ -3357,6 +3357,37 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + Value *convertBlendvToSelectMask(IRBuilder<> &IRB, Value *C) { fmayer wrote: should these two be `static`? https://github.com/llvm/llvm-project/pul

[llvm-branch-commits] [libcxx] [libc++][TZDB] Finishes zoned_time constructors. (PR #95010)

2024-06-10 Thread Mark de Wever via llvm-branch-commits
https://github.com/mordante updated https://github.com/llvm/llvm-project/pull/95010 >From e374d900e2b3524b466013d61b9c3911c862c8fa Mon Sep 17 00:00:00 2001 From: Mark de Wever Date: Wed, 17 Apr 2024 21:00:22 +0200 Subject: [PATCH] [libc++][TZDB] Finishes zoned_time constructors. Completes - LW

[llvm-branch-commits] [libcxx] [libc++][TZDB] Finishes zoned_time constructors. (PR #95010)

2024-06-10 Thread Mark de Wever via llvm-branch-commits
https://github.com/mordante updated https://github.com/llvm/llvm-project/pull/95010 >From edac5048367b80622007cbd199483cc2eda29efb Mon Sep 17 00:00:00 2001 From: Mark de Wever Date: Wed, 17 Apr 2024 21:00:22 +0200 Subject: [PATCH] [libc++][TZDB] Finishes zoned_time constructors. Completes - LW

[llvm-branch-commits] [hwasan] Distinguish overflow and underflow (PR #76131)

2024-06-10 Thread Vitaly Buka via llvm-branch-commits
https://github.com/vitalybuka converted_to_draft https://github.com/llvm/llvm-project/pull/76131 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] [Support] Integrate SipHash.cpp into libSupport. (PR #94394)

2024-06-10 Thread Anton Korobeynikov via llvm-branch-commits
@@ -1,185 +1,149 @@ -/* - SipHash reference C implementation - - Copyright (c) 2012-2022 Jean-Philippe Aumasson - - Copyright (c) 2012-2014 Daniel J. Bernstein - - To the extent possible under law, the author(s) have dedicated all copyright - and related and neighbor

[llvm-branch-commits] [llvm] [Support] Integrate SipHash.cpp into libSupport. (PR #94394)

2024-06-10 Thread Anton Korobeynikov via llvm-branch-commits
@@ -1,185 +1,149 @@ -/* - SipHash reference C implementation - - Copyright (c) 2012-2022 Jean-Philippe Aumasson - - Copyright (c) 2012-2014 Daniel J. Bernstein - - To the extent possible under law, the author(s) have dedicated all copyright - and related and neighbor

[llvm-branch-commits] [llvm] [Support] Integrate SipHash.cpp into libSupport. (PR #94394)

2024-06-10 Thread Anton Korobeynikov via llvm-branch-commits
@@ -1,185 +1,149 @@ -/* - SipHash reference C implementation - - Copyright (c) 2012-2022 Jean-Philippe Aumasson - - Copyright (c) 2012-2014 Daniel J. Bernstein - - To the extent possible under law, the author(s) have dedicated all copyright - and related and neighbor

[llvm-branch-commits] [libcxx] [libc++][TZDB] Finishes zoned_time constructors. (PR #95010)

2024-06-10 Thread Mark de Wever via llvm-branch-commits
https://github.com/mordante updated https://github.com/llvm/llvm-project/pull/95010 >From fc3076706f093903ab298fc934d848e9dd58bf51 Mon Sep 17 00:00:00 2001 From: Mark de Wever Date: Wed, 17 Apr 2024 21:00:22 +0200 Subject: [PATCH] [libc++][TZDB] Finishes zoned_time constructors. Completes - LW

[llvm-branch-commits] [libcxx] [libc++][TZDB] Finishes zoned_time constructors. (PR #95010)

2024-06-10 Thread via llvm-branch-commits
llvmbot wrote: @llvm/pr-subscribers-libcxx Author: Mark de Wever (mordante) Changes Completes - LWG3225 zoned_time converting constructor shall not be noexcept - LWG3226 zoned_time constructor from string_view should accept zoned_time Implements parts of: - P0355

[llvm-branch-commits] [libcxx] [libc++][TZDB] Finishes zoned_time constructors. (PR #95010)

2024-06-10 Thread Mark de Wever via llvm-branch-commits
https://github.com/mordante created https://github.com/llvm/llvm-project/pull/95010 Completes - LWG3225 zoned_time converting constructor shall not be noexcept - LWG3226 zoned_time constructor from string_view should accept zoned_time Implements parts of: - P0355 Extending to chrono Calendars

[llvm-branch-commits] [clang] [clang] Implement pointer authentication for C++ virtual functions, v-tables, and VTTs (PR #94056)

2024-06-10 Thread Anton Korobeynikov via llvm-branch-commits
asl wrote: > @asl It would be nice if you submit the next round of review as a single > review, instead of 29 individual comments. Oh, strange. I thought it was a single review... https://github.com/llvm/llvm-project/pull/94056 ___ llvm-branch-commit

[llvm-branch-commits] [libcxx] [libc++] Implement std::move_only_function (P0288R9) (PR #94670)

2024-06-10 Thread Nikolas Klauser via llvm-branch-commits
@@ -0,0 +1,233 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apa

[llvm-branch-commits] [libcxx] [libc++] Implement std::move_only_function (P0288R9) (PR #94670)

2024-06-10 Thread via llvm-branch-commits
@@ -0,0 +1,233 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apa

[llvm-branch-commits] [libcxx] [libc++] Implement std::move_only_function (P0288R9) (PR #94670)

2024-06-10 Thread via llvm-branch-commits
EricWF wrote: > @EricWF When switching to `__libcpp_operator_{new,delete}` everything gets > compiled exactly the same on my system. Could you disclose which test you > used for this code? You also claim that the `__pointer_int_pair` causes the > optimizer to lose track of the function pointer

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -354,6 +354,23 @@ Given that ``signedPointer`` matches the layout for signed pointers signed with the given key, extract the raw pointer from it. This operation does not trap and cannot fail, even if the pointer is not validly signed. +``ptrauth_sign_constant`` +^

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -2074,16 +2091,91 @@ static bool checkPointerAuthValue(Sema &S, Expr *&Arg, if (convertArgumentToType(S, Arg, ExpectedTy)) return true; - // Warn about null pointers for non-generic sign and auth operations. - if ((OpKind == PAO_Sign || OpKind == PAO_Auth) && -

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -0,0 +1,21 @@ +// RUN: %clang_cc1 -triple arm64-apple-ios -fptrauth-intrinsics -emit-llvm %s -o - | FileCheck %s +// RUN: %clang_cc1 -triple aarch64-elf -fptrauth-intrinsics -emit-llvm %s -o - | FileCheck %s + +extern int external; + +// CHECK: @ptr1 = global ptr ptraut

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -2074,16 +2091,91 @@ static bool checkPointerAuthValue(Sema &S, Expr *&Arg, if (convertArgumentToType(S, Arg, ExpectedTy)) return true; - // Warn about null pointers for non-generic sign and auth operations. - if ((OpKind == PAO_Sign || OpKind == PAO_Auth) && -

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -2074,16 +2091,91 @@ static bool checkPointerAuthValue(Sema &S, Expr *&Arg, if (convertArgumentToType(S, Arg, ExpectedTy)) return true; - // Warn about null pointers for non-generic sign and auth operations. - if ((OpKind == PAO_Sign || OpKind == PAO_Auth) && -

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -2061,6 +2071,58 @@ ConstantLValueEmitter::VisitCallExpr(const CallExpr *E) { } } +ConstantLValue +ConstantLValueEmitter::emitPointerAuthSignConstant(const CallExpr *E) { + llvm::Constant *UnsignedPointer = emitPointerAuthPointer(E->getArg(0)); + unsigned Key = emitPoin

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
https://github.com/kovdan01 requested changes to this pull request. https://github.com/llvm/llvm-project/pull/93904 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-comm

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -2061,6 +2071,58 @@ ConstantLValueEmitter::VisitCallExpr(const CallExpr *E) { } } +ConstantLValue +ConstantLValueEmitter::emitPointerAuthSignConstant(const CallExpr *E) { + llvm::Constant *UnsignedPointer = emitPointerAuthPointer(E->getArg(0)); + unsigned Key = emitPoin

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -938,6 +938,11 @@ class CodeGenModule : public CodeGenTypeCache { // Return the function body address of the given function. llvm::Constant *GetFunctionStart(const ValueDecl *Decl); + llvm::Constant *getConstantSignedPointer(llvm::Constant *Pointer, +

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -354,6 +354,23 @@ Given that ``signedPointer`` matches the layout for signed pointers signed with the given key, extract the raw pointer from it. This operation does not trap and cannot fail, even if the pointer is not validly signed. +``ptrauth_sign_constant`` +^

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -2030,8 +2030,25 @@ bool Sema::checkConstantPointerAuthKey(Expr *Arg, unsigned &Result) { return false; } +static std::pair +findConstantBaseAndOffset(Sema &S, Expr *E) { + // Must evaluate as a pointer. + Expr::EvalResult Result; + if (!E->EvaluateAsRValue(Result, S.

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -0,0 +1,21 @@ +// RUN: %clang_cc1 -triple arm64-apple-ios -fptrauth-intrinsics -emit-llvm %s -o - | FileCheck %s +// RUN: %clang_cc1 -triple aarch64-elf -fptrauth-intrinsics -emit-llvm %s -o - | FileCheck %s + +extern int external; + +// CHECK: @ptr1 = global ptr ptraut

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -354,6 +354,23 @@ Given that ``signedPointer`` matches the layout for signed pointers signed with the given key, extract the raw pointer from it. This operation does not trap and cannot fail, even if the pointer is not validly signed. +``ptrauth_sign_constant`` +^

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
https://github.com/kovdan01 edited https://github.com/llvm/llvm-project/pull/93904 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [clang] [clang] Define ptrauth_sign_constant builtin. (PR #93904)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -2030,8 +2030,25 @@ bool Sema::checkConstantPointerAuthKey(Expr *Arg, unsigned &Result) { return false; } +static std::pair +findConstantBaseAndOffset(Sema &S, Expr *E) { + // Must evaluate as a pointer. + Expr::EvalResult Result; + if (!E->EvaluateAsRValue(Result, S.

[llvm-branch-commits] [llvm] 300a496 - Revert "[Misc] Use `LLVM_ENABLE_ABI_BREAKING_CHECKS` correctly (#94212)"

2024-06-10 Thread via llvm-branch-commits
Author: paperchalice Date: 2024-06-10T22:08:51+08:00 New Revision: 300a496d4cfec331b080b597cd2f99d5ffc3c6e7 URL: https://github.com/llvm/llvm-project/commit/300a496d4cfec331b080b597cd2f99d5ffc3c6e7 DIFF: https://github.com/llvm/llvm-project/commit/300a496d4cfec331b080b597cd2f99d5ffc3c6e7.diff

[llvm-branch-commits] [lld] [llvm] release/18.x: [lld] Fix -ObjC load behavior with LTO (#92162) (PR #92478)

2024-06-10 Thread via llvm-branch-commits
https://github.com/AtariDreams closed https://github.com/llvm/llvm-project/pull/92478 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/18.x: [DAGCombiner] In mergeTruncStore, make sure we aren't storing shifted in bits. (#90939) (PR #91038)

2024-06-10 Thread via llvm-branch-commits
https://github.com/AtariDreams closed https://github.com/llvm/llvm-project/pull/91038 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [clang] [llvm] [clang] Define ptrauth_string_discriminator builtin. (PR #93903)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
https://github.com/kovdan01 edited https://github.com/llvm/llvm-project/pull/93903 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [clang] [llvm] [clang] Define ptrauth_string_discriminator builtin. (PR #93903)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -328,6 +328,21 @@ be done in a single instruction with an immediate integer. ``pointer`` must have pointer type, and ``integer`` must have integer type. The result has type ``ptrauth_extra_data_t``. +``ptrauth_string_discriminator`` + + +.. c

[llvm-branch-commits] [clang] [llvm] [clang] Define ptrauth_string_discriminator builtin. (PR #93903)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
@@ -112,6 +135,17 @@ typedef __UINTPTR_TYPE__ ptrauth_generic_signature_t; #define ptrauth_auth_data(__value, __old_key, __old_data) \ __builtin_ptrauth_auth(__value, __old_key, __old_data) +/* Compute a constant discriminator from the given string. + +

[llvm-branch-commits] [clang] [llvm] [clang] Define ptrauth_string_discriminator builtin. (PR #93903)

2024-06-10 Thread Daniil Kovalev via llvm-branch-commits
https://github.com/kovdan01 commented: @ahmedbougacha After the latest force-push, the PR seems to contain SipHash-related changes from PRs 93902, 94393 and 94394. Could you please limit the changes only to those which are actually being intended to be merged as a part of this PR and resolve m