[BRIGFE] Fix (more) crash with calls with more than 4 args.
authorHenry Linjamäki <henry.linjamaki@parmance.com>
Tue, 3 Oct 2017 15:16:34 +0000 (15:16 +0000)
committerPekka Jääskeläinen <visit0r@gcc.gnu.org>
Tue, 3 Oct 2017 15:16:34 +0000 (15:16 +0000)
It missed a reference which is required because vector expansion
can move the object to another location.

From-SVN: r253382

gcc/brig/ChangeLog
gcc/brig/brigfrontend/brig-branch-inst-handler.cc

index c66b16f..bdb7018 100644 (file)
@@ -1,3 +1,9 @@
+2017-10-03  Henry Linjamäki  <henry.linjamaki@parmance.com>
+
+       * brigfrontend/brig-branch-inst-handler.cc: Fix (more) crash with
+       calls with more than 4 args.  It missed a reference which is required
+       because vector expansion can move the object to another location.
+
 2017-09-29  Henry Linjamäki  <henry.linjamaki@parmance.com>
 
        * brigfrontend/brig-branch-inst-handler.cc: Fix crash with
index a32dd99..30aec37 100644 (file)
@@ -70,7 +70,7 @@ brig_branch_inst_handler::operator () (const BrigBase *base)
          const BrigOperandOffset32_t *operand_ptr
            = (const BrigOperandOffset32_t *) data->bytes;
 
-         vec<tree, va_gc> *args = i == 0 ? out_args : in_args;
+         vec<tree, va_gc> *&args = i == 0 ? out_args : in_args;
 
          while (bytes > 0)
            {