guile-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Guile-commits] 180/437: Correct C sequence point problem.


From: Andy Wingo
Subject: [Guile-commits] 180/437: Correct C sequence point problem.
Date: Mon, 2 Jul 2018 05:14:13 -0400 (EDT)

wingo pushed a commit to branch lightning
in repository guile.

commit 7c7908c97e5c2a8779993dcdfe198b34c09784fc
Author: pcpa <address@hidden>
Date:   Wed Jan 30 00:36:52 2013 -0200

    Correct C sequence point problem.
    
        * lib/jit_x86-cpu.c: Correct undefined behavior code.
        http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56143
---
 ChangeLog         |  5 +++++
 lib/jit_x86-cpu.c | 16 ++++++++++++----
 2 files changed, 17 insertions(+), 4 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 2a4170b..0c929d3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2013-01-30 Paulo Andrade <address@hidden>
+
+       * lib/jit_x86-cpu.c: Correct undefined behavior code.
+       http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56143
+
 2013-01-29 Paulo Andrade <address@hidden>
 
        * configure.ac: Use AC_CONFIG_HEADERS instead of AC_CONFIG_HEADER
diff --git a/lib/jit_x86-cpu.c b/lib/jit_x86-cpu.c
index 997855d..9ba93c3 100644
--- a/lib/jit_x86-cpu.c
+++ b/lib/jit_x86-cpu.c
@@ -2601,16 +2601,20 @@ _stxi_l(jit_state_t *_jit, jit_word_t i0, jit_int32_t 
r0, jit_int32_t r1)
 static void
 _jccs(jit_state_t *_jit, jit_int32_t code, jit_word_t i0)
 {
+    jit_word_t         w;
     ic(0x70 | code);
-    ic(i0 - (_jit->pc.w + 1));
+    w = i0 - (_jit->pc.w + 1);
+    ic(w);
 }
 
 static void
 _jcc(jit_state_t *_jit, jit_int32_t code, jit_word_t i0)
 {
+    jit_word_t         w;
     ic(0x0f);
     ic(0x80 | code);
-    ii(i0 - (_jit->pc.w + 4));
+    w = i0 - (_jit->pc.w + 4);
+    ii(w);
 }
 
 static void
@@ -3040,8 +3044,10 @@ _calli(jit_state_t *_jit, jit_word_t i0)
     callr(rn(reg));
     jit_unget_reg(reg);
 #else
+    jit_word_t         w;
     ic(0xe8);
-    ii(i0 - (_jit->pc.w + 4));
+    w = i0 - (_jit->pc.w + 4);
+    ii(w);
     word = _jit->pc.w;
 #endif
     return (word);
@@ -3058,8 +3064,10 @@ _jmpr(jit_state_t *_jit, jit_int32_t r0)
 static jit_word_t
 _jmpi(jit_state_t *_jit, jit_word_t i0)
 {
+    jit_word_t         w;
     ic(0xe9);
-    ii(i0 - (_jit->pc.w + 4));
+    w = i0 - (_jit->pc.w + 4);
+    ii(w);
     return (_jit->pc.w);
 }
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]