Optimize security type in inst impl