fixed warnings
[libfirm] / ir / opt / scalar_replace.c
index 7e16e06..d0739ad 100644 (file)
 #include "config.h"
 #endif
 
-#ifdef HAVE_STRING_H
 #include <string.h>
-#endif
 
+#include "iroptimize.h"
 #include "scalar_replace.h"
 #include "irflag_t.h"
 #include "irouts.h"
@@ -87,6 +86,7 @@ static int path_cmp(const void *elt, const void *key, size_t size)
 {
   const path_t *p1 = elt;
   const path_t *p2 = key;
+  (void) size;
 
   /* we can use memcmp here, because identical tarvals should have identical addresses */
   return memcmp(p1->path, p2->path, p1->path_len * sizeof(p1->path[0]));
@@ -101,6 +101,7 @@ static int ent_cmp(const void *elt, const void *key, size_t size)
 {
   const scalars_t *c1 = elt;
   const scalars_t *c2 = key;
+  (void) size;
 
   return c1->ent != c2->ent;
 }
@@ -433,7 +434,7 @@ static unsigned allocate_value_numbers(pset *sels, ir_entity *ent, unsigned vnum
       set_insert(pathes, key, PATH_SIZE(key), path_hash(key));
 
       SET_VNUM(sel, key->vnum);
-      ARR_EXTO(ir_mode *, *modes, (key->vnum + 15) & ~15);
+      ARR_EXTO(ir_mode *, *modes, (int)((key->vnum + 15) & ~15));
 
       (*modes)[key->vnum] = get_type_mode(get_entity_type(get_Sel_entity(sel)));