[PATCH] D100823: [RISCV] Implement the pseudo compare builtin.

2021-04-20 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. I just posted https://reviews.llvm.org/D100889 which should allow the frontend to treat all comparisons the same way. It also avoids using the long expansion for vmsge.vx Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D

[PATCH] D100626: [analyzer][NFC] Remove duplicated work from retain count leak report

2021-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. Great, thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100626/new/ https://reviews.llvm.org/D100626 ___

[PATCH] D99260: [analyzer] Fix false positives in inner pointer checker (PR49628)

2021-04-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In https://bugs.llvm.org/show_bug.cgi?id=45786 the godbolt link shows that there are still problems with `addressof` (yes, their "trunk" clang is fresh enough). They seem to have `__addressof` instead of `addressof` so maybe we should cover that case real quick. Or maybe ou

[PATCH] D100611: [RISCV] Add new attribute __clang_riscv_builtin_alias for intrinsics.

2021-04-20 Thread Hsiangkai Wang via Phabricator via cfe-commits
HsiangKai added inline comments. Comment at: clang/include/clang/Basic/AttrDocs.td:2147-2150 +This attribute can only be used to set up the aliases for certain RISC-V +C intrinsic functions; it is intended for use only inside ``riscv_*.h`` +and is not a general mechanism for decl

[PATCH] D100830: [RISCV] [1/2] Add IR intrinsic for Zbp extension

2021-04-20 Thread LevyHsu via Phabricator via cfe-commits
LevyHsu updated this revision to Diff 339105. LevyHsu marked 6 inline comments as done. LevyHsu added a comment. 1. clang/test/CodeGen/RISCV/rvb-intrinsics/riscv32-zbp.c clang/test/CodeGen/RISCV/rvb-intrinsics/riscv64-zbp.c llvm/test/MC/RISCV/rv32b-aliases-valid.s llvm/test/MC/RISCV/rv64b-alias

[PATCH] D99949: [AMDGPU][OpenMP] Add amdgpu-arch tool to list AMD GPUs installed

2021-04-20 Thread Pushpinder Singh via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG3194761d2763: [AMDGPU][OpenMP] Add amdgpu-arch tool to list AMD GPUs installed (authored by pdhaliwal). Repository: rG LLVM Github Monorepo CHANG

[clang] 3194761 - [AMDGPU][OpenMP] Add amdgpu-arch tool to list AMD GPUs installed

2021-04-20 Thread Pushpinder Singh via cfe-commits
Author: Pushpinder Singh Date: 2021-04-21T05:05:49Z New Revision: 3194761d2763a471dc6426a3e77c1445cb9ded3b URL: https://github.com/llvm/llvm-project/commit/3194761d2763a471dc6426a3e77c1445cb9ded3b DIFF: https://github.com/llvm/llvm-project/commit/3194761d2763a471dc6426a3e77c1445cb9ded3b.diff L

[PATCH] D77013: [AMDGPU] Add options -mamdgpu-ieee -mno-amdgpu-ieee

2021-04-20 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: clang/include/clang/Basic/DiagnosticDriverKinds.td:130-131 "invalid argument '%0' only allowed with '%1'">; +def err_drv_argument_only_allowed_with_or_equivalent : Error< + "invalid argument '%0' only allowed with '%1' or equivalent">

[PATCH] D77013: [AMDGPU] Add options -mamdgpu-ieee -mno-amdgpu-ieee

2021-04-20 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 339092. yaxunl marked 3 inline comments as done. yaxunl added a comment. revised by Matt's comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77013/new/ https://reviews.llvm.org/D77013 Files: clang/include/clang/Basic/CodeGenOptions.def clan

[PATCH] D100879: [Clang] Propagate guaranteed alignment for malloc and others

2021-04-20 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Please addd tests, including tests that we suppress this assumption under e.g. `-fno-builtin-malloc` CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100879/new/ https://reviews.llvm.org/D100879 ___ cfe-commits mailing

[PATCH] D45639: [Driver] Support default libc++ library location on Darwin

2021-04-20 Thread Jonas Devlieghere via Phabricator via cfe-commits
JDevlieghere added a comment. @phosek I've reverted this in 05eeed9691aeb3e0316712195b998e9078cdceb0 to turn the bot green again. Happy to help you look into this tomorrow. Repository: rG LLVM Github Monorepo CHANGES SINC

[clang] 05eeed9 - Revert "[Driver] Support default libc++ library location on Darwin"

