public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-03-31 19:10 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-03-31 19:10 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=ca2ffa0c11bdba7b5515f207eb531b9367aea2a6

commit ca2ffa0c11bdba7b5515f207eb531b9367aea2a6
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2024-04-17 20:11 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2024-04-17 20:11 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=367d2d90444b50233aae754903898f4c15c181f0

commit 367d2d90444b50233aae754903898f4c15c181f0
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2024-04-02 15:57 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2024-04-02 15:57 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=18f92a9b979d00e96629b1c15161d68274b10784

commit 18f92a9b979d00e96629b1c15161d68274b10784
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2024-02-09 17:35 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2024-02-09 17:35 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=e412f25183381a6d672c56dade2afb046acb5957

commit e412f25183381a6d672c56dade2afb046acb5957
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2024-02-07 14:10 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2024-02-07 14:10 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=2d502aefa5e54b89520b2f0593b7122bc784d718

commit 2d502aefa5e54b89520b2f0593b7122bc784d718
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2024-01-29 18:01 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2024-01-29 18:01 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=9f783b9c6a2c0cc6ae85847abb948d939ee24499

commit 9f783b9c6a2c0cc6ae85847abb948d939ee24499
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2023-12-21 18:57 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2023-12-21 18:57 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=fac8cb2886b45a4756aa4a67cc02ba05ca176855

commit fac8cb2886b45a4756aa4a67cc02ba05ca176855
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2023-09-28 17:55 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2023-09-28 17:55 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=c0be62be1d69127b90753b380193b361d2f48292

commit c0be62be1d69127b90753b380193b361d2f48292
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2023-08-30 12:40 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2023-08-30 12:40 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=47331b1a52b704f0978301c5ba0b603a2fc4e072

commit 47331b1a52b704f0978301c5ba0b603a2fc4e072
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2023-02-09 19:52 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2023-02-09 19:52 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=827d5ce6d6e802b299c470700a3dd792681825f7

commit 827d5ce6d6e802b299c470700a3dd792681825f7
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-10-28 17:45 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-10-28 17:45 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=c36dffb13151898490a14c7bcd9d949f0475cbb1

commit c36dffb13151898490a14c7bcd9d949f0475cbb1
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-10-04 13:03 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-10-04 13:03 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=c8a4b037311a325961ddcf0a60d92babdabbde46

commit c8a4b037311a325961ddcf0a60d92babdabbde46
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-06-09 21:23 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-06-09 21:23 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=f4655549a41e6bba31eac239a9692a0ef60aa89b

commit f4655549a41e6bba31eac239a9692a0ef60aa89b
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-06-09 13:20 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-06-09 13:20 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=f4655549a41e6bba31eac239a9692a0ef60aa89b

commit f4655549a41e6bba31eac239a9692a0ef60aa89b
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-06-03 14:09 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-06-03 14:09 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=d3f04f58032c3260c4a46b252894c2546f68c366

commit d3f04f58032c3260c4a46b252894c2546f68c366
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-05-13 14:23 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-05-13 14:23 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=009811e4dd87205a0f6be5c6ad7fb0b6c45333b8

commit 009811e4dd87205a0f6be5c6ad7fb0b6c45333b8
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-05-12 19:37 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-05-12 19:37 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=66d209ee1e7abef26d81c84da7be9e62dc8066d8

commit 66d209ee1e7abef26d81c84da7be9e62dc8066d8
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-05-10 18:27 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-05-10 18:27 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=95af571769550ac83ef3ec66c57553f3b2407f7a

commit 95af571769550ac83ef3ec66c57553f3b2407f7a
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-04-29 14:07 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-04-29 14:07 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=596cec4dd21e9316b24121ef609c82c2a47b4b96

commit 596cec4dd21e9316b24121ef609c82c2a47b4b96
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-04-04 12:57 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-04-04 12:57 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=76c38ea62813d91daa57ff60f41d65af5aaab33b

commit 76c38ea62813d91daa57ff60f41d65af5aaab33b
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4
@ 2022-03-29 20:33 Adhemerval Zanella
  0 siblings, 0 replies; 21+ messages in thread
From: Adhemerval Zanella @ 2022-03-29 20:33 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=a2fc810b0ecd2bfc3e66a92e80a2921658ca651b

commit a2fc810b0ecd2bfc3e66a92e80a2921658ca651b
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Fri Mar 25 11:21:33 2022 -0300

    elf: Suppress clang warning on tst-unique4
    
    clang warns that the instatiation of the variable is required,
    but no definition is available.  They are implemented on
    tst-unique4lib.so.
    
    Checked on x86_64-linux-gnu.

Diff:
---
 elf/tst-unique4.cc    | 6 ++++++
 elf/tst-unique4lib.cc | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/elf/tst-unique4.cc b/elf/tst-unique4.cc
index 575c70d3a1..ab727b8dbb 100644
--- a/elf/tst-unique4.cc
+++ b/elf/tst-unique4.cc
@@ -2,7 +2,12 @@
 #include "tst-unique4.h"
 
 #include <cstdio>
+#include <libc-diag.h>
 
+/* clang warns that the instatiation of the variable is required, but no
+   definition is available.  They are implemented on tst-unique4lib.so.  */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wundefined-var-template");
 static int a[24] =
   {
     S<1>::i, S<2>::i, S<3>::i, S<4>::i, S<5>::i, S<6>::i, S<7>::i, S<8>::i,
@@ -10,6 +15,7 @@ static int a[24] =
     S<16>::i, S<17>::i, S<18>::i, S<19>::i, S<20>::i, S<21>::i, S<22>::i,
     S<23>::i, S<24>::i
   };
+DIAG_POP_NEEDS_COMMENT_CLANG;
 
 int
 main (void)
diff --git a/elf/tst-unique4lib.cc b/elf/tst-unique4lib.cc
index 17a7cdf567..2829e75cee 100644
--- a/elf/tst-unique4lib.cc
+++ b/elf/tst-unique4lib.cc
@@ -2,7 +2,7 @@
 #include "tst-unique4.h"
 
 template<int N>
-int S<N>::i = N;
+int S<N>::i __attribute__ ((used)) = N;
 template<int N>
 const int S<N>::j __attribute__ ((used)) = -1;


^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2024-04-17 20:11 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-31 19:10 [glibc/azanella/clang] elf: Suppress clang warning on tst-unique4 Adhemerval Zanella
  -- strict thread matches above, loose matches on Subject: below --
2024-04-17 20:11 Adhemerval Zanella
2024-04-02 15:57 Adhemerval Zanella
2024-02-09 17:35 Adhemerval Zanella
2024-02-07 14:10 Adhemerval Zanella
2024-01-29 18:01 Adhemerval Zanella
2023-12-21 18:57 Adhemerval Zanella
2023-09-28 17:55 Adhemerval Zanella
2023-08-30 12:40 Adhemerval Zanella
2023-02-09 19:52 Adhemerval Zanella
2022-10-28 17:45 Adhemerval Zanella
2022-10-04 13:03 Adhemerval Zanella
2022-06-09 21:23 Adhemerval Zanella
2022-06-09 13:20 Adhemerval Zanella
2022-06-03 14:09 Adhemerval Zanella
2022-05-13 14:23 Adhemerval Zanella
2022-05-12 19:37 Adhemerval Zanella
2022-05-10 18:27 Adhemerval Zanella
2022-04-29 14:07 Adhemerval Zanella
2022-04-04 12:57 Adhemerval Zanella
2022-03-29 20:33 Adhemerval Zanella

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).