summaryrefslogtreecommitdiff
path: root/gcc/builtins.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2019-12-11 00:49:40 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2019-12-11 00:49:40 +0100
commita6ae300f9a019aff902cd11068af0956288d6541 (patch)
tree56061a0b729a25704f7b772c0a4ad8652d33ceb2 /gcc/builtins.c
parent7436a1c6750d1d45487f666da94808f5b06d5ffd (diff)
re PR tree-optimization/92891 (ice in decompose, at wide-int.h:984)
PR tree-optimization/92891 * builtins.c (gimple_call_alloc_size): Convert size to sizetype before returning it. * gcc.c-torture/compile/pr92891.c: New test. From-SVN: r279205
Diffstat (limited to 'gcc/builtins.c')
-rw-r--r--gcc/builtins.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/builtins.c b/gcc/builtins.c
index 53de17c105f..205ac3927b9 100644
--- a/gcc/builtins.c
+++ b/gcc/builtins.c
@@ -3755,7 +3755,7 @@ gimple_call_alloc_size (gimple *stmt)
return NULL_TREE;
if (argidx2 > nargs && TREE_CODE (size) == INTEGER_CST)
- return size;
+ return fold_convert (sizetype, size);
/* To handle ranges do the math in wide_int and return the product
of the upper bounds as a constant. Ignore anti-ranges. */