2021-04-20 Thread Jonas Devlieghere via cfe-commits
Author: Jonas Devlieghere Date: 2021-04-20T20:42:50-07:00 New Revision: 05eeed9691aeb3e0316712195b998e9078cdceb0 URL: https://github.com/llvm/llvm-project/commit/05eeed9691aeb3e0316712195b998e9078cdceb0 DIFF: https://github.com/llvm/llvm-project/commit/05eeed9691aeb3e0316712195b998e9078cdceb0.d

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-20 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu added inline comments. Comment at: clang/docs/LanguageExtensions.rst:2689 - size_t __builtin_coro_size() + size_t __builtin_coro_size(bool alloc) void *__builtin_coro_frame() ychen wrote: > ChuanqiXu wrote: > > ychen wrote: > > > lxfind wrote: >

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-20 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added inline comments. Comment at: clang/docs/LanguageExtensions.rst:2689 - size_t __builtin_coro_size() + size_t __builtin_coro_size(bool alloc) void *__builtin_coro_frame() ChuanqiXu wrote: > ychen wrote: > > lxfind wrote: > > > Do we need to chan

[PATCH] D45639: [Driver] Support default libc++ library location on Darwin

2021-04-20 Thread Jonas Devlieghere via Phabricator via cfe-commits
JDevlieghere added a comment. This breaks `TestAppleSimulatorOSType.py ` on GreenDragon. First failed build: http://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/31346/ /Users/buildslave/jenkins/workspace/lldb-cmake/lldb-build/bin/clang main.o -g -O0 -fno-builtin -isysroot "/Application

[PATCH] D100919: [AArch64] Support customizing stack protector guard

2021-04-20 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers planned changes to this revision. nickdesaulniers added a comment. Pretty sure I need to do something with non-zero values of `-mstack-protector-guard-offset=0`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100919/new/ https://rev

[PATCH] D100794: [HIP] Support overloaded math functions for hipRTC

2021-04-20 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked an inline comment as done. yaxunl added inline comments. Comment at: clang/lib/Headers/__clang_hip_cmath.h:347 + static const bool value = !is_same::value; }; yaxunl wrote: > tra wrote: > > Nit: `}; // namespace __hip` > will do actually this is

[PATCH] D100794: [HIP] Support overloaded math functions for hipRTC

2021-04-20 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked an inline comment as done. yaxunl added inline comments. Comment at: clang/lib/Headers/__clang_hip_cmath.h:347 + static const bool value = !is_same::value; }; tra wrote: > Nit: `}; // namespace __hip` will do CHANGES SINCE LAST ACTION https:

[PATCH] D100830: [RISCV] [1/2] Add IR intrinsic for Zbp extension

2021-04-20 Thread LevyHsu via Phabricator via cfe-commits
LevyHsu updated this revision to Diff 339086. LevyHsu added a comment. Change Log: 1. llvm/lib/Target/RISCV/RISCVInstrInfoB.td - Aligned SDNode def for shflw/unshfl/unshflw - Reordered def : PatGprImm; - Merged Pat def when Predicates = [HasStdExtZbp] 2. llvm/test/CodeGen/RISCV/rv32zbp-int

[PATCH] D100368: [X86] Support some missing intrinsics

2021-04-20 Thread LiuChen via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG72e4bf12eec4: [X86] Support some missing intrinsics (authored by LiuChen3). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https

[clang] 72e4bf1 - [X86] Support some missing intrinsics

2021-04-20 Thread via cfe-commits
Author: Liu, Chen3 Date: 2021-04-21T10:50:37+08:00 New Revision: 72e4bf12eec4e1526187b4f9445bc66a168552dd URL: https://github.com/llvm/llvm-project/commit/72e4bf12eec4e1526187b4f9445bc66a168552dd DIFF: https://github.com/llvm/llvm-project/commit/72e4bf12eec4e1526187b4f9445bc66a168552dd.diff LO

[PATCH] D100919: [AArch64] Support customizing stack protector guard

2021-04-20 Thread Xiang Zhang via Phabricator via cfe-commits
xiangzhangllvm accepted this revision. xiangzhangllvm added a comment. This revision is now accepted and ready to land. I didn't find any problem in the main context of the patch, +1 first. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100919/new/

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-20 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu added a comment. There is something I am still confused about these two patch. Maybe I don't get the problem right. The example problem shows if user uses `alignas` to specify the alignment for promise_type, the actual alignment for the promise isn't correctly due to compiler didn't c

[PATCH] D100776: [clang/Basic] Make TargetInfo.h not use DataLayout again

2021-04-20 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. > This keeps the assert that checks that the llvm DataLayout and the user label > prefix are in sync. See the NDEBUG in Mangle.cpp here-ish: > https://reviews.llvm.org/D100776#change-NN4Lz7xH29fo (I measured that that > assert doesn't slow down `check-clang` in a release

[PATCH] D100776: [clang/Basic] Make TargetInfo.h not use DataLayout again

