added jp cc,nn and some bug fixes. S flag seems work correct