The article describes some observations concerning changes in the infrastructure of tools used by programmers in everyday work. First of all, these changes are related to the release of Visual Studio 2010.
Changes in programmer toolsinfrastructureAuthor: Andrey KarpovDate: 26.04.2010AbstractThe article describes some observations concerning changes in the infrastructure of tools used byprogrammers in everyday work. First of all, these changes are related to the release of Visual Studio2010.IntroductionA set of tools used by developers is regularly updated. Some absolutely new tools appear, othersbecome obsolete and some others stop being developed and are displaced with more perfectanalogues. It is rather interesting to watch this process and I decided to share some of my latestobservations in this sphere with you.I would like to notice right away that I stick to the viewpoint that the fewer diverse tools one uses, thebetter. I am ready to be criticized for minimalism in functionality. My viewpoint is disputable but still hasthe right to exist.Automated testingSome functionality, that has been earlier available only in third-party tools, is gradually moving intodevelopment environments, in particular Visual Studio. But in the mind of developers, this functionalityis still associated only with third-party tools. For example, consider the system of automated testing ofuser application interface that appeared in Visual Studio 2010 Premium/Ultimate which lets you avoidsuch tools as AutomatedQA TestComplete or Borland SilkTest in many cases.Please do not get me wrong. I in no way persuade you to refuse using an existing test base and hurry tomove to the testing system integrated into Visual Studio 2010. And I by no means want to persuade youto use it. TestComplete is one of the most powerful commercial products intended for automation ofsoftware testing. But if you use Visual Studio 2010 and have to decide what automated testing system tochoose for the new project, I think you should not go very far. If you do not need specific features duringtesting, you will not have to buy and employ additional systems besides Visual Studio 2010.We use the user interface testing system of Visual Studio to test the PVS-Studio interface. We wereconcentrated more on testing internal units before, but as the interface component was developing, wefaced the task of moving from manual testing to automated testing. However, our demands are rathermodest and we are content that we have chosen the testing system of Visual Studio. Figures 1 and 2show some windows of the Visual Studio testing system while working.
Figure 1 - Writing of users actions in Visual Studio
Figure 2 - The tree of controls in Visual StudioThe conclusion is it is useful to study the innovations in the toolkit you are already using. If yourdemands to testing lie within the standards, perhaps you will find the functionality of Visual Studio quiteenough when developing new projects. Therefore, the number of entities (tools) you have to deal withwill not rise - and this is always good.Code editorLike with testing, it is the same with the assistant - Visual Assist. I remember how good it was to workwith it when we used Visual Studio 6.0. But many people say that this tool is useful without knowing ornoticing the contemporary capabilities of the latest Visual Studio versions. Most of the features Iappreciated in Visual Assist have been gradually implemented in Visual Studio. Beginning with VisualStudio 2008, I understood that I could well do without Visual Assist and stopped using it. As VisualStudio 2010 was released, Visual Assist became absolutely irrelevant for me.I agree that Visual Assist has some functions that will never be included into Visual Studio. And I am surethat somebody might find these functions very important or simply convenient and useful. There are alot of people for whom Visual Assist does not become less important at all but grows even moreindispensable. But personally I used very few features and did not need more. Now these needs arequite satisfied with Visual Studio environment. Let me show you some examples arming myself withVisual Studio 2010.There is the function of syntax paint. Though it is not so colorful as in Visual Assist, it is still ratherpleasant and sufficient for me. If take into account the underlining of syntactical errors, it is just quitegood (see Figure 3). Figure 3 - Highlighting of code in Visual Studio 2010 and underlining of incorrect constructsThe help system of function parameter prompting and name prompting by the first characters of nameworks quite well (see Figures 4 and 5): Figure 4 - Function parameter prompting in Visual Studio 2010
Figure 5 - Function name prompting in Visual Studio 2010There is also a feature I actually lacked for without Visual Assist. It is file name prompting. Visual Studio2010 now has this feature (see Figure 6). Figure 6 - Integrated file name prompting in Visual Studio 2010Visual Assist helped me find my way even in a very badly edited code when it was necessary tounderstand where brackets open and close. Visual Studio 2010 now also provides this functionhighlighting matching parentheses as shown in Figure 7.
Figure 7 - Highlighting of matching parentheses in Visual Studio 2010I find the Visual Studio 2010 code editor quite satisfying. Perhaps you will also look at this editor ofVisual Studio in a new way.Static analysisWhen speaking of static analysis of C++ code, programmers often have an association like this: "Theseare some tools like lint that have command-line interface and are obsolete nowadays". Let us make itout how this idea has appeared. I will not speak about companies and mature development processeswhere static analysis was used before, is being used now and will be used in future. But most developersuse immature processes. One should not be ashamed of it - it is the drawback of organizations notprogrammers. For them, a static analyzer is rather an exotic thing than an everyday tool integrated intothe development process.C is a language that requires much accuracy and attention from the programmer because its owncontrol over actions performed in the code is very weak. A more dangerous language is rather onlyassembler. Because of this, static code analysis tools appeared of which lint is the most famousrepresentative. This tool and all the other similar ones have been used rather widely due to the absenceof alternative means to detect errors at the stage of coding. They were relevant for the cycles ofdevelopment of programs with any maturity level.The new language C++ has become much safer due to a stricter level of control over types and otherinnovations. Compilers for C and C++ started to generate warnings on many potentially dangerousconstructs. They have actually undertaken the functions of existing static analyzers, and the latterbecame less popular. Many refused to use the additional analysis level provided by third-party tools atthat moment.However, static analyzers have not become obsolete at all. They have learned to detect many kinds oferrors referring to object-oriented programming, warn the programmer about incorrect use of libraries(for example, Qt) and even find errors in parallel programs. The conclusion is static analyzers, as before,let the programmer greatly reduce costs at the stage of testing and maintenance. What is good,nowadays these are usually not separate tools but units integrating into the development environment.
I would like to point out that it is the opinion itself that static analyzers are command command-line solutionswhich is obsolete. Static analyzers are contemporary tools that greatly supplement standard capabilities contemporaryof the compiler and other tools of improving software quality.For an example, let us again look at Visual Studio. Beginning with Visual Studio 2005, the Team Systemversion includes a generally-purpurpose subsystem of static analysis Code Analysis Although this system is Analysis.an extension, it is tightly integrated into the environment and working with its diagnostic warnings is thesame as with messages generated by the compiler (see Figure 8). nerated Figure 8 - Settings tab in Code Analysis in Visual Studio 2010There is another type of static analyzers - specialized analyzers. For example, it is PVS-Studio analyzerwe are developing which also tightly integrates into Visual Studio (see Figure 9) and allows you to detectmany errors in 64-bit and OpenMP programs. bit
Figure 9 - Integration of PVS-Studio into Visual Studio 2010Contemporary static analyzers are user friendly programs that may be operated both by professionalsand beginners.Dynamic analysisWhen speaking of a dynamic analyzer to search for errors of memory operation, first of all, everybodyremembers about the tool DevPartner BoundsChecker Suite. But I would like to restrain the ardor of itssupporters and those who recommend it in forums. Surely, it has been a great and indispensable toolduring a long time. Unfortunately, this project is not being developed now and is quickly becomingobsolete. For example, BoundsChecker does not support Win64 applications. It can be launched in the64-bit environment and check 32-bit applications but it cannot work with 64-bit applications. Here is aquotation from the booklet: "DevPartner Studio supports 32-bit application development on 64-bitWindows (WOW 64)".A lag like this is not permitted for testing tools. Fortunately, BoundsChecker and other dynamic analysistools have been replaced with a new titan it is best to focus on. We speak about the tool Intel ParallelInspector included into Intel Parallel Studio.Intel Parallel Studio integrates into Visual Studio (see Figure 10) and adds the function of checkingmemory and thread operations. Checking memory in Intel Parallel Inspector includes check of memoryleak, detection of pointers referring to a remote object, detection of operations with uninitializedvariables. Intel Parallel Inspector allows you to detect use of incorrect references to memory chunks,controls the stack and so on. Thread testing includes check of race conditions, mutexes, call stackanalysis with adjustable depth.
Figure 10 - Setting the diagnosis level in Intel Parallel InspectorWhat is the most pleasant, you can analyze programs built both with Intel C++ and Visual C++. There isalso support for Win32 and Win64 software analysis. Intel Parallel Studio is being stably developed, it isnot very expensive and you may safely use it for long terms.SummaryThe infrastructure of programmer tools is constantly changing. You may both find new, moreconvenient, solutions and stop using some obsolete ones (if they are not developed anymore). By theway, there are special workers (and even departments) in large companies whose only work is to watchthe development of the tools being used in the development process.