2021-04-20 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. > So, if this is really causing some consternation then we can pull back and > reinstate what we had, but it was a direction around solving a set of hard to > find bugs. > > Thoughts? This keeps the assert that checks that the llvm DataLayout and the user label prefix a

[PATCH] D100919: [AArch64] Support customizing stack protector guard

2021-04-20 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:3138 } +if (EffectiveTriple.isAArch64() && Value != "sp_el0") { + D.Diag(diag::err_drv_invalid_value_with_suggestion) TODO: can we re-use `AArch64SysReg::lookup

[PATCH] D100919: [AArch64] Support customizing stack protector guard

2021-04-20 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. I still have some todos that I will get to tomorrow, but posting this early for review. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100919/new/ https://reviews.llvm.org/D100919 __

[PATCH] D100919: [AArch64] Support customizing stack protector guard

2021-04-20 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers created this revision. nickdesaulniers added reviewers: xiangzhangllvm, efriedma, MaskRay. Herald added subscribers: dexonsmith, danielkiss, hiraditya, kristof.beyls. nickdesaulniers requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llv

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-20 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added inline comments. Comment at: clang/docs/LanguageExtensions.rst:2689 - size_t __builtin_coro_size() + size_t __builtin_coro_size(bool alloc) void *__builtin_coro_frame() lxfind wrote: > Do we need to change __builtin_coro_size? The argument wil

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-20 Thread Xun Li via Phabricator via cfe-commits
lxfind added inline comments. Comment at: clang/docs/LanguageExtensions.rst:2689 - size_t __builtin_coro_size() + size_t __builtin_coro_size(bool alloc) void *__builtin_coro_frame() Do we need to change __builtin_coro_size? The argument will always be 1,

[PATCH] D77013: [AMDGPU] Add options -mamdgpu-ieee -mno-amdgpu-ieee

2021-04-20 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added inline comments. Comment at: clang/include/clang/Basic/DiagnosticDriverKinds.td:130-131 "invalid argument '%0' only allowed with '%1'">; +def err_drv_argument_only_allowed_with_or_equivalent : Error< + "invalid argument '%0' only allowed with '%1' or equivalent">

[PATCH] D100276: [clang] p1099 using enum part 1

2021-04-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi Nathan, thanks for implementing this. Besides formatting nitpicks, few other comments/questions: - Update needed in cxx_status.html - Should we support this as an extension for earlier C++ versions? This is a very handy feature. In clang terms, `warn_cxx17_compat_cons

[PATCH] D100823: [RISCV] Implement the pseudo compare builtin.

2021-04-20 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. Thinking about this more, I'd like to consider doing this in the backend specifically for the compares for a few reasons. -vmsgt(u).vv intrinsic already selects vmslt(u).vv with swapped operands in the backend. This was needed for SEW=64 on RV32. -Inconsistent that

[PATCH] D100907: [lsan][docs] Clarify supported platforms

2021-04-20 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay marked an inline comment as done. MaskRay added subscribers: fjricci, delcypher. MaskRay added inline comments. Comment at: clang/docs/LeakSanitizer.rst:49 + +* Android aarch64/i386/x86_64 +* Linux arm/aarch64/mips64/ppc64/ppc64le/s390x/i386/x86\_64 vital

[PATCH] D100914: [clang] Revert "Re-fix _lrotl/_lrotr to always take Long, no matter the platform."

2021-04-20 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. arphaman added reviewers: erichkeane, Bigcheese. Herald added a subscriber: ributzka. arphaman requested review of this revision. Herald added a project: clang. This reverts commit 92146ce399cdb26c3a9aa4d68af8cacb7c1c0fef. The original commit is from 2019, but we w

[PATCH] D100907: [lsan][docs] Clarify supported platforms

2021-04-20 Thread Vitaly Buka via Phabricator via cfe-commits
vitalybuka accepted this revision. vitalybuka added inline comments. This revision is now accepted and ready to land. Comment at: clang/docs/LeakSanitizer.rst:49 + +* Android aarch64/i386/x86_64 +* Linux arm/aarch64/mips64/ppc64/ppc64le/s390x/i386/x86\_64 MaskRay

[PATCH] D85802: [clang] Add -fc++-abi= flag for specifying which C++ ABI to use

2021-04-20 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan reopened this revision. leonardchan added a comment. This revision is now accepted and ready to land. Herald added a subscriber: jansvoboda11. Re-opening this based on discussions in D93668 . The consensus is that this is OK as long as the compiler kn

[PATCH] D100834: Bug 49739 - [Matrix] Support #pragma clang fp

2021-04-20 Thread Hamza Mahfooz via Phabricator via cfe-commits
effective-light updated this revision to Diff 339048. effective-light added a comment. Use the correct clang command. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100834/new/ https://reviews.llvm.org/D100834 Files: clang/lib/CodeGen/CGExprScala

[PATCH] D100907: [lsan][docs] Clarify supported platforms

2021-04-20 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 339045. MaskRay added a comment. Fuchsia -> Fuchsia aarch64/x86_64 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100907/new/ https://reviews.llvm.org/D100907 Files: clang/docs/LeakSanitizer.rst Index: clan

[PATCH] D100907: [lsan][docs] Clarify supported platforms

2021-04-20 Thread Petr Hosek via Phabricator via cfe-commits
phosek added inline comments. Comment at: clang/docs/LeakSanitizer.rst:50 +* Android aarch64/i386/x86_64 +* Fuchsia +* Linux arm/aarch64/mips64/ppc64/ppc64le/riscv64/s390x/i386/x86\_64 You can clarify that Fuchsia supports aarch64 and x86_64. Repository: rG L

[PATCH] D100415: [Coroutines] Split coroutine during CoroEarly into an init and ramp function

2021-04-20 Thread Xun Li via Phabricator via cfe-commits
lxfind planned changes to this revision. lxfind added a comment. Plan to add documentation, fix Legacy pass and address comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100415/new/ https://reviews.llvm.org/D100415 __

[PATCH] D100907: [lsan][docs] Clarify supported platforms

2021-04-20 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 339039. MaskRay added a comment. Herald added subscribers: phosek, s.egerton, simoncook. Add Linux riscv64. Add Fuchsia Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100907/new/ https://reviews.llvm.org/D100907

[PATCH] D100794: [HIP] Support overloaded math functions for hipRTC

2021-04-20 Thread Artem Belevich via Phabricator via cfe-commits
tra accepted this revision. tra added a comment. This revision is now accepted and ready to land. LGTM. Comment at: clang/lib/Headers/__clang_hip_cmath.h:347 + static const bool value = !is_same::value; }; Nit: `}; // namespace __hip` CHANGES SINCE LAST A

