From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1851) id 5D18F394BE03; Fri, 14 May 2021 12:12:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 5D18F394BE03 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Martin Liska To: gcc-cvs@gcc.gnu.org Subject: [gcc r10-9824] gcc-changelog: sync scripts. X-Act-Checkin: gcc X-Git-Author: Martin Liska X-Git-Refname: refs/heads/releases/gcc-10 X-Git-Oldrev: 0c6fe939eb7b05c25c443c8f06d6439c3d8110f4 X-Git-Newrev: a0368f8344f85c09886c7c77b9aff6ae4f94ee80 Message-Id: <20210514121224.5D18F394BE03@sourceware.org> Date: Fri, 14 May 2021 12:12:24 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 May 2021 12:12:24 -0000 https://gcc.gnu.org/g:a0368f8344f85c09886c7c77b9aff6ae4f94ee80 commit r10-9824-ga0368f8344f85c09886c7c77b9aff6ae4f94ee80 Author: Martin Liska Date: Fri May 14 14:10:33 2021 +0200 gcc-changelog: sync scripts. contrib/ChangeLog: * gcc-changelog/git_check_commit.py: Sync from master. * gcc-changelog/git_commit.py: Likewise. * gcc-changelog/git_email.py: Likewise. * gcc-changelog/git_repository.py: Likewise. * gcc-changelog/git_update_version.py: Likewise. * gcc-changelog/test_email.py: Likewise. * gcc-changelog/test_patches.txt: Likewise. Diff: --- contrib/gcc-changelog/git_check_commit.py | 9 +- contrib/gcc-changelog/git_commit.py | 43 ++- contrib/gcc-changelog/git_email.py | 23 +- contrib/gcc-changelog/git_repository.py | 7 +- contrib/gcc-changelog/git_update_version.py | 9 +- contrib/gcc-changelog/test_email.py | 23 +- contrib/gcc-changelog/test_patches.txt | 430 ++++++++++------------------ 7 files changed, 218 insertions(+), 326 deletions(-) diff --git a/contrib/gcc-changelog/git_check_commit.py b/contrib/gcc-changelog/git_check_commit.py index 935425ef813..9a4c5d448fb 100755 --- a/contrib/gcc-changelog/git_check_commit.py +++ b/contrib/gcc-changelog/git_check_commit.py @@ -23,19 +23,16 @@ from git_repository import parse_git_revisions parser = argparse.ArgumentParser(description='Check git ChangeLog format ' 'of a commit') parser.add_argument('revisions', default='HEAD', nargs='?', - help='Git revisions (e.g. hash~5..hash or just hash)') + help='Git revisions (e.g. hash~5..hash or just hash) - ' + 'if not specified: HEAD') parser.add_argument('-g', '--git-path', default='.', help='Path to git repository') parser.add_argument('-p', '--print-changelog', action='store_true', help='Print final changelog entires') -parser.add_argument('-n', '--non-strict-mode', action='store_true', - help='Use non-strict mode (allow changes in ChangeLog and ' - 'other automatically updated files).') args = parser.parse_args() retval = 0 -for git_commit in parse_git_revisions(args.git_path, args.revisions, - not args.non_strict_mode): +for git_commit in parse_git_revisions(args.git_path, args.revisions): res = 'OK' if git_commit.success else 'FAILED' print('Checking %s: %s' % (git_commit.original_info.hexsha, res)) if git_commit.success: diff --git a/contrib/gcc-changelog/git_commit.py b/contrib/gcc-changelog/git_commit.py index b28f7deac23..4958ab9c159 100755 --- a/contrib/gcc-changelog/git_commit.py +++ b/contrib/gcc-changelog/git_commit.py @@ -19,8 +19,9 @@ import difflib import os import re +import sys -changelog_locations = { +default_changelog_locations = { 'c++tools', 'config', 'contrib', @@ -200,7 +201,7 @@ class Error: def __repr__(self): s = self.message if self.line: - s += ':"%s"' % self.line + s += ': "%s"' % self.line return s @@ -287,7 +288,7 @@ class GitInfo: class GitCommit: - def __init__(self, info, strict=True, commit_to_info_hook=None): + def __init__(self, info, commit_to_info_hook=None, ref_name=None): self.original_info = info self.info = info self.message = None @@ -300,6 +301,7 @@ class GitCommit: self.cherry_pick_commit = None self.revert_commit = None self.commit_to_info_hook = commit_to_info_hook + self.init_changelog_locations(ref_name) # Skip Update copyright years commits if self.info.lines and self.info.lines[0] == 'Update copyright years.': @@ -323,7 +325,7 @@ class GitCommit: if len(project_files) == len(self.info.modified_files): # All modified files are only MISC files return - elif project_files and strict: + elif project_files: self.errors.append(Error('ChangeLog, DATESTAMP, BASE-VER and ' 'DEV-PHASE updates should be done ' 'separately from normal commits')) @@ -361,15 +363,14 @@ class GitCommit: else: return False - @classmethod - def find_changelog_location(cls, name): + def find_changelog_location(self, name): if name.startswith('\t'): name = name[1:] if name.endswith(':'): name = name[:-1] if name.endswith('/'): name = name[:-1] - return name if name in changelog_locations else None + return name if name in self.changelog_locations else None @classmethod def format_git_author(cls, author): @@ -389,6 +390,17 @@ class GitCommit: modified_files.append((parts[2], 'A')) return modified_files + def init_changelog_locations(self, ref_name): + self.changelog_locations = list(default_changelog_locations) + if ref_name: + version = sys.maxsize + if 'releases/gcc-' in ref_name: + version = int(ref_name.split('-')[-1]) + if version >= 12: + # HSA and BRIG were removed in GCC 12 + self.changelog_locations.remove('gcc/brig') + self.changelog_locations.remove('libhsail-rt') + def parse_lines(self, all_are_ignored): body = self.info.lines @@ -397,7 +409,8 @@ class GitCommit: continue if (changelog_regex.match(b) or self.find_changelog_location(b) or star_prefix_regex.match(b) or pr_regex.match(b) - or dr_regex.match(b) or author_line_regex.match(b)): + or dr_regex.match(b) or author_line_regex.match(b) + or b.lower().startswith(CO_AUTHORED_BY_PREFIX)): self.changes = body[i:] return if not all_are_ignored: @@ -586,7 +599,7 @@ class GitCommit: for file in entry.files: location = self.get_file_changelog_location(file) if (location == '' - or (location and location in changelog_locations)): + or (location and location in self.changelog_locations)): if changelog and changelog != location: msg = 'could not deduce ChangeLog file, ' \ 'not unique location' @@ -606,11 +619,10 @@ class GitCommit: return True return False - @classmethod - def get_changelog_by_path(cls, path): + def get_changelog_by_path(self, path): components = path.split('/') while components: - if '/'.join(components) in changelog_locations: + if '/'.join(components) in self.changelog_locations: break components = components[:-1] return '/'.join(components) @@ -629,7 +641,12 @@ class GitCommit: assert not entry.folder.endswith('/') for file in entry.files: if not self.is_changelog_filename(file): - mentioned_files.add(os.path.join(entry.folder, file)) + item = os.path.join(entry.folder, file) + if item in mentioned_files: + msg = 'same file specified multiple times' + self.errors.append(Error(msg, file)) + else: + mentioned_files.add(item) for pattern in entry.file_patterns: mentioned_patterns.append(os.path.join(entry.folder, pattern)) diff --git a/contrib/gcc-changelog/git_email.py b/contrib/gcc-changelog/git_email.py index b0547b363aa..6933e3d71fe 100755 --- a/contrib/gcc-changelog/git_email.py +++ b/contrib/gcc-changelog/git_email.py @@ -32,7 +32,7 @@ unidiff_supports_renaming = hasattr(PatchedFile(), 'is_rename') class GitEmail(GitCommit): - def __init__(self, filename, strict=False): + def __init__(self, filename): self.filename = filename diff = PatchSet.from_filename(filename) date = None @@ -68,14 +68,27 @@ class GitEmail(GitCommit): t = 'M' modified_files.append((target if t != 'D' else source, t)) git_info = GitInfo(None, date, author, body, modified_files) - super().__init__(git_info, strict=strict, + super().__init__(git_info, commit_to_info_hook=lambda x: None) -# With zero arguments, process every patch file in the ./patches directory. -# With one argument, process the named patch file. -# Patch files must be in 'git format-patch' format. +def show_help(): + print("""usage: git_email.py [--help] [patch file ...] + +Check git ChangeLog format of a patch + +With zero arguments, process every patch file in the +./patches directory. +With one argument, process the named patch file. + +Patch files must be in 'git format-patch' format.""") + sys.exit(0) + + if __name__ == '__main__': + if len(sys.argv) == 2 and (sys.argv[1] == '-h' or sys.argv[1] == '--help'): + show_help() + if len(sys.argv) == 1: allfiles = [] for root, _dirs, files in os.walk('patches'): diff --git a/contrib/gcc-changelog/git_repository.py b/contrib/gcc-changelog/git_repository.py index a0e293d756d..2d688826ff8 100755 --- a/contrib/gcc-changelog/git_repository.py +++ b/contrib/gcc-changelog/git_repository.py @@ -29,7 +29,7 @@ except ImportError: from git_commit import GitCommit, GitInfo, decode_path -def parse_git_revisions(repo_path, revisions, strict=True): +def parse_git_revisions(repo_path, revisions, ref_name=None): repo = Repo(repo_path) def commit_to_info(commit): @@ -72,7 +72,8 @@ def parse_git_revisions(repo_path, revisions, strict=True): commits = [repo.commit(revisions)] for commit in commits: - git_commit = GitCommit(commit_to_info(commit.hexsha), strict=strict, - commit_to_info_hook=commit_to_info) + git_commit = GitCommit(commit_to_info(commit.hexsha), + commit_to_info_hook=commit_to_info, + ref_name=ref_name) parsed_commits.append(git_commit) return parsed_commits diff --git a/contrib/gcc-changelog/git_update_version.py b/contrib/gcc-changelog/git_update_version.py index 1e2b22b008b..0508f194084 100755 --- a/contrib/gcc-changelog/git_update_version.py +++ b/contrib/gcc-changelog/git_update_version.py @@ -57,7 +57,8 @@ def prepend_to_changelog_files(repo, folder, git_commit, add_to_git): repo.git.add(full_path) -active_refs = ['master', 'releases/gcc-8', 'releases/gcc-9', 'releases/gcc-10'] +active_refs = ['master', 'releases/gcc-9', 'releases/gcc-10', + 'releases/gcc-11'] parser = argparse.ArgumentParser(description='Update DATESTAMP and generate ' 'ChangeLog entries') @@ -77,7 +78,7 @@ repo = Repo(args.git_path) origin = repo.remotes['origin'] -def update_current_branch(): +def update_current_branch(ref_name): commit = repo.head.commit commit_count = 1 while commit: @@ -100,7 +101,7 @@ def update_current_branch(): if len(head.parents) == 2: head = head.parents[1] commits = parse_git_revisions(args.git_path, '%s..%s' - % (commit.hexsha, head.hexsha)) + % (commit.hexsha, head.hexsha), ref_name) commits = [c for c in commits if c.info.hexsha not in IGNORED_COMMITS] for git_commit in reversed(commits): prepend_to_changelog_files(repo, args.git_path, git_commit, @@ -144,6 +145,6 @@ else: branch.checkout() origin.pull(rebase=True) print('branch pulled and checked out') - update_current_branch() + update_current_branch(name) assert not repo.index.diff(None) print('branch is done\n', flush=True) diff --git a/contrib/gcc-changelog/test_email.py b/contrib/gcc-changelog/test_email.py index 8abf5c37487..7472762e66d 100755 --- a/contrib/gcc-changelog/test_email.py +++ b/contrib/gcc-changelog/test_email.py @@ -62,17 +62,17 @@ class TestGccChangelog(unittest.TestCase): assert t.endswith('.patch') os.remove(t) - def get_git_email(self, filename, strict=False): + def get_git_email(self, filename): with tempfile.NamedTemporaryFile(mode='w+', suffix='.patch', delete=False) as f: f.write('\n'.join(self.patches[filename])) self.temps.append(f.name) - return GitEmail(f.name, strict) + return GitEmail(f.name) - def from_patch_glob(self, name, strict=False): + def from_patch_glob(self, name): files = [f for f in self.patches.keys() if f.startswith(name)] assert len(files) == 1 - return self.get_git_email(files[0], strict) + return self.get_git_email(files[0]) def test_simple_patch_format(self): email = self.get_git_email('0577-aarch64-Add-an-and.patch') @@ -247,7 +247,7 @@ class TestGccChangelog(unittest.TestCase): assert email.changelog_entries[1].prs == [] def test_multiple_prs_not_added(self): - email = self.from_patch_glob('0001-Add-patch_are') + email = self.from_patch_glob('0002-Add-patch_are') assert not email.errors assert email.changelog_entries[0].prs == ['PR target/93492'] assert email.changelog_entries[1].prs == ['PR target/12345'] @@ -255,18 +255,17 @@ class TestGccChangelog(unittest.TestCase): assert email.changelog_entries[2].folder == 'gcc/testsuite' def test_strict_mode(self): - email = self.from_patch_glob('0001-Add-patch_are', - True) + email = self.from_patch_glob('0001-Add-patch_are') msg = 'ChangeLog, DATESTAMP, BASE-VER and DEV-PHASE updates should ' \ 'be done separately from normal commits' assert email.errors[0].message == msg def test_strict_mode_normal_patch(self): - email = self.get_git_email('0001-Just-test-it.patch', True) + email = self.get_git_email('0001-Just-test-it.patch') assert not email.errors def test_strict_mode_datestamp_only(self): - email = self.get_git_email('0002-Bump-date.patch', True) + email = self.get_git_email('0002-Bump-date.patch') assert not email.errors def test_wrong_changelog_entry(self): @@ -418,9 +417,13 @@ class TestGccChangelog(unittest.TestCase): assert email.errors[0].message == 'bad parentheses wrapping' def test_changelog_removal(self): - email = self.from_patch_glob('0001-ChangeLog-removal.patch', strict=True) + email = self.from_patch_glob('0001-ChangeLog-removal.patch') assert not email.errors def test_long_filenames(self): email = self.from_patch_glob('0001-long-filenames') assert not email.errors + + def test_multi_same_file(self): + email = self.from_patch_glob('0001-OpenMP-Fix-SIMT') + assert email.errors[0].message == 'same file specified multiple times' diff --git a/contrib/gcc-changelog/test_patches.txt b/contrib/gcc-changelog/test_patches.txt index 3f9806dc076..39d40b88618 100644 --- a/contrib/gcc-changelog/test_patches.txt +++ b/contrib/gcc-changelog/test_patches.txt @@ -68,13 +68,6 @@ xxxx-xx-xx Claudiu Zissulescu create mode 100644 gcc/testsuite/gcc.target/arc/uncached-7.c create mode 100644 gcc/testsuite/gcc.target/arc/uncached-8.c -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 91dfcd71a4b..2cc61d68cf3 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c index 22475f2732e..e1a865f02e6 100644 --- a/gcc/config/arc/arc.c @@ -88,13 +81,6 @@ index cf7aa8d83c9..46cb254ed28 100644 +++ b/gcc/config/arc/arc.md @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 16ddef07516..991934272e0 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/gcc.target/arc/arc.exp b/gcc/testsuite/gcc.target/arc/arc.exp index 8d1844edd22..501d4589c53 100644 @@ -199,20 +185,6 @@ without any data fields. 4 files changed, 36 insertions(+) create mode 100644 gcc/testsuite/g++.dg/tree-ssa/pr93667.C -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 77c2a9ad810..6b53f9a2f07 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 9b4fe11a6f6..8033fa0a3bb 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/testsuite/g++.dg/tree-ssa/pr93667.C b/gcc/testsuite/g++.dg/tree-ssa/pr93667.C new file mode 100644 index 00000000000..d875f53d9ec @@ -275,20 +247,6 @@ Subject: [PATCH 0413/2034] SRA: Total scalarization after access propagation 5 files changed, 537 insertions(+), 184 deletions(-) create mode 100644 gcc/testsuite/gcc.dg/tree-ssa/pr92706-2.c -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 16247a59304..61da54df346 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 05518848829..38758207989 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/testsuite/gcc.dg/guality/pr59776.c b/gcc/testsuite/gcc.dg/guality/pr59776.c index 382abb622bb..6c1c8165b70 100644 --- a/gcc/testsuite/gcc.dg/guality/pr59776.c @@ -333,26 +291,12 @@ Subject: [PATCH 0334/2034] Do not generate a unique fnname for resolver. gcc/testsuite/gcc.target/i386/pr81213.c | 4 ++-- 4 files changed, 19 insertions(+), 17 deletions(-) -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 45075840824..59806baa757 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/config/i386/i386-features.c b/gcc/config/i386/i386-features.c index e580b26b995..b49e6f8d408 100644 --- a/gcc/config/i386/i386-features.c +++ b/gcc/config/i386/i386-features.c @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 2de060843d9..22a37dd1ab2 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/gcc.target/i386/pr81213.c b/gcc/testsuite/gcc.target/i386/pr81213.c index 13e15d5fef0..89c47529861 100644 @@ -396,26 +340,12 @@ Co-Authored-By: Jakub Jelinek 8 files changed, 142 insertions(+), 22 deletions(-) create mode 100644 gcc/testsuite/g++.dg/pr94314-4.C -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 74dbeeb44c6..9e499ec9c86 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/cgraphclones.c b/gcc/cgraphclones.c index c73b8f810f0..8f541a28b6e 100644 --- a/gcc/cgraphclones.c +++ b/gcc/cgraphclones.c @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 756f1d759e6..94d2312022d 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/g++.dg/pr94314-2.C b/gcc/testsuite/g++.dg/pr94314-2.C index 36b93ed6d4d..998ce601767 100644 @@ -492,13 +422,6 @@ https://gcc.gnu.org/ml/gcc-patches/2020-01/msg00809.html 3 files changed, 24 insertions(+), 5 deletions(-) create mode 100644 gcc/testsuite/g++.dg/template/pr90916.C -diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog -index 004ce0fdcdf..3cc7c48b490 100644 ---- a/gcc/cp/ChangeLog -+++ b/gcc/cp/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index fa82ecad233..4fdc74f9ca8 100644 --- a/gcc/cp/pt.c @@ -539,13 +462,6 @@ not broken, but this is both safer and satisfies static analysis. libgomp/plugin/plugin-gcn.c | 8 ++++++++ 2 files changed, 17 insertions(+) -diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog -index c524abbbfb6..ee1764d4ae3 100644 ---- a/libgomp/ChangeLog -+++ b/libgomp/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/libgomp/plugin/plugin-gcn.c b/libgomp/plugin/plugin-gcn.c index dc72c90962c..4c6a4c03b6e 100644 --- a/libgomp/plugin/plugin-gcn.c @@ -578,13 +494,6 @@ ChangeLog: gcc/tree-into-ssa.c | 59 ++++++++++++++++++++++++++++++++++++--------- 2 files changed, 55 insertions(+), 12 deletions(-) -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 8c17e5992d2..262f0d6506f 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/tree-into-ssa.c b/gcc/tree-into-ssa.c index c27bf2ce121..6528acac31a 100644 --- a/gcc/tree-into-ssa.c @@ -683,26 +592,12 @@ just the C-family ones that defined a forwarding macro. 17 files changed, 146 insertions(+), 95 deletions(-) create mode 100644 gcc/testsuite/g++.dg/cpp/pr80005.C -diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog -index 09ba2c8b40f..fdddb98a74d 100644 ---- a/gcc/c-family/ChangeLog -+++ b/gcc/c-family/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/c-family/c-cppbuiltin.c b/gcc/c-family/c-cppbuiltin.c index a6308921dc9..70a12055e27 100644 --- a/gcc/c-family/c-cppbuiltin.c +++ b/gcc/c-family/c-cppbuiltin.c @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index a526e32ac89..67d5f2e9e28 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/g++.dg/cpp/pr80005.C b/gcc/testsuite/g++.dg/cpp/pr80005.C new file mode 100644 @@ -731,13 +626,6 @@ index dd15cd6af3c..82fd602f9f1 100644 +++ b/gcc/testsuite/g++.dg/cpp2a/feat-cxx2a.C @@ -1 +1,2 @@ -+ -diff --git a/libcpp/ChangeLog b/libcpp/ChangeLog -index 3249b93fe88..27a841bbdce 100644 ---- a/libcpp/ChangeLog -+++ b/libcpp/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/libcpp/directives.c b/libcpp/directives.c index 983206a5838..10735c8c668 100644 @@ -825,13 +713,6 @@ Subject: [PATCH 0004/2034] tree-opt: Fix bootstrap failure in gcc/tree-ssa-forwprop.c | 6 +++--- 2 files changed, 12 insertions(+), 3 deletions(-) -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index a195863212e..f7df07343d1 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/tree-ssa-forwprop.c b/gcc/tree-ssa-forwprop.c index aac31d02b6c..56c470f6ecf 100644 --- a/gcc/tree-ssa-forwprop.c @@ -898,13 +779,6 @@ Subject: [PATCH 0735/2034] PR 87488: Add --with-diagnostics-urls configuration gcc/pretty-print.h | 5 +- 11 files changed, 328 insertions(+), 26 deletions(-) -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index e6eb6ab4c21..22f990a3088 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/config.in b/gcc/config.in index 48292861842..01fb18dbbb5 100644 --- a/gcc/config.in @@ -1000,13 +874,6 @@ gcc/ChangeLog gcc/cfgloopanal.c | 5 ++++- 2 files changed, 9 insertions(+), 1 deletion(-) -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 07e5bebe909..f3301b16464 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/cfgloopanal.c b/gcc/cfgloopanal.c index 392b1c337c4..0b33e8272a7 100644 --- a/gcc/cfgloopanal.c @@ -1073,13 +940,6 @@ Subject: [PATCH 0735/2034] PR 87488: Add --with-diagnostics-urls configuration gcc/pretty-print.h | 5 +- 11 files changed, 328 insertions(+), 26 deletions(-) -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index e6eb6ab4c21..22f990a3088 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/config.in b/gcc/config.in index 48292861842..01fb18dbbb5 100644 --- a/gcc/config.in @@ -1187,26 +1047,12 @@ co-authored-by: John Miller2 8 files changed, 142 insertions(+), 22 deletions(-) create mode 100644 gcc/testsuite/g++.dg/pr94314-4.C -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 74dbeeb44c6..9e499ec9c86 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/cgraphclones.c b/gcc/cgraphclones.c index c73b8f810f0..8f541a28b6e 100644 --- a/gcc/cgraphclones.c +++ b/gcc/cgraphclones.c @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 756f1d759e6..94d2312022d 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/g++.dg/pr94314-2.C b/gcc/testsuite/g++.dg/pr94314-2.C index 36b93ed6d4d..998ce601767 100644 @@ -1299,26 +1145,12 @@ if it isn't a REG or SUBREG of REG. 4 files changed, 51 insertions(+), 19 deletions(-) create mode 100644 gcc/testsuite/gcc.dg/pr94291.c -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index a1ab9fb4ef3..12803e90b0a 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/combine.c b/gcc/combine.c index 58366a6d331..cff76cd3303 100644 --- a/gcc/combine.c +++ b/gcc/combine.c @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 71b5a14bcbe..3cbf891d58d 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/gcc.dg/pr94291.c b/gcc/testsuite/gcc.dg/pr94291.c new file mode 100644 @@ -1389,13 +1221,6 @@ index e85a8e8813e..fb776ba5a0e 100644 +++ b/gcc/ChangeLog @@ -1 +1,2 @@ -+ -diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog -index c429b49e68c..69ea1fdc4f3 100644 ---- a/gcc/c-family/ChangeLog -+++ b/gcc/c-family/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/c-family/c-attribs.c b/gcc/c-family/c-attribs.c index ac936d5bbbb..a101312c581 100644 @@ -1432,10 +1257,122 @@ index c212a1a57dc..3dccef39701 100644 @@ -1 +1,2 @@ + -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 176aa117904..185f9ea725e 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog +diff --git a/gcc/testsuite/c-c++-common/patchable_function_entry-error-1.c b/gcc/testsuite/c-c++-common/patchable_function_entry-error-1.c +new file mode 100644 +index 00000000000..f60bf46cfe3 +--- /dev/null ++++ b/gcc/testsuite/c-c++-common/patchable_function_entry-error-1.c +@@ -0,0 +1 @@ ++ +diff --git a/gcc/testsuite/c-c++-common/patchable_function_entry-error-2.c b/gcc/testsuite/c-c++-common/patchable_function_entry-error-2.c +new file mode 100644 +index 00000000000..90f88c78be7 +--- /dev/null ++++ b/gcc/testsuite/c-c++-common/patchable_function_entry-error-2.c +@@ -0,0 +1 @@ ++ +diff --git a/gcc/testsuite/c-c++-common/patchable_function_entry-error-3.c b/gcc/testsuite/c-c++-common/patchable_function_entry-error-3.c +new file mode 100644 +index 00000000000..4490e5c15ca +--- /dev/null ++++ b/gcc/testsuite/c-c++-common/patchable_function_entry-error-3.c +@@ -0,0 +1 @@ ++ +diff --git a/gcc/varasm.c b/gcc/varasm.c +index 271a67abf56..f062e48071f 100644 +--- a/gcc/varasm.c ++++ b/gcc/varasm.c +@@ -1 +1,2 @@ + ++ +-- +2.26.2 + +=== 0002-Add-patch_area_size-and-patch_area_entry-to-crtl.patch === +From 6607bdd99994c834f92fce924abdaea3405f62dc Mon Sep 17 00:00:00 2001 +From: "H.J. Lu" +Date: Fri, 1 May 2020 21:03:10 -0700 +Subject: [PATCH] Add patch_area_size and patch_area_entry to crtl + +Currently patchable area is at the wrong place. It is placed immediately +after function label and before .cfi_startproc. A backend should be able +to add a pseudo patchable area instruction durectly into RTL. This patch +adds patch_area_size and patch_area_entry to crtl so that the patchable +area info is available in RTL passes. + +It also limits patch_area_size and patch_area_entry to 65535, which is +a reasonable maximum size for patchable area. + +gcc/ + + PR target/93492 + * cfgexpand.c (pass_expand::execute): Set crtl->patch_area_size + and crtl->patch_area_entry. + * emit-rtl.h (rtl_data): Add patch_area_size and patch_area_entry. + * opts.c (common_handle_option): Limit + function_entry_patch_area_size and function_entry_patch_area_start + to USHRT_MAX. Fix a typo in error message. + * varasm.c (assemble_start_function): Use crtl->patch_area_size + and crtl->patch_area_entry. + * doc/invoke.texi: Document the maximum value for + -fpatchable-function-entry. + +gcc/c-family/ + + PR target/12345 + * c-attribs.c (handle_patchable_function_entry_attribute): Limit + value to USHRT_MAX (65535). + +--- + gcc/ChangeLog | 14 ++++++++ + gcc/c-family/ChangeLog | 6 ++++ + gcc/c-family/c-attribs.c | 9 +++++ + gcc/cfgexpand.c | 33 +++++++++++++++++++ + gcc/doc/invoke.texi | 1 + + gcc/emit-rtl.h | 6 ++++ + gcc/opts.c | 4 ++- + gcc/testsuite/ChangeLog | 7 ++++ + .../patchable_function_entry-error-1.c | 9 +++++ + .../patchable_function_entry-error-2.c | 9 +++++ + .../patchable_function_entry-error-3.c | 17 ++++++++++ + gcc/varasm.c | 30 ++--------------- + 12 files changed, 116 insertions(+), 29 deletions(-) + create mode 100644 gcc/testsuite/c-c++-common/patchable_function_entry-error-1.c + create mode 100644 gcc/testsuite/c-c++-common/patchable_function_entry-error-2.c + create mode 100644 gcc/testsuite/c-c++-common/patchable_function_entry-error-3.c + +diff --git a/gcc/c-family/c-attribs.c b/gcc/c-family/c-attribs.c +index ac936d5bbbb..a101312c581 100644 +--- a/gcc/c-family/c-attribs.c ++++ b/gcc/c-family/c-attribs.c +@@ -1 +1,2 @@ + ++ +diff --git a/gcc/cfgexpand.c b/gcc/cfgexpand.c +index a7ec77d5c85..86efa22bf60 100644 +--- a/gcc/cfgexpand.c ++++ b/gcc/cfgexpand.c +@@ -1 +1,2 @@ + ++ +diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi +index 527d362533a..767d1f07801 100644 +--- a/gcc/doc/invoke.texi ++++ b/gcc/doc/invoke.texi +@@ -1 +1,2 @@ + ++ +diff --git a/gcc/emit-rtl.h b/gcc/emit-rtl.h +index a878efe3cf7..3d6565c8a30 100644 +--- a/gcc/emit-rtl.h ++++ b/gcc/emit-rtl.h +@@ -1 +1,2 @@ + ++ +diff --git a/gcc/opts.c b/gcc/opts.c +index c212a1a57dc..3dccef39701 100644 +--- a/gcc/opts.c ++++ b/gcc/opts.c @@ -1 +1,2 @@ + @@ -1497,13 +1434,6 @@ gcc/cp/ChangeLog 3 files changed, 40 insertions(+), 18 deletions(-) create mode 100644 gcc/testsuite/g++.dg/cpp2a/lambda-generic-variadic20.C -diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog -index 640e4948130..4b6691a77f0 100644 ---- a/gcc/cp/ChangeLog -+++ b/gcc/cp/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index 7bf249cee5c..2fe7b66707c 100644 --- a/gcc/cp/pt.c @@ -1539,13 +1469,6 @@ concepts. 3 files changed, 11 insertions(+) create mode 100644 gcc/testsuite/g++.dg/concepts/fn-concept3.C -diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog -index 59646c70fa4..4729e3d331d 100644 ---- a/gcc/cp/ChangeLog -+++ b/gcc/cp/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/cp/except.c b/gcc/cp/except.c index e073bd4d2bc..55b4b6af442 100644 --- a/gcc/cp/except.c @@ -1573,13 +1496,6 @@ Subject: [PATCH 0129/2034] Add PR number to change log gcc/ChangeLog | 1 + 1 file changed, 1 insertion(+) -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 6c6d586ca75..49ca5f92dec 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ -- 2.26.1 @@ -1616,13 +1532,6 @@ gcc/testsuite/ 6 files changed, 132 insertions(+) create mode 100644 gcc/testsuite/gcc.target/aarch64/movk_2.c -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index efbbbf08225..cea8ffee99c 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/config/aarch64/aarch64-protos.h b/gcc/config/aarch64/aarch64-protos.h index 24cc65a383a..d29975a8921 100644 --- a/gcc/config/aarch64/aarch64-protos.h @@ -1643,13 +1552,6 @@ index 90eebce85c0..9c1f17d0f85 100644 +++ b/gcc/config/aarch64/aarch64.md @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 601bc336290..cdb26581b9c 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/gcc.target/aarch64/movk_2.c b/gcc/testsuite/gcc.target/aarch64/movk_2.c new file mode 100644 @@ -1836,26 +1738,12 @@ already). gcc/testsuite/g++.dg/tree-ssa/pr27830.C | 2 ++ 4 files changed, 47 insertions(+), 5 deletions(-) -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 06f7eda0033..93c3076eb86 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/config/rs6000/rs6000-call.c b/gcc/config/rs6000/rs6000-call.c index e08621ace27..a9ae7ab70ca 100644 --- a/gcc/config/rs6000/rs6000-call.c +++ b/gcc/config/rs6000/rs6000-call.c @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 684e408c1a5..245c1512c76 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/g++.dg/tree-ssa/pr27830.C b/gcc/testsuite/g++.dg/tree-ssa/pr27830.C index 01c7fc18783..551ebc428cd 100644 @@ -1968,13 +1856,6 @@ index c212a1a57dc..3dccef39701 100644 +++ b/gcc/opts.c @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 176aa117904..185f9ea725e 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/c-c++-common/patchable_function_entry-error-1.c b/gcc/testsuite/c-c++-common/patchable_function_entry-error-1.c new file mode 100644 @@ -2082,13 +1963,6 @@ Subject: [PATCH 0004/2034] tree-opt: Fix bootstrap failure in gcc/tree-ssa-forwprop.c | 6 +++--- 2 files changed, 12 insertions(+), 3 deletions(-) -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index a195863212e..f7df07343d1 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/tree-ssa-forwprop.c b/gcc/tree-ssa-forwprop.c index aac31d02b6c..56c470f6ecf 100644 --- a/gcc/tree-ssa-forwprop.c @@ -2125,13 +1999,6 @@ gcc/testsuite/ChangeLog: 3 files changed, 89 insertions(+), 7 deletions(-) create mode 100644 gcc/testsuite/g++.dg/ext/is_constructible4.C -diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog -index 3ca5d7a11b4..c37e461bcc5 100644 ---- a/gcc/cp/ChangeLog -+++ b/gcc/cp/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index 9bb8cc13e5f..872f8ff8f52 100644 --- a/gcc/cp/pt.c @@ -2210,26 +2077,12 @@ Subject: [PATCH 0043/2034] Compare TREE_ADDRESSABLE and TYPE_MODE when ODR create mode 100644 gcc/testsuite/g++.dg/lto/odr-8_0.C create mode 100644 gcc/testsuite/g++.dg/lto/odr-8_1.C -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 38165123654..33ca91a6467 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/ipa-devirt.c b/gcc/ipa-devirt.c index f0031957375..b609a77701d 100644 --- a/gcc/ipa-devirt.c +++ b/gcc/ipa-devirt.c @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 8e3b9105188..dc42601794b 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/g++.dg/lto/odr-8_0.C b/gcc/testsuite/g++.dg/lto/odr-8_0.C new file mode 100644 @@ -2302,13 +2155,6 @@ gcc/testsuite/ChangeLog: create mode 100755 gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/vdot-3-3.c create mode 100755 gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/vdot-3-4.c -diff --git a/gcc/ChangeLog b/gcc/ChangeLog -index 9a949980699..49dcecb6777 100644 ---- a/gcc/ChangeLog -+++ b/gcc/ChangeLog -@@ -1 +1,2 @@ - -+ diff --git a/gcc/config/aarch64/aarch64-builtins.c b/gcc/config/aarch64/aarch64-builtins.c index f0e0461b7f0..f50c4857e1c 100644 --- a/gcc/config/aarch64/aarch64-builtins.c @@ -2343,13 +2189,6 @@ index b9843b83c5f..83720d9802a 100644 +++ b/gcc/config/aarch64/iterators.md @@ -1 +1,2 @@ -+ -diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog -index 0d8aa6063a7..8b01aa06a40 100644 ---- a/gcc/testsuite/ChangeLog -+++ b/gcc/testsuite/ChangeLog -@@ -1 +1,2 @@ - + diff --git a/gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/vdot-3-1.c b/gcc/testsuite/gcc.target/aarch64/advsimd-intrinsics/vdot-3-1.c new file mode 100755 @@ -3408,14 +3247,6 @@ Subject: [PATCH] Fix a changelog. gcc/ChangeLog-2020 | 1 + 1 file changed, 1 insertion(+) -diff --git a/gcc/ChangeLog-2020 b/gcc/ChangeLog-2020 -index 6553720acad..2c170ef014a 100644 ---- a/gcc/ChangeLog-2020 -+++ b/gcc/ChangeLog-2020 -@@ -1 +1,2 @@ - -+ - -- 2.29.2 === 0001-Add-macro.patch === @@ -3546,3 +3377,32 @@ index 5ad82db1def..53b15f32516 100644 @@ -1 +1,2 @@ + + +=== 0001-OpenMP-Fix-SIMT === +From 33b647956caa977d1ae489f9baed9cef70b4f382 Mon Sep 17 00:00:00 2001 +From: Tobias Burnus +Date: Fri, 7 May 2021 12:11:51 +0200 +Subject: [PATCH] OpenMP: Fix SIMT for complex/float reduction with && and || + +libgomp/ChangeLog: + + * testsuite/libgomp.c-c++-common/reduction-5.c: New test, testing + complex/floating-point || + && reduction with 'omp target'. + * testsuite/libgomp.c-c++-common/reduction-5.c: Likewise. +--- +diff --git a/libgomp/testsuite/libgomp.c-c++-common/reduction-5.c b/libgomp/testsuite/libgomp.c-c++-common/reduction-5.c +new file mode 100644 +index 00000000000..21540512e23 +--- /dev/null ++++ b/libgomp/testsuite/libgomp.c-c++-common/reduction-5.c +@@ -0,0 +1,1 @@ ++ +diff --git a/libgomp/testsuite/libgomp.c-c++-common/reduction-6.c b/libgomp/testsuite/libgomp.c-c++-common/reduction-6.c +new file mode 100644 +index 00000000000..21540512e23 +--- /dev/null ++++ b/libgomp/testsuite/libgomp.c-c++-common/reduction-6.c +@@ -0,0 +1,1 @@ ++ +-- +2.25.1