Module Name: src Committed By: christos Date: Sun Sep 3 18:45:26 UTC 2023
Modified Files: src/external/gpl3/gcc.old/dist/gcc: ubsan.c Log Message: remap generated ubsan filename string labels. fixes reproducible builds. reported by wiz@ To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/external/gpl3/gcc.old/dist/gcc/ubsan.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/external/gpl3/gcc.old/dist/gcc/ubsan.c diff -u src/external/gpl3/gcc.old/dist/gcc/ubsan.c:1.6 src/external/gpl3/gcc.old/dist/gcc/ubsan.c:1.7 --- src/external/gpl3/gcc.old/dist/gcc/ubsan.c:1.6 Sun Feb 19 21:11:07 2023 +++ src/external/gpl3/gcc.old/dist/gcc/ubsan.c Sun Sep 3 14:45:26 2023 @@ -49,6 +49,7 @@ along with GCC; see the file COPYING3. #include "tree-cfg.h" #include "gimple-fold.h" #include "varasm.h" +#include "file-prefix-map.h" /* Map from a tree to a VAR_DECL tree. */ @@ -304,8 +305,9 @@ ubsan_source_location (location_t loc) else { /* Fill in the values from LOC. */ - size_t len = strlen (xloc.file) + 1; - str = build_string (len, xloc.file); + const char *file = remap_debug_filename (xloc.file); + size_t len = strlen (file) + 1; + str = build_string (len, file); TREE_TYPE (str) = build_array_type_nelts (char_type_node, len); TREE_READONLY (str) = 1; TREE_STATIC (str) = 1;