public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2022-10-28 17:44 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2022-10-28 17:44 UTC (permalink / raw)
  To: glibc-cvs

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

commit 92b07aa885131c0c5298afcda41ae8bde356a636
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c  | 6 +++++-
 libio/tst-bz24153.c  | 6 +++++-
 malloc/tst-tcfree3.c | 6 +++++-
 3 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index f315525071..3649dbbdbd 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index a069bf0695..9cfaa3b83c 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>
diff --git a/malloc/tst-tcfree3.c b/malloc/tst-tcfree3.c
index 3a3149b3b2..215134a9ae 100644
--- a/malloc/tst-tcfree3.c
+++ b/malloc/tst-tcfree3.c
@@ -20,7 +20,11 @@
 #include <string.h>
 
 /* Prevent GCC from optimizing away any malloc/free pairs.  */
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 static int
 do_test (void)

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2024-04-17 20:10 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2024-04-17 20:10 UTC (permalink / raw)
  To: glibc-cvs

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

commit 8eb85e1f8ac6ec5544e681d3d1e880e442b37310
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c | 6 +++++-
 libio/tst-bz24153.c | 6 +++++-
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index a9903f20a3..2d32aae74a 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index 023f07ca20..c379876fcc 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2024-04-02 15:56 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2024-04-02 15:56 UTC (permalink / raw)
  To: glibc-cvs

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

commit 464431cbad19955aa720a6fc34ca6108e32cdf2c
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c | 6 +++++-
 libio/tst-bz24153.c | 6 +++++-
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index a9903f20a3..2d32aae74a 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index 023f07ca20..c379876fcc 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2024-02-09 17:34 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2024-02-09 17:34 UTC (permalink / raw)
  To: glibc-cvs

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

commit 832420f131d6a2dc043ce028ec28fc16b8c1aa81
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c | 6 +++++-
 libio/tst-bz24153.c | 6 +++++-
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index a9903f20a3..2d32aae74a 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index 023f07ca20..c379876fcc 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2024-02-07 14:09 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2024-02-07 14:09 UTC (permalink / raw)
  To: glibc-cvs

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

commit 179c3f1bfcb3a0647901ad5e9a663675549c5451
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c | 6 +++++-
 libio/tst-bz24153.c | 6 +++++-
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index a9903f20a3..2d32aae74a 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index 023f07ca20..c379876fcc 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2024-01-29 18:00 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2024-01-29 18:00 UTC (permalink / raw)
  To: glibc-cvs

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

commit c70c975affeb2b2ea2634b8c3329994fe6d75d3e
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c | 6 +++++-
 libio/tst-bz24153.c | 6 +++++-
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index a9903f20a3..2d32aae74a 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index 023f07ca20..c379876fcc 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2023-12-21 18:56 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2023-12-21 18:56 UTC (permalink / raw)
  To: glibc-cvs

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

commit 51b09e10fb0896818baf1b41f45822248be022bd
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c | 6 +++++-
 libio/tst-bz24153.c | 6 +++++-
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index b2610827a0..a9053c0dca 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index 88f7ab13eb..37e0a250bd 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2023-09-28 17:54 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2023-09-28 17:54 UTC (permalink / raw)
  To: glibc-cvs

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

commit 4da53696a28ec5e8c931124316991e644040472e
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c  | 6 +++++-
 libio/tst-bz24153.c  | 6 +++++-
 malloc/tst-tcfree3.c | 6 +++++-
 3 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index b2610827a0..a9053c0dca 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index 88f7ab13eb..37e0a250bd 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>
diff --git a/malloc/tst-tcfree3.c b/malloc/tst-tcfree3.c
index ce6d958f8a..dbee260322 100644
--- a/malloc/tst-tcfree3.c
+++ b/malloc/tst-tcfree3.c
@@ -20,7 +20,11 @@
 #include <string.h>
 
 /* Prevent GCC from optimizing away any malloc/free pairs.  */
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 static int
 do_test (void)

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2023-08-30 12:39 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2023-08-30 12:39 UTC (permalink / raw)
  To: glibc-cvs

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

