ir: Add typeid builder