ec optimization

ec optimization