[PATCH] D100907: [lsan][docs] Clarify supported platforms

2021-04-20 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/docs/LeakSanitizer.rst:49 + +* Android aarch64/i386/x86_64 +* Linux arm/aarch64/mips64/ppc64/ppc64le/s390x/i386/x86\_64 vitalybuka wrote: > Apple is incomplete and riscv is missing > > ``` > if(APPLE) > set(ALL_

[PATCH] D100000: [clang] WIP: Implement simpler alternative to two-phase lookup for NRVO

2021-04-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 339035. mizvekov added a comment. Herald added a subscriber: dexonsmith. Initial implementation, still WIP. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D10/new/ https://reviews.llvm.org/D10 Files:

[PATCH] D100907: [lsan][docs] Clarify supported platforms

2021-04-20 Thread Vitaly Buka via Phabricator via cfe-commits
vitalybuka added inline comments. Comment at: clang/docs/LeakSanitizer.rst:49 + +* Android aarch64/i386/x86_64 +* Linux arm/aarch64/mips64/ppc64/ppc64le/s390x/i386/x86\_64 Apple is incomplete and riscv is missing ``` if(APPLE) set(ALL_LSAN_SUPPORTED_ARCH ${X86

[PATCH] D100907: [lsan][docs] Clarify supported platforms

2021-04-20 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 339032. MaskRay added a comment. add i386/aarch64 to macOS Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100907/new/ https://reviews.llvm.org/D100907 Files: clang/docs/LeakSanitizer.rst Index: clang/docs/L

[PATCH] D100907: [lsan][docs] Clarify supported platforms

2021-04-20 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay created this revision. MaskRay added reviewers: Sanitizers, vitalybuka. MaskRay requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D100907 Files: clang/docs/LeakSanitiz

[PATCH] D100807: [clang][driver] Use the canonical Darwin arch name when printing out the triple for a Darwin target

2021-04-20 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. In D100807#2702675 , @ab wrote: > This sounds nice! One idea, maybe more dangerous, not sure which is better: > in `setTripleTypeForMachOArchName`, we already have a couple `setArchName` > calls, I think that's why `arm64e` i

[PATCH] D100807: [clang][driver] Use the canonical Darwin arch name when printing out the triple for a Darwin target

2021-04-20 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman updated this revision to Diff 339027. arphaman added a comment. Updated with Ahmed's suggestion. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100807/new/ https://reviews.llvm.org/D100807 Files: clang/lib/Driver/ToolChains/Darwin.cpp clang/test/Driver/aarch64-cpus.c clan

[PATCH] D100872: Use OpenFlags instead of boolean to set a file as text/binary

2021-04-20 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a subscriber: dexonsmith. rnk added a comment. +@dexonsmith who touched this API last. Comment at: clang/include/clang/Frontend/CompilerInstance.h:738-740 + createOutputFileImpl(StringRef OutputPath, llvm::sys::fs::OpenFlags Flags, bool Remove

[PATCH] D100776: [clang/Basic] Make TargetInfo.h not use DataLayout again

2021-04-20 Thread Eric Christopher via Phabricator via cfe-commits
echristo added a comment. In D100776#2699603 , @thakis wrote: > In D100776#2699565 , @rnk wrote: > >> Of the three people who commented on D17183 >> , you and I are on the only on

[PATCH] D100148: [Driver] Fix compiler-rt lookup for x32

2021-04-20 Thread John Paul Adrian Glaubitz via Phabricator via cfe-commits
glaubitz added a comment. @hvdijk I just noticed that the sanitizer defines `SANITIZER_X32` for x32, so I assume your patch itself is already correct. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100148/new/ https://reviews.llvm.org/D100148

[PATCH] D100509: Support GCC's -fstack-usage flag

2021-04-20 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:5474 + if (Args.hasArg(options::OPT_fstack_usage)) { +CmdArgs.push_back(Args.MakeArgString("-fstack-usage")); + CC1 needs two options? If you infer the filename in the driver,

[PATCH] D100896: [CMake][clang] add_clang_library's functions require default visibility

2021-04-20 Thread Jim Radford via Phabricator via cfe-commits
radford created this revision. radford added a reviewer: arphaman. Herald added a subscriber: mgorny. radford requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Compiling LLVM, as a cmake sub-project that compiles with visibility hidden, will

[PATCH] D100834: Bug 49739 - [Matrix] Support #pragma clang fp

2021-04-20 Thread Hamza Mahfooz via Phabricator via cfe-commits
effective-light updated this revision to Diff 339012. effective-light added a comment. Fix build Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100834/new/ https://reviews.llvm.org/D100834 Files: clang/lib/CodeGen/CGExprScalar.cpp clang/test/Co

[PATCH] D100794: [HIP] Support overloaded math functions for hipRTC

2021-04-20 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 339009. yaxunl marked an inline comment as done. yaxunl added a comment. fix __hip::__numeric_type CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100794/new/ https://reviews.llvm.org/D100794 Files: clang/lib/Headers/__clang_hip_cmath.h clang/lib/

[clang] 9f1e2ee - [Clang, builtins] Added aligned_alloc, memalign support

2021-04-20 Thread Dávid Bolvanský via cfe-commits
Author: Dávid Bolvanský Date: 2021-04-21T00:11:54+02:00 New Revision: 9f1e2ee46251b09565eb87124aa836291aaf799d URL: https://github.com/llvm/llvm-project/commit/9f1e2ee46251b09565eb87124aa836291aaf799d DIFF: https://github.com/llvm/llvm-project/commit/9f1e2ee46251b09565eb87124aa836291aaf799d.dif

[PATCH] D100891: CMake fixes to enable LLVM as a sub-project

2021-04-20 Thread Jim Radford via Phabricator via cfe-commits
radford created this revision. Herald added a subscriber: mgorny. radford requested review of this revision. Herald added projects: clang, LLDB, LLVM. Herald added subscribers: llvm-commits, lldb-commits, cfe-commits. [CMake][llvm] Using -D in COMPILE_DEFINITIONS can create a lone -D w/generator-

[PATCH] D100755: [llvm-rc] [3/4] Run clang to preprocess input files

2021-04-20 Thread Alexandre Ganea via Phabricator via cfe-commits
aganea accepted this revision. aganea added a comment. LGTM. Comment at: llvm/tools/llvm-rc/llvm-rc.cpp:94 + +ErrorOr findClang(const char *Argv0) { + StringRef Parent = llvm::sys::path::parent_path(Argv0); mstorsjo wrote: > aganea wrote: > > Since you're not

[PATCH] D100755: [llvm-rc] [3/4] Run clang to preprocess input files

2021-04-20 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added inline comments. Comment at: llvm/tools/llvm-rc/llvm-rc.cpp:94 + +ErrorOr findClang(const char *Argv0) { + StringRef Parent = llvm::sys::path::parent_path(Argv0); aganea wrote: > Since you're not using the `std::error_code` below in the call site,

[PATCH] D100874: [OpenMP] Use irbuilder as default for masked and master construct

2021-04-20 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D100874#2702897 , @cchen wrote: > I mark this patch as "plan changed" since the assert message indicates that > something wrong in IRBuilder or Codegen, however, main branch also have the > same issue so I think this patch

[PATCH] D81624: [CodeGen] Simplify the way lifetime of block captures is extended

2021-04-20 Thread Sharon Xu via Phabricator via cfe-commits
SharonXu added a comment. Hi @ahatanak , @rjmccall, we found that this diff causes an issue: When -fobjc-arc is enabled, if a block is passed as an argument to a function whose corresponding parameter type is && rvalue and attributed as noescape, the object captured by the block can get destruc

[PATCH] D100755: [llvm-rc] [3/4] Run clang to preprocess input files

2021-04-20 Thread Alexandre Ganea via Phabricator via cfe-commits
aganea added inline comments. Comment at: llvm/tools/llvm-rc/llvm-rc.cpp:94 + +ErrorOr findClang(const char *Argv0) { + StringRef Parent = llvm::sys::path::parent_path(Argv0); Since you're not using the `std::error_code` below in the call site, should this retu

[PATCH] D45639: [Driver] Support default libc++ library location on Darwin

2021-04-20 Thread Petr Hosek via Phabricator via cfe-commits
phosek added a comment. Another attempt is rGcaff17e503fe . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D45639/new/ https://reviews.llvm.org/D45639

[clang] caff17e - [Driver] Don't use capture for InstalledDir

2021-04-20 Thread Petr Hosek via cfe-commits
Author: Petr Hosek Date: 2021-04-20T13:43:56-07:00 New Revision: caff17e503fe81d69e90dd69b14f5149659f9db4 URL: https://github.com/llvm/llvm-project/commit/caff17e503fe81d69e90dd69b14f5149659f9db4 DIFF: https://github.com/llvm/llvm-project/commit/caff17e503fe81d69e90dd69b14f5149659f9db4.diff LO

[PATCH] D100874: [OpenMP] Use irbuilder as default for masked and master construct

2021-04-20 Thread Chi Chun Chen via Phabricator via cfe-commits
cchen added a comment. I mark this patch as "plan changed" since the assert message indicates that something wrong in IRBuilder or Codegen, however, main branch also have the same issue so I think this patch does not trigger the issue. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D93031: Enable fexec-charset option

2021-04-20 Thread ThePhD via Phabricator via cfe-commits
ThePhD added a comment. Just a tiny comment: could you please make sure the name of the resolved encoding is also propagated to InitPreprocessor.cpp that sets the `__clang_literal_encoding__` macro? (https://github.com/llvm/llvm-project/blob/main/clang/lib/Frontend/InitPreprocessor.cpp#L784)

[PATCH] D45639: [Driver] Support default libc++ library location on Darwin

2021-04-20 Thread Petr Hosek via Phabricator via cfe-commits
phosek added a comment. In D45639#2702746 , @thakis wrote: > Looks like this breaks tests on windows: > http://45.33.8.238/win/37191/step_7.txt Should be addressed by rGf5efe0aa048b .

[PATCH] D100756: [llvm-rc] [4/4] Add a GNU windres-like frontend to llvm-rc

2021-04-20 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo updated this revision to Diff 338978. mstorsjo added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. Rebased on top of the updated preceding patch. Adjusted the logic for picking th e default triple, to preserve the exact spelling of the default triple, i

[clang] f5efe0a - [Driver] Support both slashes

2021-04-20 Thread Petr Hosek via cfe-commits
Author: Petr Hosek Date: 2021-04-20T13:25:38-07:00 New Revision: f5efe0aa048b2bd3363b3a53efe9ae7367244801 URL: https://github.com/llvm/llvm-project/commit/f5efe0aa048b2bd3363b3a53efe9ae7367244801 DIFF: https://github.com/llvm/llvm-project/commit/f5efe0aa048b2bd3363b3a53efe9ae7367244801.diff LO

[PATCH] D100874: [OpenMP] Use irbuilder as default for masked and master construct

2021-04-20 Thread Chi Chun Chen via Phabricator via cfe-commits
cchen planned changes to this revision. cchen added a comment. This change seems to expose bugs in IRBuilder. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100874/new/ https://reviews.llvm.org/D100874 __

[PATCH] D77013: [AMDGPU] Add options -mamdgpu-ieee -mno-amdgpu-ieee

2021-04-20 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 338975. yaxunl marked 4 inline comments as done. yaxunl edited the summary of this revision. yaxunl added a comment. revised by Matt's comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77013/new/ https://reviews.llvm.org/D77013 Files: clang/i

[PATCH] D100820: [RISCV] Implement the vnot.v builtin.

2021-04-20 Thread Craig Topper via Phabricator via cfe-commits
craig.topper accepted this revision. craig.topper added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100820/new/ https://reviews.llvm.org/D100820 ___

[PATCH] D100822: [RISCV] Implement the vfabs.v/vfneg.v builtin.

2021-04-20 Thread Craig Topper via Phabricator via cfe-commits
craig.topper accepted this revision. craig.topper added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100822/new/ https://reviews.llvm.org/D100822 ___

[PATCH] D100755: [llvm-rc] [3/4] Run clang to preprocess input files

2021-04-20 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo updated this revision to Diff 338969. mstorsjo added a comment. Herald added subscribers: cfe-commits, mgorny. Herald added a project: clang. - Added a testcase under clang/test/Preprocessor - Changed the option to -no-preprocess - Removed the env var for disabling preprocessing - Made it

[PATCH] D45639: [Driver] Support default libc++ library location on Darwin

2021-04-20 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. Looks like this breaks tests on windows: http://45.33.8.238/win/37191/step_7.txt Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D45639/new/ https://reviews.llvm.org/D45639 ___ cfe-c

[PATCH] D100794: [HIP] Support overloaded math functions for hipRTC

2021-04-20 Thread Justin Lebar via Phabricator via cfe-commits
jlebar added a comment. Other than the declval issue discussed above, this looks reasonable to me. I don't notice anything wrong with the standard library reimplementations here. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100794/new/ https://reviews.llvm.org/D100794 __

[PATCH] D100807: [clang][driver] Use the canonical Darwin arch name when printing out the triple for a Darwin target

2021-04-20 Thread Ahmed Bougacha via Phabricator via cfe-commits
ab added a comment. This sounds nice! One idea, maybe more dangerous, not sure which is better: in `setTripleTypeForMachOArchName`, we already have a couple `setArchName` calls, I think that's why `arm64e` is left alone in the `aarch64-cpus.c` test. Maybe we can do the `setArchName` call for

[PATCH] D91950: [clang-format] Add BreakBeforeInlineASMColon configuration

2021-04-20 Thread Anastasiia Lukianenko via Phabricator via cfe-commits
anastasiia_lukianenko updated this revision to Diff 338958. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91950/new/ https://reviews.llvm.org/D91950 Files: clang/docs/ClangFormatStyleOptions.rst clang/include/clang/Format/Format.h clang/lib/Format/ContinuationIndenter.cpp clang/l

[PATCH] D45639: [Driver] Support default libc++ library location on Darwin

2021-04-20 Thread Petr Hosek via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGae8b2cab6740: [Driver] Support default libc++ library location on Darwin (authored by phosek). Herald added a project: clang. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://rev

[clang] ae8b2ca - [Driver] Support default libc++ library location on Darwin

2021-04-20 Thread Petr Hosek via cfe-commits
Author: Petr Hosek Date: 2021-04-20T12:30:35-07:00 New Revision: ae8b2cab67408a043a4fe964d16e4803553c4ee0 URL: https://github.com/llvm/llvm-project/commit/ae8b2cab67408a043a4fe964d16e4803553c4ee0 DIFF: https://github.com/llvm/llvm-project/commit/ae8b2cab67408a043a4fe964d16e4803553c4ee0.diff LO

[PATCH] D100830: [RISCV] [1/2] Add IR intrinsic for Zbp extension

2021-04-20 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added inline comments. Comment at: llvm/lib/Target/RISCV/RISCVInstrInfoB.td:33 def riscv_shfl : SDNode<"RISCVISD::SHFL", SDTIntBinOp>; +def riscv_shflw : SDNode<"RISCVISD::SHFLW", SDT_RISCVIntBinOpW>; +def riscv_unshfl : SDNode<"RISCVISD::UNSHFL", SDTInt

[PATCH] D100794: [HIP] Support overloaded math functions for hipRTC

2021-04-20 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked 2 inline comments as done. yaxunl added inline comments. Comment at: clang/lib/Headers/__clang_hip_cmath.h:341 - typedef decltype(__test(std::declval<_Tp>())) type; - static const bool value = !std::is_same::value; + typedef decltype(__test(_Tp{})) type; + sta

[PATCH] D100879: [Clang] Propagate guaranteed alignment for malloc and others

2021-04-20 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. GCC already knows about this guaranteed alignment, check: https://godbolt.org/z/sxn6K7Yq7 Alignment checks were optimized out. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100879/new/ https://reviews.llvm.org/D100879 _

[PATCH] D100879: [Clang] Propagate guaranteed alignment for malloc and others

2021-04-20 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:2060 +case Builtin::BIstrndup: + RetAttrs.addAlignmentAttr(Context.getTargetInfo().getNewAlign() / +Context.getTargetInfo().getCharWidth()); -

[PATCH] D100879: [Clang] Propagate guaranteed alignment for malloc and others

2021-04-20 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:2060 +case Builtin::BIstrndup: + RetAttrs.addAlignmentAttr(Context.getTargetInfo().getNewAlign() / +Context.getTargetInfo().getCharWidth()); ---

[PATCH] D100879: [Clang] Propagate guaranteed alignment for malloc and others

2021-04-20 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:2059 +case Builtin::BIstrdup: +case Builtin::BIstrndup: + RetAttrs.addAlignmentAttr(Context.getTargetInfo().getNewAlign() / As a followup, I need to teach Clang abou

[PATCH] D100879: [Clang] Propagate guaranteed alignment for malloc and others

2021-04-20 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 updated this revision to Diff 338950. xbolva00 added a reviewer: jdoerfert. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100879/new/ https://reviews.llvm.org/D100879 Files: clang/lib/CodeGen/CGCall.cpp Index: clang/lib/CodeGen/CGCall.cpp

[PATCH] D100879: [Clang] Propagate guaranteed alignment for malloc and others

2021-04-20 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. If this approach makes sense, I will update / add tests. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100879/new/ https://reviews.llvm.org/D100879 ___ cfe-commits mailing list

[PATCH] D100879: [Clang] Propagate guaranteed alignment for malloc and others

2021-04-20 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 created this revision. xbolva00 added reviewers: aaron.ballman, rjmccall. xbolva00 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. LLVM should be smarter about *known* malloc's alignment and this knowledge may enable other optimiz

[PATCH] D100834: Bug 49739 - [Matrix] Support #pragma clang fp

2021-04-20 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. I don't know the matrix implementation so I can't swear this hits every place needed, but the uses of CGFPOptionsRAII in this patch look correct at least. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100834/new/ https://revie

[PATCH] D77013: [AMDGPU] Add options -mamdgpu-ieee -mno-amdgpu-ieee

2021-04-20 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked 2 inline comments as done. yaxunl added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:1951 + Args.hasFlag(options::OPT_mamdgpu_ieee, options::OPT_mno_amdgpu_ieee, + !LangOptsRef.NoHonorNaNs); + arsenm

[PATCH] D100794: [HIP] Support overloaded math functions for hipRTC

2021-04-20 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/lib/Headers/__clang_hip_cmath.h:341 - typedef decltype(__test(std::declval<_Tp>())) type; - static const bool value = !std::is_same::value; + typedef decltype(__test(_Tp{})) type; + static const bool value = !is_same::value;

[PATCH] D100874: [OpenMP] Use irbuilder as default for masked and master construct

2021-04-20 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Patch description is empty. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100874/new/ https://reviews.llvm.org/D100874 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D100834: Bug 49739 - [Matrix] Support #pragma clang fp

2021-04-20 Thread Hamza Mahfooz via Phabricator via cfe-commits
effective-light updated this revision to Diff 338941. effective-light added a comment. Whoops Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100834/new/ https://reviews.llvm.org/D100834 Files: clang/lib/CodeGen/CGExprScalar.cpp clang/test/CodeG

[clang] 057b6f5 - clang: Update libstdc++ issue workaround

2021-04-20 Thread Nathan Sidwell via cfe-commits
Author: Nathan Sidwell Date: 2021-04-20T11:34:12-07:00 New Revision: 057b6f5d0b3ec1c1d0a87eb3d99ac4a46ca68cb4 URL: https://github.com/llvm/llvm-project/commit/057b6f5d0b3ec1c1d0a87eb3d99ac4a46ca68cb4 DIFF: https://github.com/llvm/llvm-project/commit/057b6f5d0b3ec1c1d0a87eb3d99ac4a46ca68cb4.diff

[PATCH] D100874: [OpenMP] Use irbuilder as default for masked and master construct

2021-04-20 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert accepted this revision. jdoerfert added a comment. This revision is now accepted and ready to land. LGTM, thanks Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100874/new/ https://reviews.llvm.org/D100874 _

[PATCH] D100118: [clang] RFC Support new builtin __arithmetic_fence to control floating point optimization, and new clang option fprotect-parens

2021-04-20 Thread Melanie Blower via Phabricator via cfe-commits
mibintc added inline comments. Comment at: clang/lib/CodeGen/CGBuiltin.cpp:2844 + return RValue::get( + Builder.CreateArithmeticFence(ArgValue, ConvertType(ArgType))); +return RValue::get(ArgValue); mibintc wrote: > kpn wrote: > > Does this say

[PATCH] D100567: BPF: emit debuginfo for Function of DeclRefExpr if requested

2021-04-20 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. In D100567#2702394 , @yonghong-song wrote: > ping @dblaikie could you take a look of my new investigation? Yep, it's on my list to look at. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.ll

  1   2   >