public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc/maskray/relr] glibcextract.py: Place un-assemblable @@@ in a comment
@ 2021-10-29 22:18 Fangrui Song
  0 siblings, 0 replies; only message in thread
From: Fangrui Song @ 2021-10-29 22:18 UTC (permalink / raw)
  To: glibc-cvs

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

commit 46baeb61e16511f26db1b255e19dc9163f590367
Author: Fangrui Song <maskray@google.com>
Date:   Tue Oct 19 09:58:16 2021 -0700

    glibcextract.py: Place un-assemblable @@@ in a comment
    
    Unlike GCC, Clang parses asm statements and verifies they are valid
    instructions/directives. Place the magic @@@ into a comment to avoid
    a parse error.

Diff:
---
 scripts/glibcextract.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/glibcextract.py b/scripts/glibcextract.py
index 752ff6223b..bf49a5e322 100644
--- a/scripts/glibcextract.py
+++ b/scripts/glibcextract.py
@@ -45,7 +45,7 @@ def compute_c_consts(sym_data, cc):
             continue
         name = arg[0]
         value = arg[1]
-        out_lines.append('asm ("@@@name@@@%s@@@value@@@%%0@@@end@@@" '
+        out_lines.append('asm ("/* @@@name@@@%s@@@value@@@%%0@@@end@@@ */" '
                          ': : \"i\" ((long int) (%s)));'
                          % (name, value))
     out_lines.append('}')


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-10-29 22:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-29 22:18 [glibc/maskray/relr] glibcextract.py: Place un-assemblable @@@ in a comment Fangrui Song

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).