https://bugs.llvm.org/show_bug.cgi?id=45552

            Bug ID: 45552
           Summary: nobuiltin attribute ignored for sema diagnostics
           Product: clang
           Version: 10.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: -New Bugs
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected],
                    [email protected], [email protected]

#include <cstring>

static void overflow(void) __attribute__((no_builtin))
{
        char buf[8];
        /* Intentionally overwrite the stack. */
        memset(buf, 0x47, sizeof(buf)+24);
}

Compiled with `-Wfortify-source` emits a warning
(https://godbolt.org/z/nej7MN), while it does not when `-Wfortify-source
-fnobuiltin` is specified.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to