Archive for February, 2009

Software Generalism

Wednesday, February 18th, 2009

The class struggle and alienation in software factories brought me to final conclusion that a software generalist is the future classless software creator. Please don’t get me wrong, I’m not a Software Marxist advocating Software Marxism, Socialism or Communism. Believe me or not, Software Generalism is a much brighter future. More on this later.

- Dmitry Vostokov @ SoftwareGeneralist.com -

Software Labour and Alienation

Wednesday, February 18th, 2009

Here I provide sketches of parallels between Marx’s theory of alienation and software world. Obviously we have fine-grained classes of:

  • engineers
  • technical support
  • IT stuff
  • architects
  • managers

The notion of software factory also brings its share too. I guess the current software work place standards would be seen as nightmarish conditions to future generations of software engineers in 22nd century. 

To finish this topic with a joke: I remember one manager in one of my previous companies told me not to say “delete Manager [object]” during presentation of system architecture.

- Dmitry Vostokov @ SoftwareGeneralist.com -

Reading Notebook: 16-Feb-09

Monday, February 16th, 2009

Comments in italics are mine and express my own views, thoughts and opinions

Developer’s Guide to Debugging by M. Wloka, et al.:

DLL-specifc problems (pp. 122 -127) - For Windows, I’ve identified 2 patterns so far: http://www.dumpanalysis.org/blog/index.php/2008/04/22/crash-dump-analysis-patterns-part-59/ and http://www.dumpanalysis.org/blog/index.php/2008/06/12/crash-dump-analysis-patterns-part-59b/

-fPIC flag for GCC to generate position independent code for dynamic linking and -shared flag to generate .so files (p. 123)

ldd utility on UNIX to find required .so files (p. 124) - On Windows it can be Dependency Walker (depends.exe)

Incorrect search order problems (p. 124) - See also my pattern for Windows: http://www.dumpanalysis.org/blog/index.php/2008/06/19/crash-dump-analysis-patterns-part-64/

Analyzing loader issues, LD_DEBUG on UNIX (pp. 125 - 126) - On Windows it can be loader snap in option in gflags.exe and !dlls WinDbg command

shared library GDB command (p. 126) - corresponding WinDbg command lmv

break GDB command (p. 126) - corresponding b* commands in WinDbg

pending breakpoints (pp. 126 - 127) - corresponding deferred or unresolved breakpoints in WinDbg (bu command)

ptype and info function commands in GDB to list class methods and overloaded functions (pp. 130 and 131)

breakpoints in C++ templates, function signatures for instantiated templates vs. source code lines (pp. 131 - 132) - I need to check this with WinDbg

info breakpoints GDB command (p. 132) - corresponding WinDbg commands are bl and .bpcmds

Advanced Windows Debugging by M. Hewardt and D. Pravat:

Implicit CoInitializeSecurity with EOAC_APPID (p. 365)

ole32!g* variables (p. 366)

Client callback interfaces make gives a client a server role (p. 367)

DCOM failure logging registry keys (p. 367)

Concurrent Programming on Windows by J. Duffy:

Software Factories by J. Greenfield, et. al.:

Software Engineering Foundations: A Software Science Perspective, by Y. Wang:

Stiil busy to read last 3 books. Hope to resume them tomorrow.

- Dmitry Vostokov @ SoftwareGeneralist.com -

Reading Notebook: 11-Feb-09

Wednesday, February 11th, 2009

Comments in italics are mine and express my own views, thoughts and opinions

Developer’s Guide to Debugging by M. Wloka, et al.:

Linking order (pp. 113 - 114) - I need to check this with MS linker, how many passes does it have

Symbol clash as undetected multiple definitions (pp. 117 - 118) - I need to check this with MS linker

Symbol localization (suppressing exports) EDITBIN and LIB on Windows (p. 118) - Never used EDITBIN before. Will try

The possibility of crash due to linker mismatch or error (p. 120)

How to determine a compiler version from an object or library file? (pp. 120 - 122) - It looks like .obj files compiled by MS compiler contain all compilation options and the following string, for example: -compiler:”c:\Program Files (x86)\Microsoft Visual Studio 8\VC\bin\c2.dll”

Advanced Windows Debugging by M. Hewardt and D. Pravat:

Breaking the code path technique: freezing processes one by one and checking if this freezes the client (p. 355)

AccessCheck in RPCSS, machine access check -> machine launch check -> component-specific check for DCOM (pp. 357 - 361)

RPCSS service -> DcomLaunch service (p. 362)

Concurrent Programming on Windows by J. Duffy:

Software Factories by J. Greenfield, et. al.:

Software Engineering Foundations: A Software Science Perspective, by Y. Wang:

Didn’t have time today. Will resume notebook on Friday.

- Dmitry Vostokov @ SoftwareGeneralist.com -

Finite Sets

Tuesday, February 10th, 2009

Sets are objects that contain other objects, called elements which may be sets themselves. This can be illustrated on the following UML static class and object diagrams:

The cardinal number (cardinality) of a set is the number of its elements in the case of finite sets.  

