WP SilverLight 8.1 vs WP 8.1(XAML)的优点和缺点

我一直在阅读Wp8.1(XAML)应用程序是为Windows Phone 8.1创建应用程序的新方法,并且该代码对Windows 8.1桌面应用程序具有高度可重用性。

但是有点担心,因为从联系人(WP8.1 XAML中的ContactManager)执行单个搜索比Silverlight对应的慢。

只需从我的议程中返回所有联系人(240个联系人,包括电子邮件,缩略图等),我的Lumia 1520需要3秒钟; 与Silverlight代码相同的操作需要0.7秒。

我有点害怕使用WP8.1来制作手机应用,因为性能对我来说非常重要。 使用Lumia 1520的触点,Lumia 535的相同测试分别需要7秒和1.5秒。

是否有关于使用何种项目的推荐? 我觉得Silverlight应用程序(显然)专注于Windows Phone并使用所有手机的function。

我错了? 我是否会通过选择Windows手机Silverlight进入弃用之路?

注意:用于执行搜索的代码是MSDN示例中的代码…

WP8.1 XAML(诺基亚Lumia 1520,3秒与缩略图,邮件帐户等获得240个联系人……)

ContactStore agenda = await ContactManager.RequestStoreAsync(); Stopwatch sw = new Stopwatch(); IReadOnlyList contacts = null; sw.Start(); contacts = await agenda.FindContactsAsync(); sw.Stop(); txtblock1.Text = sw.ElapsedMilliseconds; 

WP Silverlight 8.1(诺基亚Lumia 1520,0.7秒获得240个缩略图,邮件账号等联系人……)

 Contacts agenda = new Contacts(); //Stopwatch is declared at class level so its accessible in ListContacts_SearchCompleted Callback sw.Start(); agenda.SearchCompleted+= ListContacts_SearchCompleted; agenda.SearchAsync(String.Empty, FilterKind.None, null); //sw.Stop() and print ElapsedMilliseconds in ListContacts_SearchCompleted callback 

编辑:在论坛中创建的post有关此https://social.msdn.microsoft.com/forums/windowsdesktop/en-us/1e0accaf-b2f8-4d68-b5ec-dc6af6351633/findcontactsasync-takes-long-time?referrer=http: //social.msdn.microsoft.com/forums/windowsdesktop/en-us/1e0accaf-b2f8-4d68-b5ec-dc6af6351633/findcontactsasync-takes-long-time?referrer=http://social.msdn.microsoft.com/论坛/ windowsdesktop / EN-US / 1e0accaf-b2f8-4d68-b5ec-dc6af6351633 / findcontactsasync通吃长时间?论坛= wpdevelop

你在比较同样的事情吗?

在Silverlight版本中,您只能在完成处理程序中调用sw.Stop。

如果你真的想做一个很好的比较,你应该得到一个ETW跟踪; 然后你就能真正理解正在发生的事情。

对于基于Metro XAML的解决方案,可能会有额外的互操作成本。 但这似乎是未来的道路。

对于Silverlight,现有API可能更适合于perf。

也许你应该在这两个解决方案上工作,尽可能地使可共享代码尽可能大,然后决定采用哪种方式。