2009-12-04 Zoltan Varga <vargaz@gmail.com>
[mono.git] / mono / mini / regalloc2.c
index 577b1e1892e5afad3eed22cb2b02618b99677319..c0308e8c30303b8bf3285230d6c3bd6c9e7cbbab 100644 (file)
@@ -135,12 +135,7 @@ typedef struct MonoRegallocContext {
  * MACROS
  */
 
-#if SIZEOF_VOID_P == 8
-#define BITS_PER_CHUNK 64
-#else
-#define BITS_PER_CHUNK 32
-#endif
-
+#define BITS_PER_CHUNK MONO_BITSET_BITS_PER_CHUNK
 #define MONO_FIRST_VREG (MONO_MAX_IREGS+MONO_MAX_FREGS)
 
 /* 
@@ -186,24 +181,6 @@ typedef struct MonoRegallocContext {
 
 #define USE_POS_IS_DEF(ins_pos) ((ins_pos) & INS_POS_DEF)
 
-static inline GSList*
-g_slist_append_mempool (MonoMemPool *mp, GSList   *list,
-                                               gpointer  data)
-{
-       GSList *new_list, *last;
-
-       last = g_slist_last (list);
-       new_list = mono_mempool_alloc (mp, sizeof (GSList));
-       new_list->data = data;
-       new_list->next = NULL;
-       if (last) {
-               last->next = new_list;
-               return list;
-       } else {
-               return new_list;
-       }
-}
-
 static MonoInst*
 create_move (MonoCompile *cfg, int dreg, int sreg)
 {
@@ -2115,7 +2092,7 @@ rewrite_code (MonoCompile *cfg, MonoRegallocContext *ctx)
        MonoBasicBlock *bb;
        MonoInst *ins, *prev;
        int pos;
-       MonoInst **defs, *def;
+       MonoInst **defs;
 
        defs = g_new (MonoInst*, MONO_MAX_IREGS + MONO_MAX_FREGS);