AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Delphi-PRAXiS - Lounge Delphi-News aus aller Welt Coming Delphi 10.4 Runtime Library Enhancements

Coming Delphi 10.4 Runtime Library Enhancements

Ein Thema von DP News-Robot · begonnen am 22. Mai 2020
Antwort Antwort
Benutzerbild von DP News-Robot
DP News-Robot

Registriert seit: 4. Jun 2010
11.764 Beiträge
 
#1

Coming Delphi 10.4 Runtime Library Enhancements

  Alt 22. Mai 2020, 11:40


Delphi Runtime Library is one of the foundations of the product, as the UI libraries such as VCL and FireMonkey and also database access libraries and many third party components reply on the core RTL. That is why changes to the RTL are particularly relevant, as they tend to affect all developers. Here are some key changes about to become available.

Bit Counting Standard Functions

We have introduced new standard functions for common low-level bit processing operations, listed below.

  • Count Leading Zeros:*Counts the number of leading zero bits preceding the most significant one bit of the parameter X. If X is zero, it returns the bit width. i.e. 32 for CountLeadingZeros32 and 64 for CountLeadingZeros64
  • Count Trailing Zeros: Counts the number of trailing zero bits following the least significant one bit of the parameter X. If X is zero, it returns the bit width. i.e. 32 for CountTrailingZeros32 and 64 for CountTrailingZeros64.
  • Count Population:*Counts the number of 1 of the parameter X. Return value will be in the range from 0 to the bit width. i.e. 32 for CountPopulation32 and 64 for CountPopulation64
Additional Features for Classic Classes

  • The TCustomIniFile class has bew methods WriteInt64 and ReadInt64
  • The*TGUID type has a new IsEmpty method
  • The Items property of the TJSONArray class is now a default array property, allowing you to write myJArray[2] rather than myJArray.Items[2]
Better Stream Buffering

The CopyFrom function of the base TStream class used to have a fixed constant buffer for copying data (set to 60K). This can be very inefficient for copying large streams. The new default is 1MB, but the method has an additional parameter you can use to provide a specific buffer size depending on the copy operation you are doing (source and target streams). The new signature of the method is

// class TStream function CopyFrom(const Source: TStream; Count: Int64 = 0; BufferSize: Integer = $100000): Int64; Performance Optimization

  • JSON reading optimization: TJSONReader is now 50% faster
  • Optimized assigning a sorted StringList to another StringList
  • RTTI performance improvements include:
    • TRttiMethod.Invoke is ~ 4 times faster
    • TVirtualInterface invocation is ~ 1.7 times faster
    • TRttiType.GetXxxx(AName) methods are ~ 10 times faster
    • For TValue several operations are faster
  • The QuickSort operation in System.Classes is now more efficient
FreeAndNil

We updated the signature of the FreeAndNil procedure, to avoid its use with interface references and other unsupported data types. It is now declared to require a reference to a TObject:

procedure FreeAndNil(const [ref] Obj: TObject); inline; This means that incorrect usage of FreeAndNil will now cause a compiler error. In the past, incorrect usage would not be caught, leading to difficult bugs. Note that although the parameter is declared as const, the by-reference variable is indeed modified.

Additional Assorted Features

  • We have removed some dependencies blocking certain console apps to run on *Windows Server Core
  • The TStringHelper.GetHashCode method has been updated not to uppercase the string before hashing it, so its result matches other internal operations like the TStringComparer class.
That's just a partial anticipation. We also did quite some work on the Parallel Programming Library, AppTethering, the REST and HTTP client libraries and more of the other Delphi RTL subsystems. Hope these improvements, even if relatively minor, will be appreciated for their positive impact in every day Delphi developers work.

This is a preview of an upcoming release of RAD Studio. There can always be last-minute bugs or changes. Nothing here is final until the release is officially made available. Sign up for our 10.4 launch webinar next week.



Weiterlesen...
  Mit Zitat antworten Zitat
Themen-Optionen Thema durchsuchen
Thema durchsuchen:

Erweiterte Suche
Ansicht

Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 07:48 Uhr.
Powered by vBulletin® Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2020 by Daniel R. Wolf