[clang] 9c72a30 - [clang][ASTImporter] New fix for default template parameter values. (#101836)

2024-09-06 Thread via cfe-commits
Author: Balázs Kéri Date: 2024-09-06T09:08:26+02:00 New Revision: 9c72a308d839a27ffcbb0c67104baceb1871c50e URL: https://github.com/llvm/llvm-project/commit/9c72a308d839a27ffcbb0c67104baceb1871c50e DIFF: https://github.com/llvm/llvm-project/commit/9c72a308d839a27ffcbb0c67104baceb1871c50e.diff L

[clang] [clang][ASTImporter] New fix for default template parameter values. (PR #101836)

2024-09-06 Thread Balázs Kéri via cfe-commits
https://github.com/balazske closed https://github.com/llvm/llvm-project/pull/101836 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Add target intrinsic for s_buffer_prefetch_data (PR #107293)

2024-09-06 Thread Stanislav Mekhanoshin via cfe-commits
@@ -9934,6 +9934,12 @@ SDValue SITargetLowering::LowerINTRINSIC_VOID(SDValue Op, auto NewMI = DAG.getMachineNode(Opc, DL, Op->getVTList(), Ops); return SDValue(NewMI, 0); } + case Intrinsic::amdgcn_s_prefetch_data: { +// For non-global address space preserve the

[clang] [llvm] [AMDGPU] Add target intrinsic for s_buffer_prefetch_data (PR #107293)

2024-09-06 Thread Stanislav Mekhanoshin via cfe-commits
@@ -9934,6 +9934,12 @@ SDValue SITargetLowering::LowerINTRINSIC_VOID(SDValue Op, auto NewMI = DAG.getMachineNode(Opc, DL, Op->getVTList(), Ops); return SDValue(NewMI, 0); } + case Intrinsic::amdgcn_s_prefetch_data: { +// For non-global address space preserve the

[clang] 30a9cac - [clang][ASTImporter] Fix -Wpessimizing-move in ASTImporter.cpp (NFC)

2024-09-06 Thread Jie Fu via cfe-commits
Author: Jie Fu Date: 2024-09-06T15:14:18+08:00 New Revision: 30a9cace807d4b5c98f2d0e2bd5bdea49061c8b8 URL: https://github.com/llvm/llvm-project/commit/30a9cace807d4b5c98f2d0e2bd5bdea49061c8b8 DIFF: https://github.com/llvm/llvm-project/commit/30a9cace807d4b5c98f2d0e2bd5bdea49061c8b8.diff LOG: [

[clang] [clang][ASTImporter] New fix for default template parameter values. (PR #101836)

2024-09-06 Thread LLVM Continuous Integration via cfe-commits
=?utf-8?q?Balázs_Kéri?= , =?utf-8?q?Balázs_Kéri?= Message-ID: In-Reply-To: llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-ppc64le-linux` running on `ppc64le-sanitizer` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm

[clang] [llvm] [X86][AVX10.2] Support AVX10.2-BF16 new instructions. (PR #101603)

2024-09-06 Thread Freddy Ye via cfe-commits
@@ -205,7 +214,8 @@ bool X86ATTInstPrinter::printVecCompareInstr(const MCInst *MI, printwordmem(MI, CurOp--, OS); else printdwordmem(MI, CurOp--, OS); - } else if ((Desc.TSFlags & X86II::OpPrefixMask) == X86II::XD) { +

[clang] [clang][ASTImporter] New fix for default template parameter values. (PR #101836)

2024-09-06 Thread LLVM Continuous Integration via cfe-commits
=?utf-8?q?Balázs_Kéri?= , =?utf-8?q?Balázs_Kéri?= Message-ID: In-Reply-To: llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux` running on `sanitizer-buildbot2` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llv

[clang] [clang-format] Correctly annotate braces in macro definition (PR #107352)

2024-09-06 Thread Owen Pan via cfe-commits
owenca wrote: Done in #107531. https://github.com/llvm/llvm-project/pull/107352 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 62fec3d - [NFCI] [ClangScanDeps] [P1689] Use PreprocessorOnly Action for P1689

2024-09-06 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2024-09-06T15:20:59+08:00 New Revision: 62fec3d23d2325869e6eba0263b0b9f834c2067f URL: https://github.com/llvm/llvm-project/commit/62fec3d23d2325869e6eba0263b0b9f834c2067f DIFF: https://github.com/llvm/llvm-project/commit/62fec3d23d2325869e6eba0263b0b9f834c2067f.diff LO

[clang] [clang][TableGen] Migrate clang-tblgen to use const RecordKeeper (PR #107533)

2024-09-06 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 30a9cace807d4b5c98f2d0e2bd5bdea49061c8b8 f6fccde5fde7782b62506863827095d82494cc83 --e

[clang] [clang][ASTImporter] New fix for default template parameter values. (PR #101836)

2024-09-06 Thread LLVM Continuous Integration via cfe-commits
=?utf-8?q?Balázs_Kéri?= , =?utf-8?q?Balázs_Kéri?= Message-ID: In-Reply-To: llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `ppc64le-lld-multistage-test` running on `ppc64le-lld-multistage-test` while building `clang` at step 12 "build-stage2-unified-tree". Full details ar

[clang] [clang-tools-extra] [llvm] [clang-format] Add support for BasedOnStyle referencing an arbitrary file (PR #107312)

2024-09-06 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 776495987272294de6aafbe73dab3e9ab445227a 163657095741b2292540fce7ff424cb4600391da --e

[clang] [llvm] [AMDGPU] Add target intrinsic for s_buffer_prefetch_data (PR #107293)

2024-09-06 Thread Matt Arsenault via cfe-commits
@@ -9934,6 +9934,12 @@ SDValue SITargetLowering::LowerINTRINSIC_VOID(SDValue Op, auto NewMI = DAG.getMachineNode(Opc, DL, Op->getVTList(), Ops); return SDValue(NewMI, 0); } + case Intrinsic::amdgcn_s_prefetch_data: { +// For non-global address space preserve the

[clang] [llvm] [AMDGPU] Add target intrinsic for s_buffer_prefetch_data (PR #107293)

2024-09-06 Thread Stanislav Mekhanoshin via cfe-commits
@@ -9934,6 +9934,12 @@ SDValue SITargetLowering::LowerINTRINSIC_VOID(SDValue Op, auto NewMI = DAG.getMachineNode(Opc, DL, Op->getVTList(), Ops); return SDValue(NewMI, 0); } + case Intrinsic::amdgcn_s_prefetch_data: { +// For non-global address space preserve the

[clang] [analyzer] Model constructor initializer for an array member (PR #107537)

2024-09-06 Thread Arseniy Zaostrovnykh via cfe-commits
https://github.com/necto created https://github.com/llvm/llvm-project/pull/107537 Bind the array member to the compound region associated with the initializer list, e.g.: class C { int arr[2]; C() : arr{1, 2} {} }; C c; This change enables correct values in `c.arr[0]`

[clang] [analyzer] Model constructor initializer for an array member (PR #107537)

2024-09-06 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: Arseniy Zaostrovnykh (necto) Changes Bind the array member to the compound region associated with the initializer list, e.g.: class C { int arr[2]; C() : arr{1, 2} {} }; C c; This change enables

[clang] [AArch64] Implement FP8 floating-point mode helper intrinsics (PR #100608)

2024-09-06 Thread Momchil Velikov via cfe-commits
@@ -2582,6 +2582,60 @@ void NeonEmitter::runVectorTypes(raw_ostream &OS) { OS << "typedef double float64_t;\n"; OS << "#endif\n\n"; + OS << R"( +typedef uint64_t fpm_t; + +enum __ARM_FPM_FORMAT { __ARM_FPM_E5M2, __ARM_FPM_E4M3 }; + +enum __ARM_FPM_OVERFLOW { __ARM_FPM_INF

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread via cfe-commits
https://github.com/CarolineConcatto approved this pull request. Thank you Spencer for the patch. I left some nits, but you can fix it before you merge the patch. https://github.com/llvm/llvm-project/pull/100278 ___ cfe-commits mailing list cfe-commits

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread via cfe-commits
https://github.com/CarolineConcatto edited https://github.com/llvm/llvm-project/pull/100278 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread via cfe-commits
@@ -401,27 +402,57 @@ def VQRSHL : SInst<"vqrshl", "..S", "csilUcUsUiUlQcQsQiQlQUcQUsQUiQUl">; // E.3.12 Shifts by constant let isShift = 1 in { -def VSHR_N : SInst<"vshr_n", "..I", "csilUcUs

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread via cfe-commits
@@ -404,142 +370,174 @@ enum ArmSMEState : unsigned { ArmZT0Mask = 0b11 << 2 }; -bool SemaARM::ParseSVEImmChecks( -CallExpr *TheCall, SmallVector, 3> &ImmChecks) { - // Perform all the immediate checks for this builtin call. +bool SemaARM::CheckImmediateArg(CallExpr *Th

[clang] [llvm] [SPIRV][RFC] Rework / extend support for memory scopes (PR #106429)

2024-09-06 Thread Vyacheslav Levytskyy via cfe-commits
VyacheslavLevytskyy wrote: Thank you for the PR! I'd like to better understand motivation and justification of SPIR-V BE-related changes though. The goal would be to understand whether AllSvmDevices is indeed a better choice (for whom?) than Device as a default mem scope value in SPIR-V BE.

[clang] [AArch64] Implement FP8 floating-point mode helper intrinsics (PR #100608)

2024-09-06 Thread Momchil Velikov via cfe-commits
@@ -0,0 +1,165 @@ +// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --version 5 + +// RUN: %clang_cc1 -O2 -triple aarch64 -emit-llvm -x c -DUSE_NEON_H %s -o - | FileCheck %s +// RUN: %clang_cc1 -O2 -triple aarch64 -emit-llvm -x c -DUSE

[clang] [Modules] Add -cc1 -flate-module-map-file to load module maps after PCMs (PR #88893)

2024-09-06 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 commented: (I just missed it initially.) I took a quick look and the change looks at least not bad to me. But I didn't have experience with clang modules and I don't have an idea for the concerns you list. I don't mind accepting this if you want to land this. I f

[clang] [Modules] Add -cc1 -flate-module-map-file to load module maps after PCMs (PR #88893)

2024-09-06 Thread Ilya Biryukov via cfe-commits
ilya-biryukov wrote: @ChuanqiXu9 thanks for taking a look! Makes sense to give others a chance to chime in, I will wait for more comments. https://github.com/llvm/llvm-project/pull/88893 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://

[clang] tune the default stack protector level as SSPOn on Windows platform (PR #107043)

2024-09-06 Thread via cfe-commits
https://github.com/wenqinI closed https://github.com/llvm/llvm-project/pull/107043 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-09-06 Thread Mikael Holmén via cfe-commits
mikaelholmen wrote: We're seeing a crash with this patch when compiling with -Weverything. ``` clang: ../../clang/include/clang/AST/Expr.h:3026: const clang::Expr *clang::CallExpr::getArg(unsigned int) const: Assertion `Arg < getNumArgs() && "Arg access out of range!"' failed. ``` I'm working o

[clang] [CLANG][AArch64] Add the modal 8 bit floating-point scalar type (PR #97277)

2024-09-06 Thread via cfe-commits
https://github.com/CarolineConcatto edited https://github.com/llvm/llvm-project/pull/97277 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [flang][Driver] Support --no-warnings option (PR #107455)

2024-09-06 Thread Tom Eccles via cfe-commits
https://github.com/tblah approved this pull request. Thanks! https://github.com/llvm/llvm-project/pull/107455 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][C23] Support N3029 Improved Normal Enumerations (PR #103917)

2024-09-06 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/103917 >From eee57bcc211a8a045c0102ebb2f4410d52d657f6 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Wed, 14 Aug 2024 05:56:18 -0700 Subject: [PATCH 1/5] [clang][C23] Support N3029 Improved Normal Enum

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-09-06 Thread Mikael Holmén via cfe-commits
mikaelholmen wrote: > We're seeing a crash with this patch when compiling with -Weverything. > > ``` > clang: ../../clang/include/clang/AST/Expr.h:3026: const clang::Expr > *clang::CallExpr::getArg(unsigned int) const: Assertion `Arg < getNumArgs() > && "Arg access out of range!"' failed. > ``

[clang] [clang][C23] Support N3029 Improved Normal Enumerations (PR #103917)

2024-09-06 Thread Mariya Podchishchaeva via cfe-commits
@@ -1039,7 +1039,8 @@ def err_opencl_invalid_param : Error< "declaring function parameter of type %0 is not allowed%select{; did you forget * ?|}1">; def err_opencl_invalid_return : Error< "declaring function return value of type %0 is not allowed %select{; did you forget

[clang] [clang][C23] Support N3029 Improved Normal Enumerations (PR #103917)

2024-09-06 Thread Mariya Podchishchaeva via cfe-commits
@@ -6194,9 +6195,12 @@ def err_misplaced_ivar : Error< def warn_ivars_in_interface : Warning< "declaration of instance variables in the interface is deprecated">, InGroup>, DefaultIgnore; -def ext_enum_value_not_int : Extension< - "ISO C restricts enumerator values to rang

[clang] [clang][C23] Support N3029 Improved Normal Enumerations (PR #103917)

2024-09-06 Thread Mariya Podchishchaeva via cfe-commits
@@ -0,0 +1,59 @@ +// RUN: %clang_cc1 -verify -triple x86_64-unknown-linux-gnu -fsyntax-only --embed-dir=%S/Inputs -std=c23 %s -pedantic -Wpre-c23-compat Fznamznon wrote: Done. https://github.com/llvm/llvm-project/pull/103917

[clang] [clang][C23] Support N3029 Improved Normal Enumerations (PR #103917)

2024-09-06 Thread Mariya Podchishchaeva via cfe-commits
@@ -1,23 +1,23 @@ -// RUN: %clang_cc1 -triple %itanium_abi_triple %s -fsyntax-only -verify -pedantic +// RUN: %clang_cc1 -triple %itanium_abi_triple %s -fsyntax-only -verify=expected,c99 -pedantic Fznamznon wrote: Hmm, I think removing the prefix is more accura

[clang] [clang][C23] Support N3029 Improved Normal Enumerations (PR #103917)

2024-09-06 Thread Mariya Podchishchaeva via cfe-commits
@@ -169,13 +169,19 @@ enum class GH42372_2 { One }; +enum IncOverflow { + V2 = __INT_MAX__, + V3 // c99-warning {{incremented enumerator value that is exceeding range of 'int' is a C23 extension}} +#if __STDC_VERSION__ >= 202311L Fznamznon wrote: I misse

[clang] [clang-repl] Implement continuation for preprocessor directives. (PR #107552)

2024-09-06 Thread Vassil Vassilev via cfe-commits
https://github.com/vgvassilev created https://github.com/llvm/llvm-project/pull/107552 None >From 1947d04f969c53b75103cabf02a1f2c851d082e1 Mon Sep 17 00:00:00 2001 From: Vassil Vassilev Date: Fri, 6 Sep 2024 09:05:15 + Subject: [PATCH] [clang-repl] Implement continuation for preprocessor

[clang] [clang-repl] Implement continuation for preprocessor directives. (PR #107552)

2024-09-06 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vassil Vassilev (vgvassilev) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/107552.diff 2 Files Affected: - (modified) clang/test/Interpreter/multiline.cpp (+6-5) - (modified) clang/tools/clang-repl/ClangRepl.cpp (+3

[clang] [flang] [flang][Driver] Support -Xlinker in flang (PR #107472)

2024-09-06 Thread Tom Eccles via cfe-commits
https://github.com/tblah approved this pull request. https://github.com/llvm/llvm-project/pull/107472 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [flang][Driver] Support -Xlinker in flang (PR #107472)

2024-09-06 Thread Tom Eccles via cfe-commits
@@ -0,0 +1,6 @@ +! RUN: %flang -### -o /dev/null %s -Xlinker -rpath=/not/a/real/path 2>&1 | FileCheck %s + +! CHECK: "-fc1" +! CHECK-NEXT: "-rpath=/not/a/real/path" tblah wrote: nit: maybe I'm being overly pedantic here, but I think the meaning of the test woul

[clang] [llvm] [X86][AVX10.2] Support AVX10.2-SATCVT-DS new instructions. (PR #102592)

2024-09-06 Thread Malay Sanghi via cfe-commits
@@ -0,0 +1,443 @@ +/*===--- avx10_2satcvtdsintrin.h - AVX512SATCVTDS intrinsics === + * + * 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: Ap

[clang] [RFC][C++20][Modules] Fix crash when function and lambda inside loaded from different modules (PR #104512)

2024-09-06 Thread Dmitry Polukhin via cfe-commits
Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=,Kyungwoo Lee ,Dmitry Polukhin Message-ID: In-Reply-To: https://github.com/dmpolukhin ready_for_review https://github.com/llvm/llvm-project/pull/104512 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[clang] [clang] Emit -Wdangling diagnoses for cases where a gsl-pointer is construct from a gsl-owner object in a container. (PR #104556)

2024-09-06 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/104556 >From aba7fdb8ad0fda5486abd896a5029b661e4982bb Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Mon, 19 Aug 2024 13:46:16 +0200 Subject: [PATCH] [clang] Diagnose dangling issues for cases where a gsl-pointer is c

[clang] [RFC][C++20][Modules] Fix crash when function and lambda inside loaded from different modules (PR #104512)

2024-09-06 Thread Dmitry Polukhin via cfe-commits
Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=,Kyungwoo Lee ,Dmitry Polukhin Message-ID: In-Reply-To: dmpolukhin wrote: @ChuanqiXu9 please take a look, I had to load lambdas delayed to avoid bad cycles when current function was not fully deserialized yet but lambda inside reference it. Now t

[clang] [llvm] [CodeView] Flatten cmd args in frontend for LF_BUILDINFO (PR #106369)

2024-09-06 Thread via cfe-commits
nebulark wrote: I always set Argv0 and Commandline, even if they are just an empty string. Some tools had issues if those were not set. We already did use the empty string for BuildInfoRecord::TypeServerPDB, so now its also more consistent. So the offset changed from 0x (null) to the empty str

[clang] [AArch64] Implement FP8 floating-point mode helper intrinsics (PR #100608)

2024-09-06 Thread via cfe-commits
@@ -2582,6 +2582,60 @@ void NeonEmitter::runVectorTypes(raw_ostream &OS) { OS << "typedef double float64_t;\n"; OS << "#endif\n\n"; + OS << R"( +typedef uint64_t fpm_t; + +enum __ARM_FPM_FORMAT { __ARM_FPM_E5M2, __ARM_FPM_E4M3 }; + +enum __ARM_FPM_OVERFLOW { __ARM_FPM_INF

[clang] [clang] Emit -Wdangling diagnoses for cases where a gsl-pointer is construct from a gsl-owner object in a container. (PR #104556)

2024-09-06 Thread Haojian Wu via cfe-commits
https://github.com/hokein edited https://github.com/llvm/llvm-project/pull/104556 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] a918fa1 - [clang] Emit -Wdangling diagnoses for cases where a gsl-pointer is construct from a gsl-owner object in a container. (#104556)

2024-09-06 Thread via cfe-commits
Author: Haojian Wu Date: 2024-09-06T12:37:21+02:00 New Revision: a918fa117acfbb20d29039cb8bddab159a8173dc URL: https://github.com/llvm/llvm-project/commit/a918fa117acfbb20d29039cb8bddab159a8173dc DIFF: https://github.com/llvm/llvm-project/commit/a918fa117acfbb20d29039cb8bddab159a8173dc.diff LO

[clang] [clang] Emit -Wdangling diagnoses for cases where a gsl-pointer is construct from a gsl-owner object in a container. (PR #104556)

2024-09-06 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/104556 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AArch64] Implement FP8 floating-point mode helper intrinsics (PR #100608)

2024-09-06 Thread via cfe-commits
https://github.com/SpencerAbson approved this pull request. Cheers, it LGTM. https://github.com/llvm/llvm-project/pull/100608 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Don't assert non-empty packs for FunctionParmPackExprs (PR #107561)

2024-09-06 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 created https://github.com/llvm/llvm-project/pull/107561 `FunctionParmPackExpr`s are peculiar in that they have to be of unexpanded dependency while they don't introduce any unexpanded packs. So this patch rules them out in the non-empty pack assertion in `DiagnoseUn

[clang] [Clang] Don't assert non-empty packs for FunctionParmPackExprs (PR #107561)

2024-09-06 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Younan Zhang (zyn0217) Changes `FunctionParmPackExpr`s are peculiar in that they have to be of unexpanded dependency while they don't introduce any unexpanded packs. So this patch rules them out in the non-empty pack assertion in `Diagnos

[clang] [clang][Sema] Ignore the parentheses in the guard of DiagnoseUnexpandedParameterPack (PR #86401)

2024-09-06 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 closed https://github.com/llvm/llvm-project/pull/86401 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Fix reinterpret casts of two non-primitive types (PR #107564)

2024-09-06 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/107564 We don't want to allow e.g. cast from a record to an array or the other way arround. >From dda02f67ba68beba4564bae52374849724fd19ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Thu, 5 Se

[clang] [clang][bytecode] Fix reinterpret casts of two non-primitive types (PR #107564)

2024-09-06 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes We don't want to allow e.g. cast from a record to an array or the other way arround. --- Full diff: https://github.com/llvm/llvm-project/pull/107564.diff 1 Files Affected: - (modified) clang/lib/AST/ByteC

[clang] [clang][bytecode] Fix two-pointer-style std::initializer_lists (PR #107565)

2024-09-06 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/107565 The first pointer needs to point to the first element of the underlying array. This requires some changes to how we handle array expansion >From 8968151c4773910e6f85d9273899432556376300 Mon Sep 17 00:00:00 200

[clang] [clang][bytecode] Fix two-pointer-style std::initializer_lists (PR #107565)

2024-09-06 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes The first pointer needs to point to the first element of the underlying array. This requires some changes to how we handle array expansion --- Full diff: https://github.com/llvm/llvm-project/pull/107565.diff

[clang-tools-extra] cdd2c06 - [clang-tidy] fix misc-unconventional-assign-operator false positive for deducing this (#107409)

2024-09-06 Thread via cfe-commits
Author: Congcong Cai Date: 2024-09-06T19:11:26+08:00 New Revision: cdd2c0693b6dd75816f64960a479aacbe4e34549 URL: https://github.com/llvm/llvm-project/commit/cdd2c0693b6dd75816f64960a479aacbe4e34549 DIFF: https://github.com/llvm/llvm-project/commit/cdd2c0693b6dd75816f64960a479aacbe4e34549.diff

[clang-tools-extra] [clang-tidy] fix misc-unconventional-assign-operator false positive for deducing this (PR #107409)

2024-09-06 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 closed https://github.com/llvm/llvm-project/pull/107409 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Implement comparsion operators for vector type (PR #107258)

2024-09-06 Thread via cfe-commits
https://github.com/yronglin updated https://github.com/llvm/llvm-project/pull/107258 >From ae9fd2653ef3f5d6323c8c8e857fbf45f394f0ce Mon Sep 17 00:00:00 2001 From: yronglin Date: Wed, 4 Sep 2024 23:31:16 +0800 Subject: [PATCH 1/4] [clang][bytecode] Implement comparsion operators for vector type

[clang] [clang][bytecode] Implement comparsion operators for vector type (PR #107258)

2024-09-06 Thread via cfe-commits
@@ -1222,6 +1224,105 @@ bool Compiler::VisitComplexBinOp(const BinaryOperator *E) { return true; } +template +bool Compiler::VisitVectorBinOp(const BinaryOperator *E) { + assert(E->getType()->isVectorType()); + assert(E->getLHS()->getType()->isVectorType()); + assert(E-

[clang] [clang][bytecode] Implement comparsion operators for vector type (PR #107258)

2024-09-06 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr approved this pull request. https://github.com/llvm/llvm-project/pull/107258 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Fix a bug in annotating CastRParen (PR #102261)

2024-09-06 Thread kadir çetinkaya via cfe-commits
kadircet wrote: there still seems to be a regression when the operator is `-`, filed https://github.com/llvm/llvm-project/issues/107568 https://github.com/llvm/llvm-project/pull/102261 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://li

[clang] [clang][bytecode] Allow continuing when discarded MemberExpr Base fails (PR #107231)

2024-09-06 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr updated https://github.com/llvm/llvm-project/pull/107231 >From 6bfbb1b280490a18d817d9ef0be0491925a0a9ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Wed, 4 Sep 2024 14:32:32 +0200 Subject: [PATCH] [clang][bytecode] Allow continuing when discarde

[clang] [clang][bytecode] Allow continuing when discarded MemberExpr Base fails (PR #107231)

2024-09-06 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr updated https://github.com/llvm/llvm-project/pull/107231 >From 44b14f24196f4ff407dfa020f441690b1203f847 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Wed, 4 Sep 2024 14:32:32 +0200 Subject: [PATCH] [clang][bytecode] Allow continuing when discarde

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-09-06 Thread Mikael Holmén via cfe-commits
mikaelholmen wrote: Btw a question about the new warning: So with -Wunsafe-buffer-usage-in-libc-call clang now warns on the following? ``` #include void foo(void) { char q[10]; snprintf(q, 10, "%s", "hello"); } ``` It says ``` foo.c:5:3: warning: function 'snprintf' is unsafe [-Wunsafe-bu

[clang] [clang] Diagnose dangling issues for the "Container" case. (PR #107213)

2024-09-06 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/107213 >From f6a9125f69ffe5231c21ad856e04cc1ff5127de5 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Wed, 28 Aug 2024 09:59:41 +0200 Subject: [PATCH] [clang] Diagnose dangling issues for "Container" case. We teach th

[clang] [clang][ExprConst] Allow comparisons with string literals (PR #106733)

2024-09-06 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr updated https://github.com/llvm/llvm-project/pull/106733 >From 73af678c4c405cff16d5baf668e78e736bb1d228 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Fri, 30 Aug 2024 15:52:48 +0200 Subject: [PATCH] [clang][ExprConst] Allow comparisons with strin

[clang] [RISCV] Allow YAML file to control multilib selection (PR #98856)

2024-09-06 Thread Sam Elliott via cfe-commits
lenary wrote: @ArcaneNibble have you seen this RFC from Arm https://discourse.llvm.org/t/rfc-multilib-custom-flags/81058?u=lenary which I think would be useful for RISC-V too? https://github.com/llvm/llvm-project/pull/98856 ___ cfe-commits mailing li

[clang] [clang][bytecode] Implement comparsion operators for vector type (PR #107258)

2024-09-06 Thread via cfe-commits
yronglin wrote: Thanks for the review, wait for CI green before land. https://github.com/llvm/llvm-project/pull/107258 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Emit -Wdangling diagnoses for cases where a gsl-pointer is construct from a gsl-owner object in a container. (PR #104556)

2024-09-06 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux-qemu` running on `sanitizer-buildbot4` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/139/builds/3380 Here is the relevant piece o

[clang] [clang] Diagnose dangling issues for the "Container" case. (PR #107213)

2024-09-06 Thread Haojian Wu via cfe-commits
@@ -278,6 +278,8 @@ Improvements to Clang's diagnostics - The lifetimebound and GSL analysis in clang are coherent, allowing clang to detect more use-after-free bugs. (#GH100549). +- Clang now diagnoses cases where a dangling `GSLOwner`` object is constructed, e.g. `std::ve

[clang] [clang] Diagnose dangling issues for the "Container" case. (PR #107213)

2024-09-06 Thread Haojian Wu via cfe-commits
@@ -525,3 +544,31 @@ void test() { std::string_view svjkk1 = ReturnStringView(StrCat("bar", "x")); // expected-warning {{object backing the pointer will be destroyed at the end of the full-expression}} } } // namespace GH100549 + +namespace GH100526 { hokei

[clang] [clang] Diagnose dangling issues for the "Container" case. (PR #107213)

2024-09-06 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/107213 >From f6a9125f69ffe5231c21ad856e04cc1ff5127de5 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Wed, 28 Aug 2024 09:59:41 +0200 Subject: [PATCH 1/2] [clang] Diagnose dangling issues for "Container" case. We teac

[clang] [clang] Diagnose dangling issues for the "Container" case. (PR #107213)

2024-09-06 Thread Haojian Wu via cfe-commits
@@ -525,3 +544,31 @@ void test() { std::string_view svjkk1 = ReturnStringView(StrCat("bar", "x")); // expected-warning {{object backing the pointer will be destroyed at the end of the full-expression}} } } // namespace GH100549 + +namespace GH100526 { +void test() { + std:

[clang] [clang] Diagnose dangling issues for the "Container" case. (PR #107213)

2024-09-06 Thread Haojian Wu via cfe-commits
@@ -525,3 +544,31 @@ void test() { std::string_view svjkk1 = ReturnStringView(StrCat("bar", "x")); // expected-warning {{object backing the pointer will be destroyed at the end of the full-expression}} } } // namespace GH100549 + +namespace GH100526 { +void test() { + std:

[clang] [clang] Diagnose dangling issues for the "Container" case. (PR #107213)

2024-09-06 Thread Haojian Wu via cfe-commits
@@ -6690,6 +6690,20 @@ When the Owner's lifetime ends, it will consider the Pointer to be dangling. P.getInt(); // P is dangling } +If a template class is annotated with [[gsl::Owner]], and the first instantiated +template argument is a [[gsl::Pointer]] type, the analy

[clang] [clang] Diagnose dangling issues for the "Container" case. (PR #107213)

2024-09-06 Thread Haojian Wu via cfe-commits
@@ -6690,6 +6690,20 @@ When the Owner's lifetime ends, it will consider the Pointer to be dangling. P.getInt(); // P is dangling } +If a template class is annotated with [[gsl::Owner]], and the first instantiated +template argument is a [[gsl::Pointer]] type, the analy

[clang] [clang] Diagnose dangling issues for the "Container" case. (PR #107213)

2024-09-06 Thread Haojian Wu via cfe-commits
hokein wrote: I have fixed the false positives, and added testcases for them. (I have tested this patch on our internal codebase, no new false positives being found). https://github.com/llvm/llvm-project/pull/107213 ___ cfe-commits mailing list cfe-co

[clang] [llvm] [AMDGPU] Convert AMDGPUResourceUsageAnalysis pass from Module to MF pass (PR #102913)

2024-09-06 Thread Janek van Oirschot via cfe-commits
JanekvO wrote: Ping https://github.com/llvm/llvm-project/pull/102913 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ExprConst] Allow comparisons with string literals (PR #106733)

2024-09-06 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr updated https://github.com/llvm/llvm-project/pull/106733 >From 7dbb01805663a6671c61330c5abc04c44146cc24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Fri, 30 Aug 2024 15:52:48 +0200 Subject: [PATCH] [clang][ExprConst] Allow comparisons with strin

[clang] [HIP][Clang][CodeGen] Handle hip bin symbols properly. (PR #107458)

2024-09-06 Thread via cfe-commits
https://github.com/jofrn updated https://github.com/llvm/llvm-project/pull/107458 >From 42034653eda53dd70d443e306182aaf04954cda2 Mon Sep 17 00:00:00 2001 From: jofernau Date: Thu, 5 Sep 2024 23:31:55 -0400 Subject: [PATCH] [HIP][Clang][CodeGen] Handle hip bin symbols properly. Remove '_' in fa

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread via cfe-commits
https://github.com/SpencerAbson edited https://github.com/llvm/llvm-project/pull/100278 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread via cfe-commits
https://github.com/SpencerAbson closed https://github.com/llvm/llvm-project/pull/100278 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] fix crash on binding to symbolic region with `void *` type (PR #107572)

2024-09-06 Thread Pavel Skripkin via cfe-commits
https://github.com/pskrgag created https://github.com/llvm/llvm-project/pull/107572 As reported in https://github.com/llvm/llvm-project/pull/103714#issuecomment-2295769193. CSA crashes on trying to bind value to symbolic region with `void *`. This happens when such region gets passed as inlin

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-ppc64le-linux` running on `ppc64le-sanitizer` while building `clang,llvm` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/72/builds/3014 Here is the relevant piece of t

[clang] [analyzer] fix crash on binding to symbolic region with `void *` type (PR #107572)

2024-09-06 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-clang-static-analyzer-1 Author: Pavel Skripkin (pskrgag) Changes As reported in https://github.com/llvm/llvm-project/pull/103714#issuecomment-2295769193. CSA crashes on trying to bind value to symbolic region with `void *`. T

[clang] [clang] Add deprecation warning for `-Ofast` driver option (PR #98736)

2024-09-06 Thread Nico Weber via cfe-commits
nico wrote: > Somehow `clang.exe -Ofast -O2 -### -Werror > C:\src\llvm-project\clang\test\Driver\Ofast.c 2>&1` is not producing any > output for you, despite `-###` being present. I'm not sure why, but all > windows buildbots seem to be happy with this patch. Can you investigate > further? F

[clang] [clang] Add deprecation warning for `-Ofast` driver option (PR #98736)

2024-09-06 Thread Nico Weber via cfe-commits
nico wrote: …passing `Wno-msvc-not-found` as suggested above would also make the test go. But `-c` seems generally nicer here anyways? https://github.com/llvm/llvm-project/pull/98736 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://list

[clang] [clang-format] Fix a regression on BAS_AlwaysBreak (PR #107506)

2024-09-06 Thread kadir çetinkaya via cfe-commits
@@ -861,7 +861,7 @@ void ContinuationIndenter::addTokenOnCurrentLine(LineState &State, bool DryRun, // or // cal( // new SomethingElseee()); - !IsSimpleFunction(Current)) { + Current.isNot(

[clang] [clang-format] Fix a regression on BAS_AlwaysBreak (PR #107506)

2024-09-06 Thread kadir çetinkaya via cfe-commits
https://github.com/kadircet requested changes to this pull request. https://github.com/llvm/llvm-project/pull/107506 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-aarch64-linux` running on `sanitizer-buildbot8` while building `clang,llvm` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/51/builds/3442 Here is the relevant piece o

[clang] 67f9183 - [clang][bytecode] Implement comparsion operators for vector type (#107258)

2024-09-06 Thread via cfe-commits
Author: yronglin Date: 2024-09-06T20:27:11+08:00 New Revision: 67f9183c113a340c58bdb9d5d3bfb850b8db4e90 URL: https://github.com/llvm/llvm-project/commit/67f9183c113a340c58bdb9d5d3bfb850b8db4e90 DIFF: https://github.com/llvm/llvm-project/commit/67f9183c113a340c58bdb9d5d3bfb850b8db4e90.diff LOG:

[clang] [clang][bytecode] Implement comparsion operators for vector type (PR #107258)

2024-09-06 Thread via cfe-commits
https://github.com/yronglin closed https://github.com/llvm/llvm-project/pull/107258 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 5cf3677 - [clang] Pass -c to clang in test/Driver/Ofast.c

2024-09-06 Thread Nico Weber via cfe-commits
Author: Nico Weber Date: 2024-09-06T08:27:41-04:00 New Revision: 5cf3677a7bcdf5a9e603c054bd40c1282db984a9 URL: https://github.com/llvm/llvm-project/commit/5cf3677a7bcdf5a9e603c054bd40c1282db984a9 DIFF: https://github.com/llvm/llvm-project/commit/5cf3677a7bcdf5a9e603c054bd40c1282db984a9.diff LO

[clang] [clang] Add deprecation warning for `-Ofast` driver option (PR #98736)

2024-09-06 Thread Nico Weber via cfe-commits
nico wrote: I made that change in 5cf3677a7bcdf5a9e603c054bd40c1282db984a9. https://github.com/llvm/llvm-project/pull/98736 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux-android` running on `sanitizer-buildbot-android` while building `clang,llvm` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/186/builds/2071 Here is the r

[clang] [llvm] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-09-06 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `ppc64le-lld-multistage-test` running on `ppc64le-lld-multistage-test` while building `clang,llvm` at step 12 "build-stage2-unified-tree". Full details are available at: https://lab.llvm.org/buildbot/#/builders/168/builds/3003

[clang] [clang-format] Fix a regression on BAS_AlwaysBreak (PR #107506)

2024-09-06 Thread kadir çetinkaya via cfe-commits
kadircet wrote: i've also found 3 more cases that point back to same patch in https://github.com/llvm/llvm-project/issues/107574, in case you want to address all of them with this change https://github.com/llvm/llvm-project/pull/107506 ___ cfe-commit

  1   2   3   4   5   6   >