Board index » delphi » Re: Fastcode versus Highlander
JED
![]() Delphi Developer |
JED
![]() Delphi Developer |
Re: Fastcode versus Highlander2006-07-06 10:32:30 AM delphi58 Dennis writes: QuotePosEx has been replaced and the AnsiStringReplace QC report is open, Compact Framework for Delphi 2006: www.jed-software.com/cf.htm QualityCentral Windows Client: www.jed-software.com/qc.htm Visual Forms IDE Add In: www.jed-software.com/vf.htm |
Dennis
![]() Delphi Developer |
2006-07-06 03:12:34 PM
Re: Fastcode versus Highlander
Hi
QuoteI wouldn't confuse Open as meaning "will be done". Only a minor issue kept it away for being done in DeXter. Best regards Dennis Kjaer Christensen |
Peter Morris [Droopy eyes software]
![]() Delphi Developer |
2006-07-06 03:34:07 PM
Re: Fastcode versus Highlander
It must be easier to convince people in Borland these days.
When I first wrote FastReplace I talked to the guy at Borland who was responsible for maintaining routines such as StringReplace (whoever that was). After saying no to FastReplace I offered a slighty modified version of StringReplace, one that didn't keep reallocating the result. Even that simple change was many times faster than StringReplace and it didn't use any ASM or anything. Still it was turned down. It was explained to me that he didn't want to speed it up "In case somebody out there depends on how slow it is", and it is only a "fluff routine" anyway. He also went on to explain how people don't really replace text in large strings anyway. If this was the case then why not limit strings to 255 chars again eh? :-) He also wasn't aware of the gaining popularity of large text files such as HTML and XML at the time. The worst argument I have ever heard I think :-) -- Pete ==== Audio compression components, DIB graphics controls, ECO extensions, FastStrings www.droopyeyes.com My blog blogs.slcdug.org/petermorris/ |
Dennis
![]() Delphi Developer |
2006-07-06 04:26:25 PM
Re: Fastcode versus Highlander
Hi Peter
All this sounds awfull ;-( Fastcode has been quite succesfull in getting functions into the RTL. Something must have changed to the better - thankfully. Best regards Dennis Kjaer Christensen |
Jouni Turunen
![]() Delphi Developer |
2006-08-09 05:42:48 PM
Re: Fastcode versus Highlander
Hi all,
Quote
Regards, Jouni -- The Fastcode Project: www.fastcodeproject.org/ |
Q Correll
![]() Delphi Developer |
2006-08-10 01:13:56 AM
Re: Fastcode versus Highlander
Dennis,
| It is time to vote. Where can I find the current FastCode D/L's these days? The SourceForge page says nothing is [yet] available? And the FastCode page I have in my Favorites now points to SourceForge. <g> -- Q 08/09/2006 10:11:40 XanaNews Version 1.17.5.7 [Q's salutation mod] |
Dennis
![]() Delphi Developer |
2006-09-16 05:07:11 PM
Re: Fastcode versus Highlander
Hi Community
Is our current list of QC reports for function proposals for Highlander complete and correct? Fastcode RGBAtoBGRA in the RTL qc.borland.com/wc/qcmain.aspx Fastcode PosIEx in the RTL qc.borland.com/wc/qcmain.aspx Fastcode CompareStr in the RTL qc.borland.com/wc/qcmain.aspx Fastcode StrLen in the RTL qc.borland.com/wc/qcmain.aspx Fastcode Floor in the RTL qc.borland.com/wc/qcmain.aspx Fastcode Ceil in the RTL qc.borland.com/wc/qcmain.aspx Fastcode GCD32 in the RTL qc.borland.com/wc/qcmain.aspx Fastcode IsPrime in the RTL qc.borland.com/wc/qcmain.aspx Fastcode RoundToEx in the RTL qc.borland.com/wc/qcmain.aspx Fastcode CharPosEY in the RTL qc.borland.com/wc/qcmain.aspx Fastcode AnsiStringReplace in the RTL qc.borland.com/wc/qcmain.aspx Fastcode CharPos in the RTL qc.borland.com/wc/qcmain.aspx Best regards Dennis Kjaer Christensen |
Dennis
![]() Delphi Developer |
2006-09-16 05:24:40 PM
Re: Fastcode versus Highlander
Hi
What about StrIComp and Int64Mul? Best regards Dennis Kjaer Christensen |
Dennis
![]() Delphi Developer |
2006-09-16 05:45:07 PM
Re: Fastcode versus Highlander |
John O'Harrow
![]() Delphi Developer |
2006-09-17 10:54:24 PM
Re: Fastcode versus Highlander
64 bit integer multiplication is a "compiler magic" function (__llmul in
system.pas) so our challenge functions cannot directly replace the RTL version. The same is true of all 64 bit math functions in system.pas I have already raised QC's for all 11 of the 64 bit math functions in system.pas (QC #33048 .. #33058) to get faster and bug-free versions into the RTL. -- regards, John The Fastcode Project: www.fastcodeproject.org/ "Dennis" <XXXX@XXXXX.COM>writes QuoteHi |
Dennis
![]() Delphi Developer |
2006-09-18 02:13:22 PM
Re: Fastcode versus Highlander
Hi John
Quote64 bit integer multiplication is a "compiler magic" function (__llmul in QC title could be = "Int64Mul Fastcode in the RTL as __llmul". QuoteI have already raised QC's for all 11 of the 64 bit math functions in Best regards Dennis Kjaer Christensen |
John O'Harrow
![]() Delphi Developer |
2006-09-18 04:47:35 PM
Re: Fastcode versus HighlanderQuote
John |
Dennis
![]() Delphi Developer |
2006-09-19 12:02:42 AM
Re: Fastcode versus Highlander
Hi John
I have a problem with Improved 64 bit multiply __llmul qc.borland.com/wc/qcmain.aspx because you bypass Fastcode. You should propose the Int64Mul challenge winner with the Fastcode MPL license text. It migth be the exact same code, but you have ignored the Fastcode validation, benchmarking and license. You have actually voluntered to be the contact between Fastcode and Borland. Is the proposed function procedure __llmul; asm mov ecx, [esp+8] imul edx, [esp+4] imul ecx, eax add ecx, edx mul dword ptr [esp+4] add edx, ecx ret 8 end; equal to the Int64Mul_JOH_IA32_2 function just converted to fit the __llmul interface? function Int64Mul_JOH_IA32_2(var X, Y : Int64) : Int64; asm {36 Bytes} push ebx push edi lea ebx, [eax] //@X lea edi, [edx] //@Y mov edx, [ebx+4] //X-Hi mov ecx, [edi+4] //Y-Hi or edx, ecx //Both 0? mov eax, [ebx] //X-Lo jz @@LowMul mov edx, [edi] //Y-Lo imul ecx, eax //Y-Hi * X-Lo imul edx, [ebx+4] //Y-Lo * X-Hi add ecx, edx @@LowMul: mul dword ptr [edi] add edx, ecx pop edi pop ebx end; It does not look like it. Int64Mul_JOH_IA32_2 is the winner of the IA32 size penalty target. Best regards Dennis Kjaer Christensen (* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1 * * The implementation of function __lldiv is subject to the * Mozilla Public License Version 1.1 (the "License"); you may * not use this file except in compliance with the License. * You may obtain a copy of the License at www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Portions created by the Initial Developer are Copyright (C) 2002-2004 * the Initial Developer. All Rights Reserved. * * Contributor(s): John O'Harrow * * ***** END LICENSE BLOCK ***** *) // ------------------------------------------------------------------------- --- // 64-bit signed multiply // ------------------------------------------------------------------------- --- // Param 1(EDX:EAX), Param 2([ESP+8]:[ESP+4]) procedure __llmul; asm mov ecx, [esp+8] imul edx, [esp+4] imul ecx, eax add ecx, edx mul dword ptr [esp+4] add edx, ecx ret 8 end; |
John O'Harrow
![]() Delphi Developer |
2006-09-19 01:00:12 AM
Re: Fastcode versus Highlander
The __llmul function I proposed was not a modified fastcode challenge
function, as is also the case with the other 10 new Int-64 function replacements I proposed at the same time (this is the reason for there being no mention of fastcode in the license block). I have now converted this function (listed below) so that it can be tested using the B&V. If Int64MulJOH_2 is better I can always amend the QC entry. function Int64MulJOH_4(var X, Y: Int64): Int64; asm {27 Bytes} push ebx lea ecx, [eax] lea ebx, [edx] mov eax, [ecx] mov edx, [ecx+4] mov ecx, [ebx+4] imul edx, [ebx] imul ecx, eax add ecx, edx mul [ebx] add edx, ecx pop ebx end; -- regards, John The Fastcode Project: www.fastcodeproject.org/ |
Dennis
![]() Delphi Developer |
2006-09-19 01:20:44 AM
Re: Fastcode versus Highlander
Hi John
QuoteThe __llmul function I proposed was not a modified fastcode challenge Quotefunction, as is also the case with the other 10 new Int-64 function Quotereplacements I proposed at the same time (this is the reason for there QuoteI have now converted this function (listed below) so that it can be tested QuoteIf Int64MulJOH_2 is better I can always amend the QC entry. Dennis Kjaer Christensen |