Help us make Xamarin faster in Visual Studio 2017

PierceBogganPierceBoggan USForum Administrator, Xamarin Team, Developer Group Leader Xamurai
edited November 2017 in General

Hi all!

The Visual Studio Tools for Xamarin team is working on making Xamarin more performant in Visual Studio 2017. This includes everything from IDE interaction (like solution and document load times) to build and deployment times.

We need your help - it will only take a few minutes:

  • Solution Load - Install the Project System Tools extension. Delete the hidden .vs subfolder in your solution folder. Open Visual Studio to the start screen and navigate to View -> Other Windows -> Build Logging. Click the play button to begin logging, and open your solution. Once the solution is finished loading, press stop, and right-click each row to export. You can see the entire process in this screencast.
  • Build - Capture a diagnostic build log using the MSBuild /bl switch from the command line (ex: msbuild.exe MyApp.sln /bl). This outputs a .binlog with diagnostic build information.
  • Deploy – Run msbuild /p:"AdbTarget=-s <id>" /t:Install /bl. You can get the ID by running adb devices.

Additionally, if you own a Mac, please repeat the steps above for the same app you built/deployed on Windows.

Either post results here on the thread or send a DM to my forums account.

If you have difficulties with other areas of the product being slow, please reach out to me directly on Twitter, and we can work to diagnose the issue.

Thanks,
Pierce Boggan

Posts

  • zahikramerzahikramer ILMember ✭✭✭

    Where to send the output?

  • PierceBogganPierceBoggan USForum Administrator, Xamarin Team, Developer Group Leader Xamurai
    edited November 2017

    @zahikramer Great question! Send a DM to my forums account.

  • I second that question; I tried to attach it to my bug report on the developer community forum but got the following error: Your attachment must be one of: gif,png,jpg,jpeg,zip,tar.gz,pdf,txt,dmp,etl,mkv,mp4,log

  • RobertDurfeeRobertDurfee USMember ✭✭

    One aspect I find frustrating is on Xamarin Android projects, adding a file to the project is excruciatingly slow. This is consistent on different machines and solutions, that are all Xamarin Forms solutions with iOS, Android and UWP targets.

    For example: I add a new image, and generate all the required sizes and place them into the appropriate project folders using Windows Explorer. With "Show All Files" turned on, I right-click and include in project. On UWP and iOS, this is pretty much instant. On the Android project, this takes minutes, where Visual Studio is totally blocked and clicking anywhere will give you the dreaded "Visual Studio is busy" pop-up.

  • PierceBogganPierceBoggan USForum Administrator, Xamarin Team, Developer Group Leader Xamurai

    @RobertDurfee - Interesting! I'll be sure to give this a try and confirm on my side as well. I suspect that a full Android design-time build is taking place (which is a blocking operation in Visual Studio), which is why you're experiencing the slowness. This build is used for providing metadata to the IntelliSense service and Android designer.

    Thanks again for the heads up!

  • PaulKertscherPaulKertscher USMember ✭✭
    edited November 2017

    Dear @PierceBoggan,

    thank you very much for your efforts. Just yesterday I've searched for ways to make the iOS build faster (esp. Debug), but none of the threads I've found did help much.

    • Is this within or beyond the scope of your endeavours?
    • Are there any further options I can/should include in the build logs?
    • What about confidentiality? How much information can be retrieved from the logs provided? How is this information used?

    I've added the --time --time mtouch arguments, but I can't find any extended timing information in the build logs. Is this the correct place to search for, anyway?

    Kind regards,
    Paul

  • PierceBogganPierceBoggan USForum Administrator, Xamarin Team, Developer Group Leader Xamurai

    @PaulKertscher: iOS is definitely within the scope of my investigations. The information above should be sufficient and should work for iOS as well (with the exception of Deploy).

    If you wish for them to be confidential among the investigating team, don't hesitate to send me a DM. Diagnostic logs may contain additional metadata, like file names.

Sign In or Register to comment.