commit b79c067f2e259eaf431a306eab945087d029226d
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c  | 6 +++++-
 libio/tst-bz24153.c  | 6 +++++-
 malloc/tst-tcfree3.c | 6 +++++-
 3 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index b2610827a0..a9053c0dca 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index 88f7ab13eb..37e0a250bd 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>
diff --git a/malloc/tst-tcfree3.c b/malloc/tst-tcfree3.c
index ce6d958f8a..dbee260322 100644
--- a/malloc/tst-tcfree3.c
+++ b/malloc/tst-tcfree3.c
@@ -20,7 +20,11 @@
 #include <string.h>
 
 /* Prevent GCC from optimizing away any malloc/free pairs.  */
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 static int
 do_test (void)

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2023-02-09 19:51 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2023-02-09 19:51 UTC (permalink / raw)
  To: glibc-cvs

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

commit 69dc737af2ebfac83238374fc871fff0e93e5cf3
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c  | 6 +++++-
 libio/tst-bz24153.c  | 6 +++++-
 malloc/tst-tcfree3.c | 6 +++++-
 3 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index b2610827a0..a9053c0dca 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index 88f7ab13eb..37e0a250bd 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>
diff --git a/malloc/tst-tcfree3.c b/malloc/tst-tcfree3.c
index ce6d958f8a..dbee260322 100644
--- a/malloc/tst-tcfree3.c
+++ b/malloc/tst-tcfree3.c
@@ -20,7 +20,11 @@
 #include <string.h>
 
 /* Prevent GCC from optimizing away any malloc/free pairs.  */
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 static int
 do_test (void)

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

* [glibc/azanella/clang] Handle pragma GCC optimize for clang
@ 2022-10-04 13:02 Adhemerval Zanella
  0 siblings, 0 replies; 11+ messages in thread
From: Adhemerval Zanella @ 2022-10-04 13:02 UTC (permalink / raw)
  To: glibc-cvs

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

commit 7726804b2b1fb77e963c0cb1b672b0bd5024810e
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Thu Mar 24 16:17:59 2022 -0300

    Handle pragma GCC optimize for clang

Diff:
---
 libio/tst-bz24051.c  | 6 +++++-
 libio/tst-bz24153.c  | 6 +++++-
 malloc/tst-tcfree3.c | 6 +++++-
 3 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/libio/tst-bz24051.c b/libio/tst-bz24051.c
index f315525071..3649dbbdbd 100644
--- a/libio/tst-bz24051.c
+++ b/libio/tst-bz24051.c
@@ -19,7 +19,11 @@
 
 /* Prevent putchar -> _IO_putc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdio.h>
 #include <string.h>
diff --git a/libio/tst-bz24153.c b/libio/tst-bz24153.c
index a069bf0695..9cfaa3b83c 100644
--- a/libio/tst-bz24153.c
+++ b/libio/tst-bz24153.c
@@ -18,7 +18,11 @@
 
 /* Prevent getchar -> getc inline expansion.  */
 #define __NO_INLINE__
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 #include <stdarg.h>
 #include <stdio.h>
diff --git a/malloc/tst-tcfree3.c b/malloc/tst-tcfree3.c
index 3a3149b3b2..215134a9ae 100644
--- a/malloc/tst-tcfree3.c
+++ b/malloc/tst-tcfree3.c
@@ -20,7 +20,11 @@
 #include <string.h>
 
 /* Prevent GCC from optimizing away any malloc/free pairs.  */
-#pragma GCC optimize ("O0")
+#ifdef __clang__
+# pragma clang optimize off
+#else
+# pragma GCC optimize("O0")
+#endif
 
 static int
 do_test (void)

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

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

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-28 17:44 [glibc/azanella/clang] Handle pragma GCC optimize for clang Adhemerval Zanella
  -- strict thread matches above, loose matches on Subject: below --
2024-04-17 20:10 Adhemerval Zanella
2024-04-02 15:56 Adhemerval Zanella
2024-02-09 17:34 Adhemerval Zanella
2024-02-07 14:09 Adhemerval Zanella
2024-01-29 18:00 Adhemerval Zanella
2023-12-21 18:56 Adhemerval Zanella
2023-09-28 17:54 Adhemerval Zanella
2023-08-30 12:39 Adhemerval Zanella
2023-02-09 19:51 Adhemerval Zanella
2022-10-04 13:02 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).