Speed up building software

To speed up software building .the most common way is reuse something ready.
there are ways to create reusable stuff .make high cohesion: create function, class ,use patterns , components … what happens is, (say want class reusable) sometimes the use case is not exactly same as last time when class been created or lets say the class is has not been created perfectly but can not change it now, and 85% codes are same ,only some thing (say project name, model name etc) are different .

Continue reading “Speed up building software”

Difference between Task and new Thread

Task: is way of doing async which is same like promose in javascript . internally it’s using ThreadPool to schedule the task .and manage some states to make async program easier (like consolidate exceptions ) . more important ,Task will try utilize the best of CPU to get the ‘task’ done .

Continue reading “Difference between Task and new Thread”

.Net Coding performance

##[GC Basic]

In a managed process there are two types of heaps—native and managed. Native heaps are allocated with the VirtualAlloc Windows API and used by the operating system and CLR for unmanaged memory such as that for the Windows API, OS data structures, and even much of the CLR. The CLR allocates all managed .NET objects on the managed heap, also called the GC heap, because the objects on it are subject to garbage collection.
Continue reading “.Net Coding performance”