PREfast, SAL and the Windows SDK


In a prior article I wrote about the benefits of the Standard Annotation Language (SAL) available in various high-end versions of Visual Studio 2005. The good news is the Windows SDK released for Windows Vista Beta 2, also includes PREfast and can therefore take advantage of the SAL-annotated CRT and Windows SDK headers. Viz:


PS C:\Program Files\Microsoft SDKs\Windows\v1.0\VC\Bin> ./cl –help


Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 14.00.50727.42 for 80x86Copyright (C) Microsoft Corporation. All rights reserved.


C/C++ COMPILER OPTIONS


<snip>


-CODE ANALYSIS-


/analyze[:WX-] enable code analysis


WX- – code analysis warnings should not be treated as errors even if /WX is invoked


I’m told that PREfast was also included in the Windows SDK February 2006 CTP release, but I have not verified it.


Finally, as you probably know by now, we wrapped up Windows Vista beta 2 today, so I would wait for the beta 2 SDK to come out anyway!

Comments (9)

  1. Alun Jones says:

    Wonderful news! It’s a shame that, although I have exactly the same version of CL in my Visual Studio 2005, it doesn’t come with PREFast. That makes me wonder if PREFast is a DLL I can add to my installation, or if I have to download the whole Vista SDK.

  2. Alun Jones says:

    Will this be available in the final release?  I can’t remember if VS2005 also had /analyze in the beta, but I’d really like to work with software that is going to last.

  3. Okay, so for the foreseeable future at least, SAL (and other code analysis goodness) is indeed available…

  4. A couple of people have asked about the relationship between /GS, SAL and ASLR in Windows Vista. Here’s…

  5. Nein says:

    Hey Michael, do you know if the version of PREfast included in the Windows SDK released for Windows Vista Beta 2 is a beta or release version?

  6. michael_HOWARD says:

    Technically it’s beta – but it’s the same tool we use on Vista 🙂

  7. &amp;nbsp;

    Web Resources

    &amp;nbsp;

    [Default] Game Developers: Make Contact in Seattle

    August…