In reply to rupeshblr:
Without a specification for what your instruction set looks like (and some valid example solutions), it is difficult to answer. And probably to much detail to be addressed in this forum. I suggest you look for some local help.