From: "Alexei A. Frounze" Newsgroups: comp.os.msdos.djgpp Subject: Re: compiler efficiency Date: Thu, 18 Jan 2001 01:28:23 -0500 Lines: 53 Message-ID: <9462ch$c77dg$1@ID-57378.news.dfncis.de> References: NNTP-Posting-Host: pppa45-resalerochester3-5r7104.dialinx.net (4.4.209.234) X-Trace: fu-berlin.de 979799251 12819888 4.4.209.234 (16 [57378]) X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4133.2400 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Believe me GCC is quite good at optimization (well, when you helped it with nice algorithm and source). Around a year ago I had a bet in this NG that I can make a faster implementation of my texture mapper in C+ASM mix rather than nearly plain C. But in fact, eventually I got nearly the same thing when used 100% of GCC capabilities and no extra ASM at all (well, probably just 1 or 2 ASM instructions which is not a lot :). I was also wondered by the fact that GCC beats Watcom. I've thought that Watcom is one of best C compilers before I got GCC. But when I saw than my 3d-engine comiled by Watcom is about twice as slow as compiled by GCC... :) Happy coding with GCC! -- Alexei A. Frounze alexfru [AT] chat [DOT] ru frounze [AT] ece [DOT] rochester [DOT] edu http://alexfru.chat.ru http://members.xoom.com/alexfru/ http://welcome.to/pmode/ "Mike Darrett" wrote in message news:Pine DOT GSO DOT 4 DOT 21 DOT 0101172014390 DOT 7634-100000 AT sandman DOT ucdavis DOT edu... > Hi guys, > > I was running some algorithm benchmarks on DJGPP vs Borland C++ 5.5, and > was shocked to see that DJGPP outperformed Borland C++ on some stack > tests. Using a linked list to simulate a stack, adding and removing 80,000 > entries took 1.8 seconds on my AMDK6-2 350, but took 2.5 seconds on > Borland C++, compiled without the -tW option (since it is a console app). > > Any ideas? Is Borland C++ using thunking to access memory? Is DJGPP simply > more efficient? Would like to get any input before I try optimizing the > code any further. > > This was a homework assignment, but was meant only to test different > algorithms vs each other, and not vs other compilers. The homework > assignment can be seen > at: http://wwwcsif.cs.ucdavis.edu/~davis/110/prog1.html > > Thanks, > > Mike Darrett > mrdarrett AT ucdavis DOT edu > http://mdarrett.freeyellow.com > > Get a free Windows C++ compiler! With STL, OpenGL and DirectX support. > http://www.borland.com/bcppbuilder/freecompiler/ > >