ckobjid: Use CkArrayIndex instead of CkArrayIndexStruct
authorRamprasad Venkataraman <ramv@illinois.edu>
Tue, 26 Apr 2011 17:56:12 +0000 (12:56 -0500)
committerRamprasad Venkataraman <ramv@illinois.edu>
Tue, 31 May 2011 15:18:33 +0000 (10:18 -0500)
Needs further testing from fault tolerance subgroup

src/ck-core/ckobjid.h

index a2caef7fe7eec6a6f475362d78509bbb5684bd3d..8987fddf231f41908ce89959ba624ab217a70097 100644 (file)
@@ -11,7 +11,7 @@ union _ObjectID {
        } group; //also used for NodeGroups
        struct s_array{
                CkGroupID id; //array id
-               CkArrayIndexStruct idx; //index
+               CkArrayIndex idx; //index
        } array;
 };
 
@@ -39,8 +39,7 @@ public:
                    ret += circleShift(data.group.id.idx,6);
                    break;
                case TypeArray:
-                   CkArrayIndex &i1= (CkArrayIndex &)data.array.idx.asMax();
-                   CkHashCode temp = i1.hash();
+                   CkHashCode temp = data.array.idx.hash();
                    //ret = circleShift(ret,13);
                    //ret += circleShift(temp,11);
                    ret += temp;
@@ -71,10 +70,8 @@ public:
                                }
                                break;
                        case TypeArray:
-                               CkArrayIndex &i1= (CkArrayIndex &)data.array.idx.asMax();
-                               CkArrayIndex &i2 = (CkArrayIndex &)t.data.array.idx.asMax();
                                bool val;
-                               if(data.array.id == t.data.array.id && i1.compare(i2)){
+                               if(data.array.id == t.data.array.id && data.array.idx.compare(t.data.array.idx)){
                                        val = true;
                                }else{
                                        val = false;