forked from devyte/esp-quick-toolchain
-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GCC: xtensa: backport patch from upstream #31
Merged
earlephilhower
merged 4 commits into
earlephilhower:master
from
jjsuwa-sys3175:from_upstream
Nov 27, 2021
Merged
Changes from 3 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
6468f61
patches: Make keep the order of some patches applied
jjsuwa-sys3175 ed86506
GCC: xtensa: backport patch from upstream
jjsuwa-sys3175 0b97526
Makefile: Add GCC config options to `--enable-checking=all`
jjsuwa-sys3175 7a464ef
Revert "Makefile: Add GCC config options to `--enable-checking=all`"
jjsuwa-sys3175 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
29 changes: 29 additions & 0 deletions
29
patches/gcc10.1/gcc-xtensa-0005-fix-PR-target-102115.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
From b552c4e601c7fdc4d341e29cc1ed6081d42b00d0 Mon Sep 17 00:00:00 2001 | ||
From: Max Filippov <jcmvbkbc@gmail.com> | ||
Date: Tue, 7 Sep 2021 15:40:00 -0700 | ||
Subject: [PATCH] gcc: xtensa: fix PR target/102115 | ||
|
||
2021-09-07 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp> | ||
gcc/ | ||
PR target/102115 | ||
* config/xtensa/xtensa.c (xtensa_emit_move_sequence): Add | ||
'CONST_INT_P (src)' to the condition of the block that tries to | ||
eliminate literal when loading integer contant. | ||
--- | ||
gcc/config/xtensa/xtensa.c | 3 ++- | ||
1 file changed, 2 insertions(+), 1 deletion(-) | ||
|
||
diff --git a/gcc/config/xtensa/xtensa.c b/gcc/config/xtensa/xtensa.c | ||
index f4f8f1975c55a..8d6755144c120 100644 | ||
--- a/gcc/config/xtensa/xtensa.c | ||
+++ b/gcc/config/xtensa/xtensa.c | ||
@@ -1084,7 +1084,8 @@ xtensa_emit_move_sequence (rtx *operands, machine_mode mode) | ||
{ | ||
/* Try to emit MOVI + SLLI sequence, that is smaller | ||
than L32R + literal. */ | ||
- if (optimize_size && mode == SImode && register_operand (dst, mode)) | ||
+ if (optimize_size && mode == SImode && CONST_INT_P (src) | ||
+ && register_operand (dst, mode)) | ||
{ | ||
HOST_WIDE_INT srcval = INTVAL (src); | ||
int shift = ctz_hwi (srcval); |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
29 changes: 29 additions & 0 deletions
29
patches/gcc10.2/gcc-xtensa-0005-fix-PR-target-102115.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
From b552c4e601c7fdc4d341e29cc1ed6081d42b00d0 Mon Sep 17 00:00:00 2001 | ||
From: Max Filippov <jcmvbkbc@gmail.com> | ||
Date: Tue, 7 Sep 2021 15:40:00 -0700 | ||
Subject: [PATCH] gcc: xtensa: fix PR target/102115 | ||
|
||
2021-09-07 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp> | ||
gcc/ | ||
PR target/102115 | ||
* config/xtensa/xtensa.c (xtensa_emit_move_sequence): Add | ||
'CONST_INT_P (src)' to the condition of the block that tries to | ||
eliminate literal when loading integer contant. | ||
--- | ||
gcc/config/xtensa/xtensa.c | 3 ++- | ||
1 file changed, 2 insertions(+), 1 deletion(-) | ||
|
||
diff --git a/gcc/config/xtensa/xtensa.c b/gcc/config/xtensa/xtensa.c | ||
index f4f8f1975c55a..8d6755144c120 100644 | ||
--- a/gcc/config/xtensa/xtensa.c | ||
+++ b/gcc/config/xtensa/xtensa.c | ||
@@ -1084,7 +1084,8 @@ xtensa_emit_move_sequence (rtx *operands, machine_mode mode) | ||
{ | ||
/* Try to emit MOVI + SLLI sequence, that is smaller | ||
than L32R + literal. */ | ||
- if (optimize_size && mode == SImode && register_operand (dst, mode)) | ||
+ if (optimize_size && mode == SImode && CONST_INT_P (src) | ||
+ && register_operand (dst, mode)) | ||
{ | ||
HOST_WIDE_INT srcval = INTVAL (src); | ||
int shift = ctz_hwi (srcval); |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
29 changes: 29 additions & 0 deletions
29
patches/gcc10.3/gcc-xtensa-0005-fix-PR-target-102115.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
From b552c4e601c7fdc4d341e29cc1ed6081d42b00d0 Mon Sep 17 00:00:00 2001 | ||
From: Max Filippov <jcmvbkbc@gmail.com> | ||
Date: Tue, 7 Sep 2021 15:40:00 -0700 | ||
Subject: [PATCH] gcc: xtensa: fix PR target/102115 | ||
|
||
2021-09-07 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp> | ||
gcc/ | ||
PR target/102115 | ||
* config/xtensa/xtensa.c (xtensa_emit_move_sequence): Add | ||
'CONST_INT_P (src)' to the condition of the block that tries to | ||
eliminate literal when loading integer contant. | ||
--- | ||
gcc/config/xtensa/xtensa.c | 3 ++- | ||
1 file changed, 2 insertions(+), 1 deletion(-) | ||
|
||
diff --git a/gcc/config/xtensa/xtensa.c b/gcc/config/xtensa/xtensa.c | ||
index f4f8f1975c55a..8d6755144c120 100644 | ||
--- a/gcc/config/xtensa/xtensa.c | ||
+++ b/gcc/config/xtensa/xtensa.c | ||
@@ -1084,7 +1084,8 @@ xtensa_emit_move_sequence (rtx *operands, machine_mode mode) | ||
{ | ||
/* Try to emit MOVI + SLLI sequence, that is smaller | ||
than L32R + literal. */ | ||
- if (optimize_size && mode == SImode && register_operand (dst, mode)) | ||
+ if (optimize_size && mode == SImode && CONST_INT_P (src) | ||
+ && register_operand (dst, mode)) | ||
{ | ||
HOST_WIDE_INT srcval = INTVAL (src); | ||
int shift = ctz_hwi (srcval); |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
29 changes: 29 additions & 0 deletions
29
patches/gcc11.1/gcc-xtensa-0005-fix-PR-target-102115.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
From b552c4e601c7fdc4d341e29cc1ed6081d42b00d0 Mon Sep 17 00:00:00 2001 | ||
From: Max Filippov <jcmvbkbc@gmail.com> | ||
Date: Tue, 7 Sep 2021 15:40:00 -0700 | ||
Subject: [PATCH] gcc: xtensa: fix PR target/102115 | ||
|
||
2021-09-07 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp> | ||
gcc/ | ||
PR target/102115 | ||
* config/xtensa/xtensa.c (xtensa_emit_move_sequence): Add | ||
'CONST_INT_P (src)' to the condition of the block that tries to | ||
eliminate literal when loading integer contant. | ||
--- | ||
gcc/config/xtensa/xtensa.c | 3 ++- | ||
1 file changed, 2 insertions(+), 1 deletion(-) | ||
|
||
diff --git a/gcc/config/xtensa/xtensa.c b/gcc/config/xtensa/xtensa.c | ||
index f4f8f1975c55a..8d6755144c120 100644 | ||
--- a/gcc/config/xtensa/xtensa.c | ||
+++ b/gcc/config/xtensa/xtensa.c | ||
@@ -1084,7 +1084,8 @@ xtensa_emit_move_sequence (rtx *operands, machine_mode mode) | ||
{ | ||
/* Try to emit MOVI + SLLI sequence, that is smaller | ||
than L32R + literal. */ | ||
- if (optimize_size && mode == SImode && register_operand (dst, mode)) | ||
+ if (optimize_size && mode == SImode && CONST_INT_P (src) | ||
+ && register_operand (dst, mode)) | ||
{ | ||
HOST_WIDE_INT srcval = INTVAL (src); | ||
int shift = ctz_hwi (srcval); |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That makes sense for the gcc development, but may degrade compiler performance for the end users.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's just testing purpose and will be reverted