NetInverse Developers Blog

June 18, 2009
Category: .Net — Tags: , — admin @ 11:21 pm

Igor Ostrovsky’s LINQ Tips:

Check out Igor’s site.

June 7, 2009
Category: Agile — Tags: , — admin @ 9:20 pm

Hi, I’ve got some exciting news for everyone as most of this announcement involves resources or courses available on line.
We also have free events on both sides of the country. I’ve written several blogs recently, as well as done a podcast, so
some good information no matter where you are. We’re also offering another Lean Online course in another few weeks which, of
course, is also available everywhere. In Bellevue, we’re offering a new course which incorporates Lean practices into our Scrum Master
course – we call it Lean Scrum Master Certification by Net Objectives. While this is being offered in Bellevue, we’d love to offer it elsewhere
if there is enough interest. We also have free events in Washington, DC, Hampton Roads, VA, and Bellevue, WA, as well as upcoming courses
in both Washington and South Carolina. In addition to all of this, I’ve started a fun new thing based on Janice Hagy’s Indexed concept.
Finally, we have some great discounts on SQE’s Better Software Conference coming up next week – please look for us if you’re there as several of us will be.

Recent Blogs and a podcast
Since the Lean Kanban conference in Miami, I’ve had a significant number of insights into how to incorporate Lean into Agile methods as well as increased my understanding of why Scrum teams have difficulties. I discuss many of these on our blog page. The most recent blogs and podcasts are:

  • What is the Difference Between First Generation Agile (XP/Scrum) and Lean/Kanban?
  • Redefining Lean (a podcast)
  • Challenging Why (not if) Scrum Fails
  • Lean Kanban 2009 – Wow!

If you want to learn more about Lean or if you are having troubles getting Scrum to scale, you should find these of interest.

Second offering of Lean On-Line Course June 29-August 3
We got a lot of positive feedback about our Lean-Online Course we recently offered. We are offering it again at for only $395 ($345 if you register by June 10th and an even bigger discount if you had registered for the first one but weren’t able to attend – see the Yahoo discussion group for details). This includes a CD with all of the sessions (sent to you after the course) plus additional material that will be sent to you after the course (add $20 if outside of the United States). More and more people are recognizing that an understanding of Lean principles is essential if you want to make your enterprise agile. Scaling Agility can be difficult. It is important to start out with a vision for the entire organization that you want to become more effective. Lean provides this understanding.

New Course Lean Scrum Master Certification by Net Objectives in Bellevue, July 27th
We’ve been doing Scrum training (team, Scrum Master and Product Owner) for almost 9 years now. All of these courses have been done within the context of Lean, providing a better base for companies doing Scrum across more than just a couple of teams. This new course incorporates Lean practices of setting up a work-flow, directly managing work-in-process, coordinating development and test groups as well giving insights into how to coordinate multiple teams. This approach represents a significant advance of Scrum – having it both work within the context of Lean and now taking advantage of Lean practices to kick-start your teams’ progress. If your company is having difficulties getting started with Scrum, see how an integration of Lean with Scrum can accelerate the process.

This course is open to those who already have taken one of our Scrum courses (Implementing Scrum for your Team or Scrum Master Certification), a Scrum Alliance CSM course, or have been practicing Scrum for 6 months. Bottom line - you must already understand Scrum prior to attending. This is one reason our Scrum training is tops. It is unfortunate that most people attending a Scrum Alliance CSM course are going there to learn what Scrum is. This makes it difficult to cover what being a Scrum Master is as well. This course requires knowing Scrum so the full day can be focused on the Scrum Master role. Ron Jeffries, a senior CST of the Scrum Alliance agrees that more than two days of training is needed when he explains why he offers 3-day Scrum courses – “The traditional CSM course is only two days. That’s not enough time to cover the things a ScrumMaster needs to know to help their team be successful.” This course represents that necessary, third day.

Other Courses in Bellevue, WA and Columbia, SC
Implementing Lean-Agile for Your Team, Columbia, SC, June 9-10. Learn how to do Scrum within the context of Lean principles. We’re offering this course at a one-time high discount from our normal pricing to introduce ourselves into the area.

Design Patterns for Agile Developers, Bellevue, WA, July 7-9. Improve your programming skills and learn to design sustainable code in an Agile environment. Taught by the award winning author of Emergent Design – Scott Bain.

Free events around the States
The Washington, DC Lean-Agile Open, the afternoon of June 5. Business track on Enterprise Driven Software Development and Technical track on Acceptance Test-Driven Development followed by an open space to discuss your issues with our experts.

