RAD Studio 2010: Community pulse: The day after. (Part 2)

TThreadSome interesting topics about RAD Studio 2010:

The fastest fix ever?

With few days before release, there was a very hot thread in .public.non-technical forum, called  ‘Fatal threading model!’. The issue mentioned there was fixed in the official version released shortly after:…


  TThread = class
  private type
    PSynchronizeRecord = ^TSynchronizeRecord;
    TSynchronizeRecord = record
      FThread: TObject;
      FMethod: TThreadMethod;
      FProcedure: TThreadProcedure;
      FSynchronizeException: TObject;
    end;
  private
{$IFDEF MSWINDOWS}
    FHandle: THandle;
    FThreadID: THandle;
{$ENDIF}
{$IFDEF LINUX}
    // ** FThreadID is not THandle in Linux **
    FThreadID: Cardinal;
    FCreateSuspendedSem: TSemaphore;
    FInitialSuspendDone: Boolean;
{$ENDIF}
    FCreateSuspended: Boolean;
    FTerminated: Boolean;

  //snipped

  public
    constructor Create(CreateSuspended: Boolean);
    destructor Destroy; override;
    procedure AfterConstruction; override;
    // This function is not intended to be used for thread synchronization.
    procedure Resume; deprecated;
    // Use Start after creating a suspended thread.
    procedure Start;
    // This function is not intended to be used for thread synchronization.
    procedure Suspend; deprecated;
    procedure Terminate;
 //...etc...

Do you note the Deprecated keyword next to Resume and Suspended? Also, the new Start procedure? From what I remember, this is the fastest official fix delivery in any Delphi version. And the decision was based (almost) entirely on community feedback. I think that this is very important because nowadays everything which one can program, the other can program it too. The key of success is how fast you cover an emerging need of your user base. For this they need to have a “user base” to communicate with (and here the responsibility is on both sides), and after they’ll find the common wavelength they need to try to minimize their response time. Yes, the things get better but still… And when I say ‘but still…’ I do not imply heroics. Usually a better thinking, a better cooperation, leveraging the other’s experience yields way better results than a ‘march of death’ stretched over countless days and nights.

Nothing to see in the source code… Or perhaps…

I posted a larger snippet above in order to show the LINUX IfDefs. But there are other pieces of code like the following one in SysUtils.Pas:


unit SysUtils;

{$H+,B-,R-}
{$WARN SYMBOL_PLATFORM OFF}
{$WARN UNSAFE_TYPE OFF}

interface

uses
{$IFDEF MSWINDOWS}
Windows,
{$ENDIF}
{$IFDEF POSIX}
Types,
{$IFDEF MACOSX}
MiniLibc,
{$ELSE !MACOSX}
Libc,
{$ENDIF !MACOSX}
{$ENDIF}
SysConst;

Of course all these strange IFDEFs doesn’t do anything. Yet… 😉

Yes, the future is beginning to take shape in Delphi 2010. And speaking about the future, can you answer the following? Your feedback will shape the future:

And…

Thank you for voting!

As  usual, most probably we’ll post the results with few comments around. Waiting for your feedback.

13 thoughts on “RAD Studio 2010: Community pulse: The day after. (Part 2)

  1. Oh, OK, DelphiFeeds was blocking it.

    Your Poll doesn’t allow for the common D7 (Help) and D2007 simultaneously situation.

  2. Ack! Google Reader(and, I assume, any other RSS readers out there) is still showing the “windwings” string instead of excerpts.

    If you’d like I can make a screenshot.

    I do like the site though. 😉

  3. I’ld love to use D2010 (I have it on SA), but at the moment:

    1)What appear to be bugs in Datasnap mean I need have to stick with D2009.

    2) If I compile an application in D2009 it is 6,733kb, but in D2010 it comes out at 8,781kb: that’s rather a big change. Perhaps it’s just me – but all my applications seem to get significantly bigger.

    • 1. What bugs?
      2. This is due of new RTTI enhancements. IIRC you can disable the most of it (if not entirely). It is such a big change for you? Why? (What are your constraints?)

      • 1. embarcadero.public.delphi.database.multi-tier: “Bug in DBExpress/Datasnap for D2010?” 27 Aug 2009

        2. Have an upgrade system which updates executables on the client machine using Datasnap. Executables being bigger slows it down – especially if you have quite a lot of executables – the increase is size becomes quite signficant. Not the end of the world as we can compress things more – but just a bit of a surprise.

        Thanks for letting me know this is due to the RTTI: I thought it might be my fault!

  4. See Delphi still does not allow to set the thread stack size. Time to file a QC entry, their implementations are always “the very least we can do”.

    BTW, the “Linux” ifdefs in classes.pas are there since Kilyx 1 and Delphi 6, AFAIK.

  5. Pingback: Community pulse: Delphi Poll Results « Wings of Wind Software

  6. Pingback: TThread.resume is deprecated in Delphi-2010 what should be used in place? – w3toppers.com

Leave a comment