public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s
@ 2021-02-02 8:03 crazylht at gmail dot com
2021-02-02 8:24 ` [Bug tree-optimization/98928] " rguenth at gcc dot gnu.org
` (7 more replies)
0 siblings, 8 replies; 9+ messages in thread
From: crazylht at gmail dot com @ 2021-02-02 8:03 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98928
Bug ID: 98928
Summary: [11 regression] ICE when build 638.imagick_s
Product: gcc
Version: 11.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: crazylht at gmail dot com
Target Milestone: ---
Host: x86_64-pc-linux-gnu
I can't reproduce it with small testcase, the regression may happen between
20201211 and 20201215, ICE still can be reproduced in the latest trunk with gcc
option: -march=skylake-avx512 -Ofast -funroll-loops -mfpmath=sse -Ofast
-fno-associative-math -flto -fopenmp
ice dump:
spec@shgcc100:~/workspace/CPU2017_SHGCC100/result/benchspec/CPU/638.imagick_s/build/build_base_march_native_ofast.0000$
/export/liuhongt/install/gcc11_trunk/bin/gcc -m64 -Wl,-z,muldefs
-march=native -Ofast -funroll-loops -mfpmath=sse -Ofast -fno-associative-math
-funroll-loops -flto -fopenmp -DSPEC_OPENMP coders/tga.o
filters/analyze.o magick/accelerate.o magick/animate.o magick/annotate.o
magick/artifact.o magick/attribute.o magick/blob.o magick/cache-view.o
magick/cache.o magick/channel.o magick/cipher.o magick/client.o magick/coder.o
magick/color.o magick/colormap.o magick/colorspace.o magick/compare.o
magick/composite.o magick/compress.o magick/configure.o magick/constitute.o
magick/decorate.o magick/delegate.o magick/display.o magick/distort.o
magick/distribute-cache.o magick/draw.o magick/effect.o magick/enhance.o
magick/exception.o magick/feature.o magick/fourier.o magick/fx.o magick/gem.o
magick/geometry.o magick/hashmap.o magick/histogram.o magick/identify.o
magick/image.o magick/layer.o magick/list.o magick/locale.o magick/log.o
magick/magic.o magick/magick.o magick/matrix.o magick/memory.o magick/mime.o
magick/module.o magick/monitor.o magick/montage.o magick/morphology.o
magick/option.o magick/paint.o magick/pixel.o magick/policy.o magick/prepress.o
magick/profile.o magick/property.o magick/quantize.o magick/quantum-export.o
magick/quantum-import.o magick/quantum.o magick/random.o magick/registry.o
magick/resample.o magick/resize.o magick/resource.o magick/segment.o
magick/semaphore.o magick/shear.o magick/signature.o magick/splay-tree.o
magick/static.o magick/statistic.o magick/stream.o magick/string.o
magick/threshold.o magick/timer.o magick/token.o magick/transform.o
magick/type.o magick/utility.o magick/version.o magick/xml-tree.o
utilities/convert.o wand/convert.o wand/drawing-wand.o wand/magick-image.o
wand/magick-wand.o wand/mogrify.o wand/pixel-wand.o wand/magick-property.o
wand/pixel-iterator.o wand/wand.o magick/deprecate.o -lm
-L/home/spec/workspace/CPU2017_SHGCC100/speccpu2017/jemalloc/intel64/lib/
-ljemalloc -lpthread -ldl -o imagick_sIn function ‘CopyMagickMemory’,
inlined from ‘ConvertUTF16ToUTF8’ at magick/xml-tree.c:1341:14,
inlined from ‘NewXMLTree.part.0’ at magick/xml-tree.c:1973:8:
magick/memory.c:702:10: warning: ‘__builtin_memcpy’ writing one too many bytes
into a region of a size that depends on ‘strlen’ [-Wstringop-overflow=]
702 | return(memmove(destination,source,size));
| ^
magick/xml-tree.c: In function ‘NewXMLTree.part.0’:
magick/memory.c:464:10: note: destination object of size [0,
9223372036854775805] allocated by ‘malloc’
464 | memory=memory_methods.acquire_memory_handler(size == 0 ? 1UL : size);
| ^
during GIMPLE pass: vect
magick/pixel.c: In function ‘InterpolateMagickPixelPacket.constprop.isra’:
magick/pixel.c:4244:32: internal compiler error: in
vect_get_vec_defs_for_operand, at tree-vect-stmts.c:1450
4244 | MagickExport MagickBooleanType InterpolateMagickPixelPacket(const Image
*image,
| ^
0x75bc56 vect_get_vec_defs_for_operand(vec_info*, _stmt_vec_info*, unsigned
int, tree_node*, vec<tree_node*, va_heap, vl_ptr>*, tree_node*)
../../../gcc/git_trunk/gcc/tree-vect-stmts.c:1450
0x10295e3 vect_get_vec_defs(vec_info*, _stmt_vec_info*, _slp_tree*, unsigned
int, tree_node*, vec<tree_node*, va_heap, vl_ptr>*, tree_node*, tree_node*,
vec<tree_node*, va_heap, vl_ptr>*, tree_node*, tree_node*, vec<tree_node*,
va_heap, vl_ptr>*, tree_node*, tree_node*, vec<tree_node*, va_heap, vl_ptr>*,
tree_node*)
../../../gcc/git_trunk/gcc/tree-vect-stmts.c:1482
0x10296cc vect_get_vec_defs(vec_info*, _stmt_vec_info*, _slp_tree*, unsigned
int, tree_node*, vec<tree_node*, va_heap, vl_ptr>*, tree_node*, vec<tree_node*,
va_heap, vl_ptr>*, tree_node*, vec<tree_node*, va_heap, vl_ptr>*, tree_node*,
vec<tree_node*, va_heap, vl_ptr>*)
../../../gcc/git_trunk/gcc/tree-vect-stmts.c:1504
0x102a1a5 vectorizable_conversion
../../../gcc/git_trunk/gcc/tree-vect-stmts.c:4963
0x1045e38 vect_transform_stmt(vec_info*, _stmt_vec_info*,
gimple_stmt_iterator*, _slp_tree*, _slp_instance*)
../../../gcc/git_trunk/gcc/tree-vect-stmts.c:10831
0x104b7ba vect_transform_loop_stmt
../../../gcc/git_trunk/gcc/tree-vect-loop.c:9204
0x10659c7 vect_transform_loop(_loop_vec_info*, gimple*)
../../../gcc/git_trunk/gcc/tree-vect-loop.c:9640
0x109393c try_vectorize_loop_1
../../../gcc/git_trunk/gcc/tree-vectorizer.c:1103
0x1094629 vectorize_loops()
../../../gcc/git_trunk/gcc/tree-vectorizer.c:1242
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
lto-wrapper: fatal error: /export/liuhongt/install/gcc11_trunk/bin/gcc returned
1 exit status
compilation terminated.
/usr/bin/ld: error: lto-wrapper failed
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s
2021-02-02 8:03 [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s crazylht at gmail dot com
@ 2021-02-02 8:24 ` rguenth at gcc dot gnu.org
2021-02-02 8:58 ` marxin at gcc dot gnu.org
` (6 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu.org @ 2021-02-02 8:24 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98928
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |ASSIGNED
Ever confirmed|0 |1
Assignee|unassigned at gcc dot gnu.org |rguenth at gcc dot gnu.org
Target Milestone|--- |11.0
Last reconfirmed| |2021-02-02
--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
I will investigate
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s
2021-02-02 8:03 [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s crazylht at gmail dot com
2021-02-02 8:24 ` [Bug tree-optimization/98928] " rguenth at gcc dot gnu.org
@ 2021-02-02 8:58 ` marxin at gcc dot gnu.org
2021-02-02 10:33 ` marxin at gcc dot gnu.org
` (5 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-02-02 8:58 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98928
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |marxin at gcc dot gnu.org
--- Comment #2 from Martin Liška <marxin at gcc dot gnu.org> ---
I'm reducing a test-case.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s
2021-02-02 8:03 [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s crazylht at gmail dot com
2021-02-02 8:24 ` [Bug tree-optimization/98928] " rguenth at gcc dot gnu.org
2021-02-02 8:58 ` marxin at gcc dot gnu.org
@ 2021-02-02 10:33 ` marxin at gcc dot gnu.org
2021-02-02 10:33 ` [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s since r11-5969-g3ed472af6bc9f83b marxin at gcc dot gnu.org
` (4 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-02-02 10:33 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98928
--- Comment #3 from Martin Liška <marxin at gcc dot gnu.org> ---
Reduced test-case:
$ cat ice.i
typedef float MagickRealType;
typedef short Quantum;
float InterpolateMagickPixelPacket_alpha[1];
int InterpolateMagickPixelPacket_i;
void InterpolateMagickPixelPacket();
void main() { InterpolateMagickPixelPacket(); }
typedef struct {
MagickRealType red, green, blue, opacity, index;
} MagickPixelPacket;
typedef struct {
Quantum blue, green, red, opacity;
} PixelPacket;
struct _Image {
int colorspace;
int matte;
} GetMagickPixelPacket(MagickPixelPacket *pixel) {
pixel->red = pixel->green = pixel->blue = 0.0;
}
int AlphaBlendMagickPixelPacket(struct _Image *image, PixelPacket *color,
Quantum *indexes, MagickPixelPacket *pixel,
MagickRealType *alpha) {
if (image->matte) {
*alpha = pixel->red = pixel->green = pixel->blue = pixel->opacity =
color->opacity;
pixel->index = 0.0;
if (image->colorspace)
pixel->index = *indexes;
return 0;
}
*alpha = 1.0 / 0.2;
pixel->red = *alpha * color->red;
pixel->green = *alpha * color->green;
pixel->blue = *alpha * color->blue;
pixel->opacity = pixel->index = 0.0;
if (image->colorspace && indexes)
pixel->index = *indexes;
}
MagickPixelPacket InterpolateMagickPixelPacket_pixels[1];
PixelPacket InterpolateMagickPixelPacket_p;
void
InterpolateMagickPixelPacket(struct _Image *image) {
Quantum *indexes;
for (; InterpolateMagickPixelPacket_i; InterpolateMagickPixelPacket_i++) {
GetMagickPixelPacket(InterpolateMagickPixelPacket_pixels +
InterpolateMagickPixelPacket_i);
AlphaBlendMagickPixelPacket(
image, &InterpolateMagickPixelPacket_p +
InterpolateMagickPixelPacket_i,
indexes + InterpolateMagickPixelPacket_i,
InterpolateMagickPixelPacket_pixels + InterpolateMagickPixelPacket_i,
InterpolateMagickPixelPacket_alpha + InterpolateMagickPixelPacket_i);
}
}
one needs the following options: gcc -Ofast -march=skylake-avx512 ice.i
-fwhole-program
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s since r11-5969-g3ed472af6bc9f83b
2021-02-02 8:03 [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s crazylht at gmail dot com
` (2 preceding siblings ...)
2021-02-02 10:33 ` marxin at gcc dot gnu.org
@ 2021-02-02 10:33 ` marxin at gcc dot gnu.org
2021-02-02 12:43 ` tnfchris at gcc dot gnu.org
` (3 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-02-02 10:33 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98928
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |tnfchris at gcc dot gnu.org
Blocks| |26163
Known to work| |10.2.0
Known to fail| |11.0
Priority|P3 |P1
Summary|[11 regression] ICE when |[11 regression] ICE when
|build 638.imagick_s |build 638.imagick_s since
| |r11-5969-g3ed472af6bc9f83b
--- Comment #4 from Martin Liška <marxin at gcc dot gnu.org> ---
Started with r11-5969-g3ed472af6bc9f83b.
Referenced Bugs:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=26163
[Bug 26163] [meta-bug] missed optimization in SPEC (2k17, 2k and 2k6 and 95)
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s since r11-5969-g3ed472af6bc9f83b
2021-02-02 8:03 [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s crazylht at gmail dot com
` (3 preceding siblings ...)
2021-02-02 10:33 ` [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s since r11-5969-g3ed472af6bc9f83b marxin at gcc dot gnu.org
@ 2021-02-02 12:43 ` tnfchris at gcc dot gnu.org
2021-02-02 14:58 ` tnfchris at gcc dot gnu.org
` (2 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: tnfchris at gcc dot gnu.org @ 2021-02-02 12:43 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98928
--- Comment #5 from Tamar Christina <tnfchris at gcc dot gnu.org> ---
Hmm looks like the SLP unwinding code is accidentally cancelling a pattern it
shouldn't have. Checking why...
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s since r11-5969-g3ed472af6bc9f83b
2021-02-02 8:03 [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s crazylht at gmail dot com
` (4 preceding siblings ...)
2021-02-02 12:43 ` tnfchris at gcc dot gnu.org
@ 2021-02-02 14:58 ` tnfchris at gcc dot gnu.org
2021-02-03 8:09 ` cvs-commit at gcc dot gnu.org
2021-02-03 8:10 ` tnfchris at gcc dot gnu.org
7 siblings, 0 replies; 9+ messages in thread
From: tnfchris at gcc dot gnu.org @ 2021-02-02 14:58 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98928
Tamar Christina <tnfchris at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|rguenth at gcc dot gnu.org |tnfchris at gcc dot gnu.org
--- Comment #6 from Tamar Christina <tnfchris at gcc dot gnu.org> ---
testing patch.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s since r11-5969-g3ed472af6bc9f83b
2021-02-02 8:03 [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s crazylht at gmail dot com
` (5 preceding siblings ...)
2021-02-02 14:58 ` tnfchris at gcc dot gnu.org
@ 2021-02-03 8:09 ` cvs-commit at gcc dot gnu.org
2021-02-03 8:10 ` tnfchris at gcc dot gnu.org
7 siblings, 0 replies; 9+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-02-03 8:09 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98928
--- Comment #7 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Tamar Christina <tnfchris@gcc.gnu.org>:
https://gcc.gnu.org/g:5e606ed90a1bed878071b6b5a3ef9b97b3d99838
commit r11-7049-g5e606ed90a1bed878071b6b5a3ef9b97b3d99838
Author: Tamar Christina <tamar.christina@arm.com>
Date: Wed Feb 3 08:06:11 2021 +0000
slp: Split out patterns away from using SLP_ONLY into their own flag
Previously the SLP pattern matcher was using STMT_VINFO_SLP_VECT_ONLY as a
way
to dissolve the SLP only patterns during SLP cancellation. However it
seems
like the semantics for STMT_VINFO_SLP_VECT_ONLY are slightly different than
what
I expected.
Namely that the non-SLP path can still use a statement marked
STMT_VINFO_SLP_VECT_ONLY. One such example is masked loads which are used
both
in the SLP and non-SLP path.
To fix this I now introduce a new flag STMT_VINFO_SLP_VECT_ONLY_PATTERN
which is
used only by the pattern matcher.
gcc/ChangeLog:
PR tree-optimization/98928
* tree-vect-loop.c (vect_analyze_loop_2): Change
STMT_VINFO_SLP_VECT_ONLY to STMT_VINFO_SLP_VECT_ONLY_PATTERN.
* tree-vect-slp-patterns.c (complex_pattern::build): Likewise.
* tree-vectorizer.h (STMT_VINFO_SLP_VECT_ONLY_PATTERN): New.
(class _stmt_vec_info): Add slp_vect_pattern_only_p.
gcc/testsuite/ChangeLog:
PR tree-optimization/98928
* gcc.target/i386/pr98928.c: New test.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s since r11-5969-g3ed472af6bc9f83b
2021-02-02 8:03 [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s crazylht at gmail dot com
` (6 preceding siblings ...)
2021-02-03 8:09 ` cvs-commit at gcc dot gnu.org
@ 2021-02-03 8:10 ` tnfchris at gcc dot gnu.org
7 siblings, 0 replies; 9+ messages in thread
From: tnfchris at gcc dot gnu.org @ 2021-02-03 8:10 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98928
Tamar Christina <tnfchris at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|ASSIGNED |RESOLVED
--- Comment #8 from Tamar Christina <tnfchris at gcc dot gnu.org> ---
Fixed in trunk
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2021-02-03 8:10 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-02 8:03 [Bug tree-optimization/98928] New: [11 regression] ICE when build 638.imagick_s crazylht at gmail dot com
2021-02-02 8:24 ` [Bug tree-optimization/98928] " rguenth at gcc dot gnu.org
2021-02-02 8:58 ` marxin at gcc dot gnu.org
2021-02-02 10:33 ` marxin at gcc dot gnu.org
2021-02-02 10:33 ` [Bug tree-optimization/98928] [11 regression] ICE when build 638.imagick_s since r11-5969-g3ed472af6bc9f83b marxin at gcc dot gnu.org
2021-02-02 12:43 ` tnfchris at gcc dot gnu.org
2021-02-02 14:58 ` tnfchris at gcc dot gnu.org
2021-02-03 8:09 ` cvs-commit at gcc dot gnu.org
2021-02-03 8:10 ` tnfchris 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).