Ignore:
Timestamp:
Jun 14, 2016, 6:43:38 PM (3 years ago)
Author:
cameron
Message:

Bugfix: swap CreateStore? operands

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/kernels/interface.cpp

    r5053 r5054  
    174174        Value * parm = &*(args++);
    175175        Value * ptr = iBuilder->CreateGEP(self, {iBuilder->getInt32(0), getScalarIndex(binding.scalarName)});
    176         iBuilder->CreateStore(ptr, parm);
     176        iBuilder->CreateStore(parm, ptr);
    177177    }
    178178    iBuilder->CreateRetVoid();
     
    196196void KernelInterface::setScalarField(Value * self, std::string fieldName, Value * newFieldVal) {
    197197    Value * ptr = iBuilder->CreateGEP(self, {iBuilder->getInt32(0), getScalarIndex(fieldName)});
    198     iBuilder->CreateStore(ptr, newFieldVal);
     198    iBuilder->CreateStore(newFieldVal, ptr);
    199199}
    200200
Note: See TracChangeset for help on using the changeset viewer.