The Hampton Roads, VA, Lean-Agile Open, the afternoon of June 22. Business track on Enterprise Driven Software Development and Technical track on Acceptance Test-Driven Development followed by an open space to discuss your issues with our experts.

Sustainable Test-Driven Development, evening of July 1, Bellevue, WA. Learn what Test-Driven Development is and why it is important to do it.

The Daily Index
This is just a new fun way of communicating. Check it out.

SQE’s Better Software Conference Next week in Las Vegas!
We have a variety of discounts available - some too good to mention in a public email (really!). If you have an interest in attending, please send an email to mike.shalloway@netobjectives.com Please make sure you to mention the company you work for.

I hope you found this informative. Please let me know if there is anything we can do to help you.

Alan Shalloway
CEO, Sr. Consultant
Net Objectives. Achieving Enterprise Agility
425-269-8991

May 30, 2009
Category: .Net — Tags: , — admin @ 11:23 pm

Microsoft just released Beta 1 versions of Visual Studio 2010 and .NET 4.0, which contain its new support for parallel programming. The v1 of Parallel Extensions for .Net is part of .Net 4.0.

Parallel Extensions includes task and data parallelism, and tools for building concurrent and parallel applications. This is a sine qua non feature considering the increasing occurrence of multiple core processors, because the chips aren’t getting faster, they’re just adding more cores.

May 10, 2009
Category: Agile, Architecture, Design Pattern — Tags: — admin @ 8:59 pm
  1. On the criteria to be used in decomposing systems into modules – David Parnas
  2. A Note On Distributed Computing – Jim Waldo, Geoff Wyant, Ann Wollrath, Sam Kendall
  3. The Next 700 Programming Languages – P. J. Landin
  4. Can Programming Be Liberated from the von Neumann Style? – John Backus
  5. Reflections on Trusting Trust – Ken Thompson
  6. Lisp: Good News, Bad News, How to Win Big – Richard Gabriel
  7. An experimental evaluation of the assumption of independence in multiversion programming – John Knight and Nancy Leveson
  8. Arguments and Results – James Noble
  9. A Laboratory For Teaching Object-Oriented Thinking – Kent Beck, Ward Cunningham
  10. Programming as an Experience: the inspiration for Self – David Ungar, Randall B. Smith

by Michael Feathers. You can read the original post here.

May 2, 2009
Category: Debugging — Tags: , , — admin @ 12:37 am

When you debug the code, very oftern you need to deal with memory and registers. It would be beneficial to understand the eight general-purpose registers in the x86 processor family. Each register has a unique purpose and has special instructions and opcodes which make fulfilling this purpose more convenient or efficient. The registers and their uses are shown briefly below:

  • EAX - Accumulator register.
  • EDX - The data register is the an extension to the accumulator. It is most useful for storing data related to the accumulator’s current calculation.
  • ECX - The count register.
  • EDI - Every loop must store its result somewhere, and the destination index points to that place. With a single-byte STOS instruction to write data out of the accumulator, this register makes data operations much more size-efficient.
  • ESI - In loops that process data, the source index holds the location of the input data stream. Like the destination index, ESI had a convenient one-byte instruction for loading data out of memory into the accumulator.
  • ESP - ESP is the stack pointer. Its value is required by PUSH, POP, CALL, and RET instructions.
  • EBP - In functions that store parameters or variables on the stack, the base pointer holds the location of the current stack frame. In other situations, however, EBP is a free data-storage register.
  • EBX - In 16-bit mode, the base register was useful as a pointer. Now it is completely free for extra storage space.
Category: CLR — Tags: , , , , — admin @ 12:23 am

Precode

In .Net v2.x Precode is used to do the similar thing like Prepad.

Prepad

In .Net v1.x MethodDesc has a Prepad which contains code to call Prestub (before jitting) or jitted code.

typedef struct MethodDesc {
#ifdef _DEBUG

    LPCSTR         m_pszDebugMethodName;
    LPSTR          m_pszDebugClassName;
    LPSTR          m_pszDebugMethodSignature;
    PVOID          m_pDebugEEClass;
    PVOID          m_pDebugMethodTable;

#ifdef STRESS_HEAP
    PVOID          m_GcCover;
#else
    DWORD_PTR       m_DebugAlignPad;
#endif

    unsigned short  m_iPrestubCalls;
    unsigned short  m_iSharedSlots;
    unsigned short  m_iDirectCalls;

    unsigned short  m_DebugAlignPad2;
#endif

    DWORD_PTR      m_CodeOrIL;         // pointer to code
    WORD           m_wSlotNumber;      // entry in VTable
    WORD           m_wFlags;           // IL vs native, static vs instance ...
} MethodDesc;

