unwind-dw2.c (_Unwind_GetGR): Compare regno instead of index to DWARF_ZERO_REG.
authorUros Bizjak <ubizjak@gmail.com>
Tue, 19 Feb 2019 16:10:00 +0000 (17:10 +0100)
committerUros Bizjak <uros@gcc.gnu.org>
Tue, 19 Feb 2019 16:10:00 +0000 (17:10 +0100)
* unwind-dw2.c (_Unwind_GetGR) [DWARF_ZERO_REG]: Compare
regno instead of index to DWARF_ZERO_REG.

From-SVN: r269021

libgcc/ChangeLog
libgcc/unwind-dw2.c

index 65cd3f97cddf8928cf8f52cb2320f2bc426c9182..c8b59b4814b4ffccafd5c8f42ca52f1eb52bc99b 100644 (file)
@@ -1,3 +1,8 @@
+2019-02-19  Uroš Bizjak  <ubizjak@gmail.com>
+
+       * unwind-dw2.c (_Unwind_GetGR) [DWARF_ZERO_REG]: Compare
+       regno instead of index to DWARF_ZERO_REG.
+
 2019-02-15  Eric Botcazou  <ebotcazou@adacore.com>
 
        * config/visium/lib2funcs.c (__set_trampoline_parity): Replace
index bd88df963957aef1c6a2396f0ce355c54f3dd475..e6130af2fb54d1abca80baba1af5cd1e48ee7410 100644 (file)
@@ -225,7 +225,7 @@ _Unwind_GetGR (struct _Unwind_Context *context, int regno)
   _Unwind_Context_Reg_Val val;
 
 #ifdef DWARF_ZERO_REG
-  if (index == DWARF_ZERO_REG)
+  if (regno == DWARF_ZERO_REG)
     return 0;
 #endif