New Innovations in the .NET Runtime

26
Andrew Pardoe ([email protected]) Program Manager, .NET Runtime New Innovations in the .NET Runtime

description

New Innovations in the .NET Runtime. Andrew Pardoe ([email protected]) Program Manager, .NET Runtime. .NET (A *Very* Simplified View). Questions? . Answers: http:// blogs.msdn.com/b/dotnet. What are we hearing from you?. Every company is becoming a software company.. - PowerPoint PPT Presentation

Transcript of New Innovations in the .NET Runtime

Page 1: New Innovations in the .NET Runtime

Andrew Pardoe ([email protected])Program Manager, .NET Runtime

New Innovations in the .NET Runtime

Page 2: New Innovations in the .NET Runtime

.NET (A *Very* Simplified View)

Runtime Ecosystem

Languages Tools

Page 3: New Innovations in the .NET Runtime

Questions? Answers: http://blogs.msdn.com/b/dotnet

Page 4: New Innovations in the .NET Runtime

What are we hearing from you?Every company is becoming a software company.

Enterprise software needs to be innovative, agile and polished.

Line of business apps must be cross-device.

Open Source enriches the platform and the community.

Enterprises have existing applications to evolve and keep running.

Page 5: New Innovations in the .NET Runtime

.NET is open and community-driven

.NET skills transfer to many scenarios

.NET will continue to be relevant

Open

Productive

Innovative

Our investments in .NET

.NET

VS SDK

Page 6: New Innovations in the .NET Runtime

• .NET Framework 4.5.1 4.5.2• ASP .NET vNext and cloud-optimized .NET• Portable Class Libraries & Universal Apps• .NET Native• RyuJIT modern JIT compiler

Session overview

Page 7: New Innovations in the .NET Runtime

• Highly compatible, in-place update of .NET 4, 4.5

• Incorporates feedback from 4.5.1 release • 7 major features, 109 bug fixes• ASP.NET improvements• HostingEnvironment.QueueBackgroundWorkItem• HttpResponse.AddOnSendingHeaders • HttpResponse.HeadersWritten

• High DPI rendering improvements in Windows Forms controls DataGridView, ComboBox, ToolStripMenuItem, Cursor

• Distributed Transactions enhancements• More robust profiling APIs for better dependency injection• ETW-based tracking on a larger .NET Framework surface area• Improved activity tracing support

.NET 4.5.2 available for download

Page 8: New Innovations in the .NET Runtime

Share early and share often

.NET is .NET, everywhere

Your feedback drives our work

Open

Consistent

Feedback

.NET Ecosystem

Page 9: New Innovations in the .NET Runtime

• New, modular, modern web stack• Ships .NET Framework as part of your web

app• Servicing events limited to critical security

issues• “Cloud optimized” framework ships with

CoreCLR

ASP .NET vNext

Page 10: New Innovations in the .NET Runtime

Making your .NET knowledge more valuable Shipping APIs across platforms on NuGet

Improved options for sharing code

Feedback-driven

• Shipping faster and across more platforms with NuGet• Problems:• Support • Discoverability

• Not every core API is portable across platforms (e.g., file)

• Portable Class Libraries improved for scalable, cross-device sharing• Universal Projects enable sharing of source and assets

• Shipping much more often• Make changes due to UserVoice and bug reports • Using light-weight public previews to collect feedback

Page 13: New Innovations in the .NET Runtime

• Microsoft NuGet packages and Portable Class Libraries (PCLs) are licensed to work cross-platform

• PCLs work in Visual Studio Express & Xamarin tools

Sharing is good

Page 14: New Innovations in the .NET Runtime

• Portable Class Libraries can depend on WinRT APIs

• PCLs can be exposed to other languages as WinMD

• WinRT is converging across Windows platforms

• Increasing the set of APIs available on all platforms

Sharing more is better

Page 15: New Innovations in the .NET Runtime

• Share source & assets between Windows 8.1 and Windows Phone 8.1 platforms

• You can even share XAML UI in the designer• Share your project directly—no need to

create Portable Class Library binaries• Create an app for both platforms from one

project

Universal Windows Apps

Page 16: New Innovations in the .NET Runtime

Conditional constants…#if WINDOWS_PHONE_APP Windows.Phone.UI.Input.HardwareButtons.BackPressed += this.HardwareButtons_BackPressed;#endif

…drive IntelliSense, syntax highlighting, emulators, etc.

Universal Windows Apps

Page 17: New Innovations in the .NET Runtime

• Completely new browsing experience with search and navigation powered by Rosyln

• Hyperlinked source code• Browsing features include

• Go to definition• Find references• Highlight references• Document Outline• Project Explorer• Namespace Explorer

http://SourceOf.net Step through .NET Framework sources when debugging your code

Browse .NET Framework source code online

Page 18: New Innovations in the .NET Runtime

• Continued investment in full .NET Framework

• ASP .NET vNext and a cloud-optimized .NET• Portable Class Libraries & Universal Apps• .NET Native• RyuJIT modern JIT compiler

Session overview

Page 19: New Innovations in the .NET Runtime

.NET code generation: A primer

Source code(C#/VB/F#)

MSIL bytecode Machine code

C#/VB/F# compiler

Code generation

Code generation is done either….• Lazily at runtime with a Just-In-Time, or JIT, compiler• Optimistically at build time with NGen, Triton or .NET Native

Page 20: New Innovations in the .NET Runtime

.NET Code Execution today

C++ PerformanceSelf-contained apps

Dynamic experience“Unlimited” class libraries

Page 21: New Innovations in the .NET Runtime

• Next Generation Compiler in the Cloud builds upon Triton for Windows Phone

• Apps compiled with .NET Native start up to 60% faster and use ~25% less memory

• Developer Preview available at http://aka.ms/dotnetnative

.NET Native (Project N)

Scenario Improvement (%)Cold Startup 39.32%Warm Startup 31.21%Memory Usage 12.68%

Wordament on .NET Native:

Page 22: New Innovations in the .NET Runtime

Visual Studio Experience for .NET NativeEnable .NET Native for your project

Debug and test your app with .NET Native

Page 23: New Innovations in the .NET Runtime

A compiler’s performance is measured in two ways:• Throughput measures how fast a compiler

generates app code. Because a JIT compiler runs before user code throughput dominates startup.

• Code quality measures how fast the generated code runs. Code quality matters most in a long-running process where code is JIT compiled once and run for a long time.

• 32-bit JIT emphasizes throughput over code quality

• 64-bit JIT emphasizes code quality over throughput

Just-In-Time (JIT) compilation

Page 24: New Innovations in the .NET Runtime

RyuJIT performance

CTP3 vs JIT64, code quality

Page 25: New Innovations in the .NET Runtime

• RyuJIT is based on JIT32 for fast throughput• RyuJIT brings optimizations from JIT64 for

great code quality• Having one JIT codebase means faster

innovation• First new feature: SIMD in CTP3• More new features to come including x86 & ARM support

• Try out CTP3 today: http://aka.ms/RyuJIT

RyuJIT is a modern JIT compiler