dotgnu-pnet-commits
[Top][All Lists]
Advanced

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

[dotgnu-pnet-commits] [SCM] DotGNU Portable.NET engine, compilers and to


From: Klaus Treichel
Subject: [dotgnu-pnet-commits] [SCM] DotGNU Portable.NET engine, compilers and tools (pnet) branch, master, updated. 9c33568c36a12545007dc0a6046f7cbd14dbaa71
Date: Wed, 09 Dec 2009 20:20:53 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "DotGNU Portable.NET engine, compilers and tools (pnet)".

The branch, master has been updated
       via  9c33568c36a12545007dc0a6046f7cbd14dbaa71 (commit)
      from  f701605f1686559e385d18b82c1e2784876e62bf (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit/pnet.git/commit/?id=9c33568c36a12545007dc0a6046f7cbd14dbaa71

commit 9c33568c36a12545007dc0a6046f7cbd14dbaa71
Author: Klaus Treichel <address@hidden>
Date:   Wed Dec 9 21:20:37 2009 +0100

    Add changes for the new block handling in libjit.

diff --git a/ChangeLog b/ChangeLog
index fd889c9..8a61b88 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2009-12-09  Klaus Treichel  <address@hidden,de>
+
+       * engine/jitc_branch.c (JITCoder_Label): Don't add the label for offset
+       0 here because that was already done during setup.
+
+       * engine/jitc_locals.c (_ILJitLocalsInit): Create new blocks for the
+       start and end label to make sure that they are on different blocks.
+
 2009-11-24  Klaus Treichel  <address@hidden>
 
        * engine/verify_call.c (TryInlineLoad): Remove the extra check for value
diff --git a/engine/jitc_branch.c b/engine/jitc_branch.c
index 466f0bb..3cdd9c4 100755
--- a/engine/jitc_branch.c
+++ b/engine/jitc_branch.c
@@ -58,7 +58,13 @@ static void JITCoder_Label(ILCoder *coder, ILUInt32 offset)
                        }
                #endif
                        _ILJitLabelRestoreStack(jitCoder, label);
-                       jit_insn_label(jitCoder->jitFunction, &(label->label));
+                       /*
+                        * The label for the 0 offset is already inserted 
during setup.
+                        */
+                       if(offset != 0)
+                       {
+                               jit_insn_label(jitCoder->jitFunction, 
&(label->label));
+                       }
                }
        }
 }
diff --git a/engine/jitc_locals.c b/engine/jitc_locals.c
index adf344b..8ed30ae 100755
--- a/engine/jitc_locals.c
+++ b/engine/jitc_locals.c
@@ -461,6 +461,15 @@ static int _ILJitLocalsInit(ILJITCoder *coder)
                jit_label_t startLabel = jit_label_undefined;
                jit_label_t endLabel = jit_label_undefined;
 
+               /* 
+                * Create a new block to make sure that the start label will be
+                * placed on a new block alone with the code generated.
+                */
+               if(!jit_insn_new_block(coder->jitFunction))
+               {
+                       return 0;
+               }
+
                if(!jit_insn_label(coder->jitFunction, &startLabel))
                {
                        return 0;
@@ -471,22 +480,26 @@ static int _ILJitLocalsInit(ILJITCoder *coder)
                        return 0;
                }
 
+               /*
+                * Create a new block for the end label. This should be done
+                * by jit_insn_label anyways but it doesn't hurt.
+                * The case where this seems to be needed is if all locals are
+                * structs which are not initialized by now.
+                */
+               if(!jit_insn_new_block(coder->jitFunction))
+               {
+                       return 0;
+               }
+
                if(!jit_insn_label(coder->jitFunction, &endLabel))
                {
                        return 0;
                }
-               /*
-                * TODO: This additional check for inequal blocks can be removed
-                * later when label merging is fixed in libjit.
-                */
-               if(jit_block_from_label(coder->jitFunction, startLabel) !=
-                  jit_block_from_label(coder->jitFunction, endLabel))
+
+               if(!jit_insn_move_blocks_to_start(coder->jitFunction, 
startLabel,
+                                                                               
                                          endLabel))
                {
-                       if(!jit_insn_move_blocks_to_start(coder->jitFunction, 
startLabel,
-                                                                               
                                                  endLabel))
-                       {
-                               return 0;
-                       }
+                       return 0;
                }
        }
        return 1;

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog            |    8 ++++++++
 engine/jitc_branch.c |    8 +++++++-
 engine/jitc_locals.c |   35 ++++++++++++++++++++++++-----------
 3 files changed, 39 insertions(+), 12 deletions(-)


hooks/post-receive
-- 
DotGNU Portable.NET engine, compilers and tools (pnet)




reply via email to

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