yamt wrote:
> That said, the description of the use case is ~3 short sentences.
ok.
here is a concrete example and a bit longer explanation:
https://github.com/yamt/toywasm/blob/9ee6ec86f56723819fd8411866094f72247dba78/lib/insn.c#L515-L527
https://github.com/llvm/llvm-project/pull/92499
efriedma-quic wrote:
I think the underlying functionality is pretty clearly useful: identical code
folding gives significant codesize reductions. In fact, on Windows, the linker
does this kind of folding automatically by default (despite the fact that it
isn't standards-compliant). I imagine
erichkeane wrote:
> > Hmm... I'm not sure this meets our requirements for inclusion as an
> > attribute. The semantics of this are pretty opaque, no obvious significant
> > motivation/applicability in the base languages, etc. There doesn't seem to
> > be any reasonable use case that I can
yamt wrote:
> If we're going to do this, it should probably also work for constants.
for completeness, maybe. i myself have no use cases though.
> Also, I think I'd prefer to sort out the situation with the C++ standard's
> rules for constant merging before we start extending those rules. See
yamt wrote:
> Hmm... I'm not sure this meets our requirements for inclusion as an
> attribute. The semantics of this are pretty opaque, no obvious significant
> motivation/applicability in the base languages, etc. There doesn't seem to be
> any reasonable use case that I can see.
do you mean
https://github.com/erichkeane commented:
Hmm... I'm not sure this meets our requirements for inclusion as an attribute.
The semantics of this are pretty opaque, no obvious significant
motivation/applicability in the base languages, etc. There doesn't seem to be
any reasonable use case that
@@ -1944,6 +1944,13 @@ def ReturnsTwice : InheritableAttr {
let SimpleHandler = 1;
}
+def UnnamedAddr : InheritableAttr {
+ let Spellings = [Clang<"unnamed_addr">];
+ let Subjects = SubjectList<[Function]>;
+ let Documentation = [Undocumented];
yamt
https://github.com/yamt updated https://github.com/llvm/llvm-project/pull/92499
>From 52b744c91bdba1cf8cda9d6164ec8fc130d75fab Mon Sep 17 00:00:00 2001
From: YAMAMOTO Takashi
Date: Fri, 17 May 2024 14:47:06 +0900
Subject: [PATCH 1/3] [clang] add unnamed_addr function attribute
It simply
efriedma-quic wrote:
If we're going to do this, it should probably also work for constants.
Also, I think I'd prefer to sort out the situation with the C++ standard's
rules for constant merging before we start extending those rules. See #63628.
https://github.com/llvm/llvm-project/pull/92499
https://github.com/Sirraide edited
https://github.com/llvm/llvm-project/pull/92499
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1944,6 +1944,13 @@ def ReturnsTwice : InheritableAttr {
let SimpleHandler = 1;
}
+def UnnamedAddr : InheritableAttr {
+ let Spellings = [Clang<"unnamed_addr">];
+ let Subjects = SubjectList<[Function]>;
+ let Documentation = [Undocumented];
Sirraide
https://github.com/Sirraide commented:
I’m not sure how useful such an attribute would be, but the implementation of
this looks ok, though this needs some documentation, a release note, and some
sema tests to make sure we diagnose it when it’s applied to a non-function and
codegen tests as
https://github.com/yamt edited https://github.com/llvm/llvm-project/pull/92499
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/yamt updated https://github.com/llvm/llvm-project/pull/92499
>From 52b744c91bdba1cf8cda9d6164ec8fc130d75fab Mon Sep 17 00:00:00 2001
From: YAMAMOTO Takashi
Date: Fri, 17 May 2024 14:47:06 +0900
Subject: [PATCH] [clang] add unnamed_addr function attribute
It simply applies
llvmbot wrote:
@llvm/pr-subscribers-clang
Author: YAMAMOTO Takashi (yamt)
Changes
It simply applies the LLVM attribute with the same name to the function.
Sometimes, a programmer knows that function pointer uniqueness doesn't really
matter for some of their functions. In that case, this
https://github.com/yamt created https://github.com/llvm/llvm-project/pull/92499
It simply applies the LLVM attribute with the same name to the function.
Sometimes, a programmer knows that function pointer uniqueness doesn't really
matter for some of their functions. In that case, this
16 matches
Mail list logo