small optimization
authorbdemsky <bdemsky>
Mon, 27 Jun 2011 06:29:47 +0000 (06:29 +0000)
committerbdemsky <bdemsky>
Mon, 27 Jun 2011 06:29:47 +0000 (06:29 +0000)
Robust/src/Runtime/bamboo/multicoregcflush.c

index 6d79bc7f38f655c870c6b88248d75ba70294bbc2..762d1d0f8ffb152f6541fca2620289552686e1e8 100644 (file)
@@ -217,7 +217,8 @@ void * updateblocks(struct moveHelper * orig, struct moveHelper * to) {
       /* Move the object */
       if(origptr <= endtoptr) {
         memmove(dstptr, origptr, length);
-      } else {
+      } else if (origptr!=dstptr) {
+       //no need to copy if the source & dest are equal....
         memcpy(dstptr, origptr, length);
       }