When you use SOS command !dumpmd, if IsJitted is “yes,” you can run !U on the m_CodeOrIL pointer to see a disassembly of the JITTED code.

Prestub

In a CLR MethodTable, a method points to a Prestub or Jitted code. Prestub traps first calls on methods so it can JIT generate native code for them.

April 26, 2009
Category: Debugging — Tags: , , , , — admin @ 12:00 pm

Prepare the tools you need for advanced system level debugging

You can use Debugging Tools for Windows to debug drivers, applications, and services on systems that are running Windows NT 4.0, Windows 2000, Windows XP, Windows Server 2003, Windows Vista, or Windows Server 2008. You can also use Debugging Tools for Windows to debug the operating system itself. Versions of the Debugging Tools for Windows package are available for 32-bit x86, native Intel Itanium, and native x64 platforms.

The latest release of Debugging Tools for Windows is available for download (see the Using Debugging Tools for Windows section on this page). You can also install the package from the Windows Driver Kit (WDK), the Platform SDK, or a Customer Support Diagnostics CD.

Note: If you have a system with a 64-bit processor and you are debugging an application on it, you must use one of the native 64-bit packages.

Download the right tools from MSDN.

-Run windbg.exe or cdb.exe

>.hh [keyword] for help

Set up Symbols

Category: Agile, Architecture — Tags: — admin @ 11:47 am
  • Componentization
  • Better test infrastructure and tools
  • Improved logging and error models
  • Error reporting and automated updates, including hot patching
April 23, 2009
Category: .Net, CLR, Debugging — Tags: , — admin @ 10:53 pm

CLR Internal - ObjHeader

Every Object is preceded by an object header -ObjHeader (at a negative offset). ObjHeader is a DWORD and has a combination of different bit masks (defined in Syncblk.h) like hash code, AppDomain index, flags to facility string operations, thin lock bit and etc.

When the DWORD is not large enough, CLR will create a SyncBlock for the object and set the SyncBlock index in object header.

Category: .Net, CLR, Debugging — Tags: , , — admin @ 10:14 pm

CLR Internal: SyncBlock

CLR Object Internal - from Shared Source CLI Essentials

CLR Object Internal - from Shared Source CLI Essentials

Every Object is preceded by an ObjHeader (at a negative offset). The ObjHeader has an index to a SyncBlock. This index is 0 for the bulk of all instances, which indicates that the object shares a dummy SyncBlock with most other objects. All SyncBlocks are stored in SyncTable as an array and managed by SyncBlockCache.

The SyncBlock is primarily responsible for object synchronization. However, it is also a “kitchen sink” of sparsely allocated instance data. For instance, the default implementation of Hash() is based on the existence of a SyncTableEntry. And objects exposed to or from COM, or through context boundaries, can store sparse data here.

SyncTableEntries and SyncBlocks are allocated in non-GC memory. A weak pointer from the SyncTableEntry to the instance is used to ensure that the SyncBlock and SyncTableEntry are reclaimed (recycled) when the instance dies.

The organization of the SyncBlocks isn’t intuitive (at least to me). Here’s the explanation:

Before each Object is an ObjHeader. If the object has a SyncBlock, the ObjHeader contains a non-0 index to it.

The index is looked up in the g_pSyncTable of SyncTableEntries. This means the table is consecutive for all outstanding indices. Whenever it needs to grow, it doubles in size and copies all the original entries. The old table is kept until GC time, when it can be safely discarded.

Each SyncTableEntry has a backpointer to the object and a forward pointer to the actual SyncBlock. The SyncBlock is allocated out of a SyncBlockArray which is essentially just a block of SyncBlocks.

The SyncBlockArrays are managed by a SyncBlockCache that handles the actual allocations and frees of the blocks.

Each allocation and release has to handle free lists in the table of entries and the table of blocks.

We burn an extra 4 bytes for the pointer from the SyncTableEntry to the SyncBlock.

The reason for this is that many objects have a SyncTableEntry but no SyncBlock. That’s because someone (e.g. HashTable) called Hash() on them.

- syncblk.h

« Newer PostsOlder Posts »

©2009 NetInverse. All rights reserved. Powered by WordPress