Modified comparing functions to match new primops