public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/102852] New: [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b
@ 2021-10-20 6:27 marxin at gcc dot gnu.org
2021-10-20 6:27 ` [Bug tree-optimization/102852] " marxin at gcc dot gnu.org
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-10-20 6:27 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102852
Bug ID: 102852
Summary: [12 Regression] Compile time hog since
r12-4421-g0bd68793921ecf3b
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Keywords: compile-time-hog
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: marxin at gcc dot gnu.org
CC: aldyh at gcc dot gnu.org
Target Milestone: ---
The following test-case is reduced from gnulib testsuite:
$ cat 1.c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
char vasnprintf_resultbuf, vasnprintf_format_buf;
char *vasnprintf_format_result;
size_t xmax();
typedef enum {
TYPE_SCHAR,
TYPE_ULONGLONGINT,
TYPE_DOUBLE,
TYPE_WIDE_CHAR,
TYPE_WIDE_STRING
} arg_type;
void vasnprintf_format() {
int *a_0;
arg_type a_0_0_0;
size_t dp_3;
size_t length;
for (;;) {
int prefix_count, count;
size_t maxlen;
switch (a_0_0_0) {
case TYPE_SCHAR:
switch (prefix_count) {
case 1:
break;
case 2:
snprintf(0, maxlen, &vasnprintf_format_buf);
break;
default:
abort();
}
case TYPE_ULONGLONGINT:
a_0[dp_3];
case TYPE_DOUBLE:
a_0[dp_3];
case TYPE_WIDE_CHAR:
switch (prefix_count)
case 2:
snprintf(0, maxlen, &vasnprintf_format_buf, &count);
case TYPE_WIDE_STRING:
size_t n = xmax();
if (n) {
char *memory;
if (vasnprintf_format_result)
memory = malloc(0);
if (vasnprintf_resultbuf && length)
memcpy(memory, vasnprintf_format_result, length);
}
}
}
}
$ time gcc-11 1.c -O3 -c
real 0m0.073s
user 0m0.034s
sys 0m0.022s
$ time gcc 1.c -O3 -c
real 0m3.272s
user 0m3.245s
sys 0m0.027s
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/102852] [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b
2021-10-20 6:27 [Bug tree-optimization/102852] New: [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b marxin at gcc dot gnu.org
@ 2021-10-20 6:27 ` marxin at gcc dot gnu.org
2021-10-20 6:38 ` aldyh at gcc dot gnu.org
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-10-20 6:27 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102852
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Known to work| |11.2.0
CC| |amacleod at redhat dot com
Ever confirmed|0 |1
Known to fail| |12.0
Priority|P3 |P1
Last reconfirmed| |2021-10-20
Target Milestone|--- |12.0
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/102852] [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b
2021-10-20 6:27 [Bug tree-optimization/102852] New: [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b marxin at gcc dot gnu.org
2021-10-20 6:27 ` [Bug tree-optimization/102852] " marxin at gcc dot gnu.org
@ 2021-10-20 6:38 ` aldyh at gcc dot gnu.org
2021-10-20 7:10 ` aldyh at gcc dot gnu.org
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: aldyh at gcc dot gnu.org @ 2021-10-20 6:38 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102852
Aldy Hernandez <aldyh at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jbglaw@lug-owl.de
--- Comment #1 from Aldy Hernandez <aldyh at gcc dot gnu.org> ---
This seems to have been fixed by the loop threading restrictions I just
committed:
$ time ./xgcc -B./ a.c -O3 -c
real 0m0.114s
user 0m0.100s
sys 0m0.013s
However, this looks suspicious, so please leave it open while I investigate.
The --param's I removed are obviously having deleterious effects.
This may be the same problem Jan-Benedict reported with compiling the Linux
kernel.
Thanks for distilling and reporting this.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/102852] [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b
2021-10-20 6:27 [Bug tree-optimization/102852] New: [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b marxin at gcc dot gnu.org
2021-10-20 6:27 ` [Bug tree-optimization/102852] " marxin at gcc dot gnu.org
2021-10-20 6:38 ` aldyh at gcc dot gnu.org
@ 2021-10-20 7:10 ` aldyh at gcc dot gnu.org
2021-10-20 7:11 ` marxin at gcc dot gnu.org
2021-10-20 7:18 ` aldyh at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: aldyh at gcc dot gnu.org @ 2021-10-20 7:10 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102852
Aldy Hernandez <aldyh at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |DUPLICATE
--- Comment #2 from Aldy Hernandez <aldyh at gcc dot gnu.org> ---
This is actually the same thing as 102814.
*** This bug has been marked as a duplicate of bug 102814 ***
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/102852] [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b
2021-10-20 6:27 [Bug tree-optimization/102852] New: [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b marxin at gcc dot gnu.org
` (2 preceding siblings ...)
2021-10-20 7:10 ` aldyh at gcc dot gnu.org
@ 2021-10-20 7:11 ` marxin at gcc dot gnu.org
2021-10-20 7:18 ` aldyh at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-10-20 7:11 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102852
--- Comment #3 from Martin Liška <marxin at gcc dot gnu.org> ---
Thanks for the fix, it's really gone now.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/102852] [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b
2021-10-20 6:27 [Bug tree-optimization/102852] New: [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b marxin at gcc dot gnu.org
` (3 preceding siblings ...)
2021-10-20 7:11 ` marxin at gcc dot gnu.org
@ 2021-10-20 7:18 ` aldyh at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: aldyh at gcc dot gnu.org @ 2021-10-20 7:18 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102852
--- Comment #4 from Aldy Hernandez <aldyh at gcc dot gnu.org> ---
(In reply to Martin Liška from comment #3)
> Thanks for the fix, it's really gone now.
Heh. Actually the bug is still latent, but I'm testing a fix ;-).
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-10-20 7:18 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-20 6:27 [Bug tree-optimization/102852] New: [12 Regression] Compile time hog since r12-4421-g0bd68793921ecf3b marxin at gcc dot gnu.org
2021-10-20 6:27 ` [Bug tree-optimization/102852] " marxin at gcc dot gnu.org
2021-10-20 6:38 ` aldyh at gcc dot gnu.org
2021-10-20 7:10 ` aldyh at gcc dot gnu.org
2021-10-20 7:11 ` marxin at gcc dot gnu.org
2021-10-20 7:18 ` aldyh at gcc dot gnu.org
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).