Fix uninitialized field in expand_operand.
authorAndrew Pinski <apinski@marvell.com>
Thu, 16 Jan 2020 01:52:12 +0000 (01:52 +0000)
committerAndrew Pinski <apinski@marvell.com>
Thu, 16 Jan 2020 12:25:31 +0000 (12:25 +0000)
Commit g:f96bf49a0 added the target field to expand_operand.
But it leaves it uninitialized when doing a full initialization
inside create_expand_operand.  This fixes the problem and improves
the code generation inside create_expand_operand too.

ChangeLog:
* optabs.h (create_expand_operand): Initialize target field also.

gcc/ChangeLog
gcc/optabs.h

index d21ec86a2dd190f271647a23416021561fed827e..4196998ff69bf4c190c7dab09927de0529e3700b 100644 (file)
@@ -1,3 +1,7 @@
+2020-01-16  Andrew Pinski  <apinski@marvell.com>
+
+       * optabs.h (create_expand_operand): Initialize target field also.
+
 2020-01-16  Andre Vieira  <andre.simoesdiasvieira@arm.com>
 
        PR tree-optimization/92429
index 07bdc56586e9acf12114c386e7627cb03715db60..5bd19503a0ac0a3dbca322530cfb841a9e83cd2f 100644 (file)
@@ -78,6 +78,7 @@ create_expand_operand (class expand_operand *op,
 {
   op->type = type;
   op->unsigned_p = unsigned_p;
+  op->target = 0;
   op->unused = 0;
   op->mode = mode;
   op->value = value;