Automatic ROP chain generator