compnerd wrote:
I don't think that this fully fixes the issue as it doesn't completely break
the cycle.
https://github.com/llvm/llvm-project/pull/131668
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/lis
https://github.com/compnerd updated
https://github.com/llvm/llvm-project/pull/131668
>From 8415be6e59aa2f8a23a3e484b1c8053f4d0c7206 Mon Sep 17 00:00:00 2001
From: Saleem Abdulrasool
Date: Mon, 17 Mar 2025 13:31:05 -0700
Subject: [PATCH] Headers: prefer `corecrt_malloc.h` to `malloc.h`
This all
@@ -13,7 +13,7 @@
#include
#ifdef _WIN32
-#include
+#include
compnerd wrote:
Thanks for the typo correction!
I think that I can add in a `!defined(__MINGW32__)` condition.
https://github.com/llvm/llvm-project/pull/131668
_
https://github.com/compnerd created
https://github.com/llvm/llvm-project/pull/131668
This allows us to target a lower level library (corecrt) rather than the higher
level library (ucrt) which can be helpful in mordularising the SDK.
>From f8dea4c8a85c018a3c7ef5eadd00f2da96fe1737 Mon Sep 17 00:
compnerd wrote:
New version also includes the release notes for this.
https://github.com/llvm/llvm-project/pull/130993
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd updated
https://github.com/llvm/llvm-project/pull/130993
>From 1021d05a73cb990bcbdd1948fd372fdf4b1a21ec Mon Sep 17 00:00:00 2001
From: Saleem Abdulrasool
Date: Wed, 12 Mar 2025 09:52:58 -0700
Subject: [PATCH] Lex: add support for `i128` and `ui128` suffixes
Microsof
compnerd wrote:
> > Take the opportunity to tighten up the code slightly by ensuring that we do
> > not access out-of-bounds characters when lexing the token.
>
> That's a nice touch :-)
😄
> Do we already have tests somewhere checking that we can codegen this, or do
> we need to add that?
I
@@ -3924,10 +3924,18 @@ ExprResult Sema::ActOnNumericConstant(const Token &Tok,
Scope *UDLScope) {
// to get the integer value from an overly-wide APInt is *extremely*
// expensive, so the naive approach of assuming
// llvm::IntegerType::MAX_INT_BITS is a big perfo
@@ -13,16 +13,24 @@ __int64 w = 0x43ui64;
__int64 z = 9Li64; // expected-error {{invalid suffix}}
__int64 q = 10lli64; // expected-error {{invalid suffix}}
-__complex double c1 = 1i;
-__complex double c2 = 1.0i;
+__complex double c1 = 1i; // GNU extension
+__complex double c
https://github.com/compnerd updated
https://github.com/llvm/llvm-project/pull/130993
>From ba82162bbc75ab6838f2c1aa0ad89cfe585a578f Mon Sep 17 00:00:00 2001
From: Saleem Abdulrasool
Date: Wed, 12 Mar 2025 09:52:58 -0700
Subject: [PATCH] Lex: add support for `i128` and `ui128` suffixes
Microsof
https://github.com/compnerd created
https://github.com/llvm/llvm-project/pull/130993
Microsoft's compiler supports an extension for 128-bit literals. This is
referenced in `intsafe.h` which is included transitievly. When building with
modules, the literal parsing causes a failure due to the mi
compnerd wrote:
@steakhal bleh, is the "New Features" a sub item of "Static Analyzer"?
https://github.com/llvm/llvm-project/pull/125384
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/126961
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/126675
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd closed
https://github.com/llvm/llvm-project/pull/125384
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
compnerd wrote:
I can see that as being useful certainly. `-fblocks` could add
`-lBlocksRuntime`. However, I think that the behaviour change with
`-static-libclosure` would then impact both code generation (on Windows) and
the linking, which would give the correct desired behaviour. Where as,
compnerd wrote:
The other way works with warnings and some performance loss and code bloat
(linking code designed for DLL as static).
So far I've always mandated dynamic linking for BlocksRuntime on Windows within
the Swift toolchain and by the Swift toolchain.
You are correct that the `-stat
https://github.com/compnerd updated
https://github.com/llvm/llvm-project/pull/125384
>From 33f361fda5b27964037c061d7944c01d3891d914 Mon Sep 17 00:00:00 2001
From: Saleem Abdulrasool
Date: Sat, 1 Feb 2025 15:04:04 -0800
Subject: [PATCH] CodeGen: support static linking for libclosure
When buildi
https://github.com/compnerd created
https://github.com/llvm/llvm-project/pull/125384
When building on Windows, dealing with the BlocksRuntime is slightly more
complicated. As we are not guaranteed a formward declaration for the blocks
runtime ABI symbols, we may generate the declarations for t
Author: Saleem Abdulrasool
Date: 2025-02-01T14:49:29-08:00
New Revision: b798679c076af4acaa806e893b038372f5954298
URL:
https://github.com/llvm/llvm-project/commit/b798679c076af4acaa806e893b038372f5954298
DIFF:
https://github.com/llvm/llvm-project/commit/b798679c076af4acaa806e893b038372f5954298.
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/125250
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/122516
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -19493,7 +19493,11 @@ void Sema::ActOnFields(Scope *S, SourceLocation
RecLoc, Decl *EnclosingDecl,
CDecl->setIvarRBraceLoc(RBrac);
}
}
- ProcessAPINotes(Record);
+
+ // If this is a class template instantiation, its API Notes attributes were
+ // added to the
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/122516
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
compnerd wrote:
(waiting to see if Aaron can also take a look)
https://github.com/llvm/llvm-project/pull/119403
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/119403
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/120487
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd closed
https://github.com/llvm/llvm-project/pull/119090
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
compnerd wrote:
I'll go ahead and merge the change on your behalf as I suspect that you do not
have commit rights as this is your first PR to the project. Thank you for the
contribution!
https://github.com/llvm/llvm-project/pull/119090
___
cfe-commit
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/119090
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -46,6 +46,9 @@ typedef struct {
/**
* Retrieve the character data associated with the given string.
+ *
+ * The caller shouldn't free the returned string data, and the returned string
+ * data shouldn't be accessed after the \c CXString disposed.
compnerd
@@ -46,6 +46,9 @@ typedef struct {
/**
* Retrieve the character data associated with the given string.
+ *
+ * The caller shouldn't free the returned string data, and the returned string
+ * data shouldn't be accessed after the \c CXString disposed.
compnerd
https://github.com/compnerd edited
https://github.com/llvm/llvm-project/pull/119090
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -46,6 +46,9 @@ typedef struct {
/**
* Retrieve the character data associated with the given string.
+ *
+ * The caller shouldn't free the returned string data, and the returned string
+ * data shouldn't be accessed after the \c CXString disposed.
compnerd
@@ -373,6 +373,13 @@ void ReadFunctionInfo(const uint8_t *&Data, FunctionInfo
&Info) {
endian::readNext(Data);
Info.ResultType = std::string(Data, Data + ResultTypeLen);
Data += ResultTypeLen;
+
+ unsigned SwiftReturnOwnershipLength =
+ endian::readNext(Data);
@@ -373,6 +373,13 @@ void ReadFunctionInfo(const uint8_t *&Data, FunctionInfo
&Info) {
endian::readNext(Data);
Info.ResultType = std::string(Data, Data + ResultTypeLen);
Data += ResultTypeLen;
+
+ unsigned SwiftReturnOwnershipLength =
+ endian::readNext(Data);
compnerd wrote:
> But this before we do that, we need to have some kind of mechanism in place
> so we can actually enumerate the AP However, we already expose everything in
> the API, and just adding the annotations doesn't change that (although I
> think it may slightly reduce the number of s
compnerd wrote:
> Well, we're currently approaching this from the angle of "expose everything
> and then the user can do whatever they want", but perhaps the discussion we
> should be having is "what use cases do we explicitly want to support?" and
> then we write plugins to demonstrate that w
compnerd wrote:
> > I can absolutely see the value in the opposite - minimise the ABI surface.
> > For many projects, there is a split of internal and external headers. The
> > idea is that this tool is only run on the external headers, so those are
> > meant to be ABI.
>
> There were multipl
compnerd wrote:
> > The default behaviour of `ids` is to assume that anything declared in the
> > header is public and it will ensure that anything added in the headers is
> > annotated properly to say it is exposed, making something private would be
> > an explicit decision that the developer
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/117194
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -47,7 +47,7 @@ endmacro()
macro(add_clang_library name)
cmake_parse_arguments(ARG
-"SHARED;STATIC;INSTALL_WITH_TOOLCHAIN"
+"SHARED;STATIC;INSTALL_WITH_TOOLCHAIN;CLANG_IMPORT"
compnerd wrote:
We should document the option. Why is it specific to cl
@@ -114,7 +114,7 @@ macro(add_clang_library name)
if(TARGET "obj.${name}")
target_compile_definitions("obj.${name}" PUBLIC CLANG_BUILD_STATIC)
endif()
- elseif(NOT ARG_SHARED AND NOT ARG_STATIC)
+ elseif(NOT ARG_SHARED AND NOT ARG_STATIC AND NOT ARG_CLANG_IMPORT
@@ -114,7 +114,7 @@ macro(add_clang_library name)
if(TARGET "obj.${name}")
target_compile_definitions("obj.${name}" PUBLIC CLANG_BUILD_STATIC)
endif()
- elseif(NOT ARG_SHARED AND NOT ARG_STATIC)
+ elseif(NOT ARG_SHARED AND NOT ARG_STATIC AND NOT ARG_CLANG_IMPORT
@@ -47,7 +47,7 @@ endmacro()
macro(add_clang_library name)
cmake_parse_arguments(ARG
-"SHARED;STATIC;INSTALL_WITH_TOOLCHAIN"
+"SHARED;STATIC;INSTALL_WITH_TOOLCHAIN;CLANG_IMPORT"
compnerd wrote:
It is unclear what this new option (`CLANG_IMPORT`) doe
https://github.com/compnerd edited
https://github.com/llvm/llvm-project/pull/115866
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd approved this pull request.
Some minor comments left.
https://github.com/llvm/llvm-project/pull/115866
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1266,11 +1266,11 @@ class CommonTypeTableInfo
class TagTableInfo : public CommonTypeTableInfo {
public:
unsigned getUnversionedInfoSize(const TagInfo &TI) {
-return 2 + (TI.SwiftImportAs ? TI.SwiftImportAs->size() : 0) +
- 2 + (TI.SwiftRetainOp ? TI.SwiftRet
@@ -757,6 +763,15 @@ class TagInfo : public CommonTypeInfo {
SwiftCopyable = Value.value_or(false);
}
+ std::optional isSwiftEscapable() const {
+return SwiftEscapableSpecified ? std::optional(SwiftEscapable)
+ : std::nullopt;
+ }
@@ -589,10 +589,16 @@ class TagTableInfo
uint8_t Copyable =
endian::readNext(Data);
-if (Copyable == kSwiftNonCopyable)
+if (Copyable == kSwiftDoesNotConform)
Info.setSwiftCopyable(std::optional(false));
-else if (Copyable == kSwiftCopyable)
+
@@ -647,6 +647,13 @@ static void ProcessAPINotes(Sema &S, TagDecl *D, const
api_notes::TagInfo &Info,
D->addAttr(SwiftAttrAttr::Create(S.Context, "~Copyable"));
}
+ if (auto Escapable = Info.isSwiftEscapable()) {
+if (*Escapable)
+ D->addAttr(SwiftAttrAttr::
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/115021
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -730,7 +731,9 @@ class YAMLConverter {
}
}
- void convertParams(const ParamsSeq &Params, FunctionInfo &OutInfo) {
+ std::optional convertParams(const ParamsSeq &Params,
+ FunctionInfo &OutInfo) {
compnerd wrot
@@ -396,12 +397,19 @@ class ObjCMethodTableInfo
const uint8_t *&Data) {
ObjCMethodInfo Info;
uint8_t Payload = *Data++;
+bool HasSelf = Payload & 0x01;
+Payload >>= 1;
Info.RequiredInit = Payload & 0x01;
Payload
@@ -730,7 +731,9 @@ class YAMLConverter {
}
}
- void convertParams(const ParamsSeq &Params, FunctionInfo &OutInfo) {
+ std::optional convertParams(const ParamsSeq &Params,
+ FunctionInfo &OutInfo) {
compnerd wrot
@@ -516,7 +524,17 @@ class CXXMethodTableInfo
static CXXMethodInfo readUnversioned(internal_key_type Key,
const uint8_t *&Data) {
CXXMethodInfo Info;
+
+uint8_t Payload = *Data++;
+bool HasThis = Payload & 0x01;
+Payload
@@ -739,10 +742,16 @@ class YAMLConverter {
PI.setLifetimebound(P.Lifetimebound);
PI.setType(std::string(P.Type));
PI.setRetainCountConvention(P.RetainCountConvention);
- if (OutInfo.Params.size() <= P.Position)
+ if (static_cast(OutInfo.Params.size(
@@ -926,11 +935,17 @@ class YAMLConverter {
TheNamespace.Items, SwiftVersion);
}
- void convertFunction(const Function &Function, FunctionInfo &FI) {
+ template
+ void convertFunction(const Function &Function, FuncOrMethodInfo &FI) {
convert
@@ -793,12 +802,22 @@ class CXXMethodTableInfo
return static_cast(key.hashValue());
}
- unsigned getUnversionedInfoSize(const CXXMethodInfo &OMI) {
-return getFunctionInfoSize(OMI);
+ unsigned getUnversionedInfoSize(const CXXMethodInfo &CxxMI) {
+auto size = ge
@@ -730,7 +731,9 @@ class YAMLConverter {
}
}
- void convertParams(const ParamsSeq &Params, FunctionInfo &OutInfo) {
+ std::optional convertParams(const ParamsSeq &Params,
+ FunctionInfo &OutInfo) {
+std::optional thisOrSelf;
compnerd wrote:
Thanks @AaronBallman - @egorzhdan was nice enough to reach out to me earlier
and I am fine with co-maintaining the APINotes.
https://github.com/llvm/llvm-project/pull/114981
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/114830
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -444,6 +454,16 @@ class ParamInfo : public VariableInfo {
NoEscape = Value.value_or(false);
}
+ std::optional isLifetimebound() const {
+if (!LifetimeboundSpecified)
+ return std::nullopt;
+return Lifetimebound;
compnerd wrote:
```sugge
@@ -860,13 +868,12 @@ void Sema::ProcessAPINotes(Decl *D) {
if (!D)
return;
+ auto *DC = D->getDeclContext();
// Globals.
- if (D->getDeclContext()->isFileContext() ||
- D->getDeclContext()->isNamespace() ||
- D->getDeclContext()->isExternCContext() ||
-
compnerd wrote:
> pre-commit actions are expensive, but I think we could afford to do something
> here. It is not hard to set up a DLL build of an ELF DSO build that uses
> these annotations, and it's cheaper than a fully static build.
Having a fast incremental build for DLL-enabled LLVM/clang
@@ -1165,6 +1188,23 @@ void Writer::createMiscChunks() {
llvm::TimeTraceScope timeScope("Misc chunks");
Configuration *config = &ctx.config;
+ auto searchForPgoMagicSection = [this](char sectionName[]) {
+for (auto *obj : ctx.objFileInstances) {
+ for (auto &chun
https://github.com/compnerd commented:
Should the call be prior to the assert?
https://github.com/llvm/llvm-project/pull/112768
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,153 @@
+//===-- amdgpuintrin.h - AMDPGU intrinsic functions
---===//
+//
+// 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
@@ -0,0 +1,153 @@
+//===-- amdgpuintrin.h - AMDPGU intrinsic functions
---===//
+//
+// 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
compnerd wrote:
> Looking at Format.h (the only file I'm interested in), there feels to me to
> be things in the ABI that I wouldn't expect to be called externally, I don't
> know enough about what's involved in creating a DLL ABI but I wouldn't want
> some of the clang-format functions to be
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/108276
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -31,6 +31,7 @@ set(LLVM_LINK_COMPONENTS
Target
TargetParser
TransformUtils
+ CodeGenTypes
compnerd wrote:
This is duplicated (L6).
https://github.com/llvm/llvm-project/pull/109601
___
cfe-commits mailing l
@@ -31,6 +31,7 @@ set(LLVM_LINK_COMPONENTS
Target
TargetParser
TransformUtils
+ LLVMCodeGenTypes
compnerd wrote:
These are lexicographically sorted, please maintain that invariant.
https://github.com/llvm/llvm-project/pull/109601
__
https://github.com/compnerd edited
https://github.com/llvm/llvm-project/pull/109601
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd edited
https://github.com/llvm/llvm-project/pull/109601
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1,3 +1,7 @@
+if(EXISTS ${LLVM_MAIN_SRC_DIR}/include/llvm/CodeGen AND CLANG_BUILT_STANDALONE)
+ add_subdirectory(${LLVM_MAIN_SRC_DIR}/include/llvm/CodeGen llvm/lib/CodeGen)
+endif()
compnerd wrote:
https://github.com/llvm/llvm-project/blob/main/llvm/cmake/mod
@@ -1,3 +1,7 @@
+if(EXISTS ${LLVM_MAIN_SRC_DIR}/include/llvm/CodeGen AND CLANG_BUILT_STANDALONE)
+ add_subdirectory(${LLVM_MAIN_SRC_DIR}/include/llvm/CodeGen llvm/lib/CodeGen)
+endif()
compnerd wrote:
The issue is that the `vt_gen` target is undefined. This is _
compnerd wrote:
> @compnerd @etcwilde WDYT about conditionalizing the new dependency with an
> `if (TARGET vt_gen)` instead of doing the `add_subdirectory()` dance?
Ugh, I misread the change as `include_directories`. The `add_subdirectory` is
definitely odd and I'm not sure if that is a proper
@@ -1,3 +1,7 @@
+if(EXISTS ${LLVM_MAIN_SRC_DIR}/include/llvm/CodeGen AND CLANG_BUILT_STANDALONE)
+ add_subdirectory(${LLVM_MAIN_SRC_DIR}/include/llvm/CodeGen llvm/lib/CodeGen)
+endif()
compnerd wrote:
No, `LLVM_DIR` is passed to the CMake configure step to locat
@@ -1,3 +1,7 @@
+if(EXISTS ${LLVM_MAIN_SRC_DIR}/include/llvm/CodeGen AND CLANG_BUILT_STANDALONE)
compnerd wrote:
I think that I would rather have the cases mirrored here - the path should
always exist in general, it is only the standalone case that is special.
@@ -1,3 +1,7 @@
+if(EXISTS ${LLVM_MAIN_SRC_DIR}/include/llvm/CodeGen AND CLANG_BUILT_STANDALONE)
+ add_subdirectory(${LLVM_MAIN_SRC_DIR}/include/llvm/CodeGen llvm/lib/CodeGen)
+endif()
compnerd wrote:
IIRC, even in the standalone case, you need to identify the L
@@ -0,0 +1,69 @@
+//===-- clang/Support/Compiler.h - Compiler abstraction support -*- C++
-*-===//
+//
+// 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
@@ -0,0 +1,69 @@
+//===-- clang/Support/Compiler.h - Compiler abstraction support -*- C++
-*-===//
+//
+// 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
@@ -26,7 +26,7 @@ if(NOT CLANG_BUILT_STANDALONE)
set(tablegen_deps intrinsics_gen LinkerWrapperOpts)
endif()
-add_clang_tool(clang-linker-wrapper
+add_clang_tool(clang-linker-wrapper DISABLE_CLANG_LINK_DYLIB
compnerd wrote:
Similar
https://github.com/llvm/
@@ -8,6 +8,7 @@
set(LLVM_LINK_COMPONENTS Support)
-add_clang_tool(amdgpu-arch AMDGPUArch.cpp AMDGPUArchByHSA.cpp
AMDGPUArchByHIP.cpp)
+add_clang_tool(amdgpu-arch DISABLE_CLANG_LINK_DYLIB
compnerd wrote:
Why is this not allowed? Can we add a note about this?
@@ -7,6 +7,7 @@
#
//======//
set(LLVM_LINK_COMPONENTS Support)
-add_clang_tool(nvptx-arch NVPTXArch.cpp)
+add_clang_tool(nvptx-arch DISABLE_CLANG_LINK_DYLIB
compnerd wrote:
Likewise
https:/
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/109457
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
compnerd wrote:
> One thing I don't understand about this PR is why we need Compiler.h in Clang
> -- wouldn't the LLVM definitions in their Compiler.h work for Clang as well?
> (This would probably be worth explaining in the patch summary.)
The symbol lookup in PE/COFF is two level and symmetr
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/109306
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -165,4 +166,8 @@ const std::list>
&getAttributePluginInstances();
} // namespace clang
+namespace llvm {
+extern template class CLANG_TEMPLATE_ABI llvm::Registry;
compnerd wrote:
```suggestion
extern template class CLANG_TEMPLATE_ABI Registry;
```
This
@@ -189,19 +190,23 @@
#define LLVM_TEMPLATE_ABI __declspec(dllimport)
#define LLVM_EXPORT_TEMPLATE
#endif
+#define LLVM_ABI_EXPORT __declspec(dllexport)
compnerd wrote:
Why is this being added? I'm weary of any macro that is always export only
because the val
@@ -108,6 +108,10 @@ macro(add_clang_library name)
endif()
llvm_add_library(${name} ${LIBTYPE} ${ARG_UNPARSED_ARGUMENTS} ${srcs})
+ if(NOT ARG_SHARED AND NOT ARG_STATIC)
+target_compile_definitions("obj.${name}" PRIVATE CLANG_EXPORTS)
compnerd wrote:
@@ -166,7 +166,7 @@ if(ENABLE_SHARED)
set_target_properties(libclang
PROPERTIES
VERSION ${LIBCLANG_LIBRARY_VERSION}
- DEFINE_SYMBOL _CINDEX_LIB_)
+ DEFINE_SYMBOL _CINDEX_LIB_ DEFINE_SYMBOL CLANG_EXPORTS)
compnerd wrote:
This will ove
@@ -1699,11 +1699,18 @@ class CGObjCGNUstep2 : public CGObjCGNUstep {
llvm::Value *EmitIvarOffset(CodeGenFunction &CGF,
const ObjCInterfaceDecl *Interface,
const ObjCIvarDecl *Ivar) override {
-const std::string
compnerd wrote:
Please also get a sign off from @aganea
https://github.com/llvm/llvm-project/pull/106369
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -484,8 +519,10 @@ static bool initTargetOptions(DiagnosticsEngine &Diags,
Entry.Group == frontend::IncludeDirGroup::System))
Options.MCOptions.IASSearchPaths.push_back(
Entry.IgnoreSysRoot ? Entry.Path : HSOpts.Sysroot + Entry.Path);
- Options.MCOpt
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/106369
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/101962
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -321,6 +322,41 @@ static bool actionRequiresCodeGen(BackendAction Action) {
Action != Backend_EmitLL;
}
+static std::string flattenClangCommandLine(ArrayRef Args,
+ StringRef MainFilename) {
+ std::string FlatCmdLine;
+ raw_st
@@ -322,6 +323,46 @@ static bool actionRequiresCodeGen(BackendAction Action) {
Action != Backend_EmitLL;
}
+static std::string flattenClangCommandLine(ArrayRef Args,
+ StringRef MainFilename) {
+ if (Args.empty())
+ {
---
1 - 100 of 1035 matches
Mail list logo