Here A, B, SB and SC belong to SA set, C belongs to SB set and SC set is the empty set ø. In bracketed set-theoretic notation we have:

SA = {A, B, SB, SC} = {A, B, {C}, {}}

Card(SA) = 4
Card(SB) = 1
Card(SC) = 0

Note: the empty set ø = {} is a subset of any set and this is not shown on diagrams above.

- Dmitry Vostokov @ SoftwareGeneralist.com

Software and Modern Mathematics

Tuesday, February 10th, 2009

This is a forthcoming book consisting of short articles with illustrations planned to be published by the end of this year:

Software and Modern Mathematics (ISBN-13: 978-1906717582)

- Dmitry Vostokov @ SoftwareGeneralist.com -

Reading Notebook: 09-Feb-09

Monday, February 9th, 2009

Comments in italics are mine and express my own views, thoughts and opinions

Developer’s Guide to Debugging by M. Wloka, et al.:

An application as a set of processes (p. 103)

strace (Linux) and truss (Solaris) to trace OS calls (pp. 104 - 106) - On Windows we can trace API while debugging using WinDbg extensions: http://www.dumpanalysis.org/blog/index.php/2007/01/03/tracing-win32-api-while-debugging-a-process/. Process Monitor can also be used to trace API subsets like File and Registry I/O.

Compiler bugs (pp. 106 - 107)

Debugger and compiler incompatibilities (p. 107)

Link-time bugs (Chapter 9)

Missing symbols (pp. 112 - 113) - On Windows search strategies like Explorer Search and dumpbin can be useful for dynamic linking errors

Advanced Windows Debugging by M. Hewardt and D. Pravat:

The importance of lazy initialization and associated impersonation bugs (pp. 347 - 354)

Concurrent Programming on Windows by J. Duffy:

.NET programs are multithreaded from the start (gc runs on a separate thread) (p. 79) - We can see this in WinDbg when attaching it to a .NET app container

Thread as a virtual processor metaphor (p. 80)

Thread as an execution context (p. 81)

Non-local transfer of control; context switch, exception handling, hardware interrupt (borrows kernel stack), DPC and APC (pp. 84 - 85)

DPC and APC run in the context of the current thread (p. 85)

The differences of CLR (managed) threads: just additional CLR information is stored on per OS thread basis (p. 86)

Explicit threading: explicit thread creation (p. 87) with thread pool alternative (p.88)

Software Factories by J. Greenfield, et. al.:

Failure of enterprise data modeling during terminal era of 70s - 80s (p. 13)

Bifurcation of of software into personal and enterprise with the advent of PCs (pp. 15 - 16)

The notion of the phenomenon of cheaper products eventually displacing market leaders after improvement over time (p. 16)

Thick client: business rules on both tiers (p. 17)

The growth of packaged application industry and outsourcing after client-server era (pp. 18 - 21)

Software Engineering Foundations: A Software Science Perspective, by Y. Wang:

SE principles to counter SE constraints (cognitive, organizational and resource) (p. 2)

Software as a unique abstract structure (p. 7)

The notion of the intelligent behavioural metaphor (p. 7)

Inductive math-based methodology of theoretical software problems vs. deductive experiment-driven for empirical problems: both must be used for SE problems (1st Law of SE)  (p. 8)

The need for mathematical modeling of software system architecture and software behaviours (p. 9)

- Dmitry Vostokov @ SoftwareGeneralist.com -

Reading Notebook: 06-Feb-09

Friday, February 6th, 2009

Resumed my reading notebook today after more than two week break caused by finishing my Windows Debugging book.

Comments in italics are mine and express my own views, thoughts and opinions

Developer’s Guide to Debugging by M. Wloka, et al.:

Deadlock roots (circular locking and protocol mismatches in produce-consumer scenarious (p. 93)

info thread command in GDB (0. 95), thread N command to switch current thread, info stack command - In WinDbg we use ~*kv in process dumps and !process 0 ff in kernel and complete kernel dumps. Beware of WOW64 though:
http://www.dumpanalysis.org/blog/index.php/2007/01/26/note-32-bit-stack-from-64-bit-dump/ and http://www.dumpanalysis.org/blog/index.php/2009/02/06/32-bit-stack-traces-from-x64-complete-dumps/

Threading analysis tools: Intel Thread Checker and Helgrind (pp. 96 - 98) 

Environment dependency as root cause for some problems (pp. 101 - 103)

Advanced Windows Debugging by M. Hewardt and D. Pravat:

The importance of system boundaries (pp. 338 - 340)

Logical error representations by subsystems (p. 341) 

Security descriptor for debugger created thread can have different DACL (pp. 346 - 347)

Security chapter is awesome - sheds light on what described in other Win32 security books

Concurrent Programming on Windows by J. Duffy:

Software Factories by J. Greenfield, et. al.:

Software Engineering Foundations: A Software Science Perspective, by Y. Wang:

I resume reading these books next Monday

- Dmitry Vostokov @ SoftwareGeneralist.com -