In Android reference, it says
For performance reasons, view inflation relies heavily on pre-processing of XML files that is done at build time. Therefore, it is not currently possible to use LayoutInflater with an XmlPullParser over a plain XML file at runtime; it only works with an XmlPullParser returned from a compiled resource (R.something file.)
if it really causes performance reasons why Android developers don't solve this problem? Is it any solution about it? Can I use a XML parser before inflate layout file?