flat assembler
Message board for the users of flat assembler.

Index > Heap > C++ vs Object Pascal

Goto page Previous  1, 2, 3  Next
Author
Thread Post new topic Reply to topic
JohnFound



Joined: 16 Jun 2003
Posts: 3500
Location: Bulgaria
JohnFound
Ah, yes. It was "@" (at) to return the pointer of something. It was more than 10 years ago. Smile
Post 16 Jan 2013, 21:52
View user's profile Send private message Visit poster's website ICQ Number Reply with quote
f0dder



Joined: 19 Feb 2004
Posts: 3170
Location: Denmark
f0dder
JohnFound wrote:
f0dder, I also moved from Pascal.
But to FASM, not to C/C++. Wink

Well, I moved from TP6 -> TP/BP7, picking up x86 during that timeframe. Did a little bit of 16bit pmode in pascal, then moved to 32bit pmode asm with some assembler which name I can't even remember, the Borland C++ 5 (mostly C, a little C++, some assembly) because it could create 32bit executables (for windows) that were DOS extendable... then has followed a mix of various C++ compilers and x86 assemblers, and (in no particular chronological nor exerpience+level order) the usual html+xml+json+javascript+css, perl, python, Lua, Java, Ruby, C#, Scala. So I've never ended at one language. I still need to move a little more beyond the C-like language family, I'm considering picking up F# next (it's different but in the comfort zone, and has good tooling). But anywaym for some reason, it's C++ "I fall back to". I guess it's a mix of supporting several different programming paradigms, having a syntax that while sometimes ugly is comfortable for the 90%-coding part, has pretty good performance for a HLL, and allows super linking to anything with a C interface (and thus assembly modules).

I wish there were a few more situations where it was the right tool for the job Smile

LocoDelAssembly wrote:
f0dder, JohnFound, just to keep the "fighting" going Very Happy : What do you think about pointer syntax for both declaration and dereference on things like pointers to functions/procedures, variables, double indirection (anything else?).

It's absolutely horrible in C++. It does need to support some relatively complex things - one thing is various types and levels of indirection, and another being able to differentiate between "const pointer to mutable, mutable pointer to const, mutable pointer to mutable, and const pointer to const". it's one of the worse parts of C++'s syntax.

The good thing is that you very rarely need to do these constructs. And when you do, you can construct individual parts via typedefs, which makes the finaly step almost readbly. Yep, horrible part of C++, but not something you should have to deal with very often.

LocoDelAssembly wrote:
Spool, actually not so much in the case of Pascal (or at least TP, Delphi, FreePascal as I remember). I don't remember how Pascal handled pointer arithmetic though, I remember it was possible, but can't recall whether adding one advanced the pointer by one byte or one data unit.

I recall raw pointer manipulation to be rather horrible in Pascal, but that was very colored by 16 bit addressen. Declaring pointer types seemed saner though, even if you couldn't tell the compiler as precisely which kind of pointer type.

JohnFound wrote:
In the OOP, the objects are actually pointers to the object instance. But the syntax mimics normal variables, which is really useful, because it makes the syntax very clean.

I've been pondering on that one for several years - in Java and C# I definitely enjoy being able ot just write "object.property", knowing fully and well that there's pointer indirection. In C++, I've gravitated towards the pointer deref syntax not being too bad after all - when adopting "treat input parameters as const, try to keep member variables immutable" (inspired by functional programming ideas), you'll almost never be dealing with pointers, you'll be using const references - which use the object.field syntax (even though *possibly* causing indirection). The objptr->field syntax is reserved for output parameters and mutable members, which gives you a great visual clue which code is read-only and which is read-write.

And wasn't there some "variable^" syntax to denote pointer deref, and thus "object^.field" syntax? Did they do away with that for later Object Pascal syntax?

_________________
Image - carpe noctem
Post 17 Jan 2013, 02:02
View user's profile Send private message Visit poster's website Reply with quote
ASM-Man



Joined: 11 Jan 2013
Posts: 65
ASM-Man
JohnFound wrote:
Pascal rules! Smile Object Pascal is better language than C/C++ and generally all "curly bracket languages". As HaHaAnonymous already said - it is much more readable.
Of course, FASM is even better. That is why I abandoned Delphi programming at all.


WOW. So are you using FASM as main/default programming language?

_________________
I'm not a native speaker of the english language. So, if you find any mistake what I have written, you are free to fix for me or tell me on. Smile
Post 17 Jan 2013, 04:05
View user's profile Send private message Reply with quote
ASM-Man



Joined: 11 Jan 2013
Posts: 65
ASM-Man
TmX wrote:
f0dder wrote:
More complexity, yes, but most at it in the compiler end - reducing the complexity for programmers. This is A Good Thing(TM). Autos (judiciously used!), ranged-based for and lambdas can really reduce your code complexity, and result in some pretty beautiful and easy to read code - with decent enough performance as well. Move semantics are wonderful for performance. Initializer lists + Uniform initialization are nice pieces of syntactic sugar.


And of course, only hardcore UNIX geeks who insist to write everything in C.

Very Happy


It's changing. The peoples from GNU project is moving from C to C++. Look at to gcc 4.6 where they have mixed C and C++ in the GCC compiler and the gcc 4.7 that's written in C++. There is another GNU's implementations written in pure C++.
Another example is myself,I'm leaving the C++ haters group.

Another example is myself,I'm leaving the C++ haters group. That makes no difference in the world. hahaa But I'm just saying that the peoples(like me) are changing your opinion about C++ language. But I still think C++'s OP sucks.

_________________
I'm not a native speaker of the english language. So, if you find any mistake what I have written, you are free to fix for me or tell me on. Smile
Post 17 Jan 2013, 04:14
View user's profile Send private message Reply with quote
JohnFound



Joined: 16 Jun 2003
Posts: 3500
Location: Bulgaria
JohnFound
ASM-Man wrote:
WOW. So are you using FASM as main/default programming language?


Yes. Besides the hobby programming, I am using FASM on my job. I have several serious projects realized, about industrial machinery control, using FASM. The later one (still not finished) uses assembly written web server in order to provide remote human-machine interface.

_________________
Tox ID: 48C0321ADDB2FE5F644BB5E3D58B0D58C35E5BCBC81D7CD333633FEDF1047914A534256478D9
Post 17 Jan 2013, 04:35
View user's profile Send private message Visit poster's website ICQ Number Reply with quote
AsmGuru62



Joined: 28 Jan 2004
Posts: 1408
Location: Toronto, Canada
AsmGuru62
C++ is only awful if ALL of its features are used in one program.
Personally, I use C++ as it was drafted looong ago.
Post 17 Jan 2013, 15:16
View user's profile Send private message Send e-mail Reply with quote
f0dder



Joined: 19 Feb 2004
Posts: 3170
Location: Denmark
f0dder
AsmGuru62 wrote:
C++ is only awful if ALL of its features are used in one program.

I'd say the problem isn't "all of its features used in one program", but "features used needlessly and carelessly" - which is close to "all features used", but subtly different. You might very well be using a lot of really tricky code with template metaprogramming and heavy amounts of language features under the hood through some library (like Boost), to achieve simple & clean use at the client side.

But sure, the "so ein Ding muss ich auch haben" kind of programming is to be frowned upon; using language features just because you can (either to appear cool & wizardly, or simply "because of the fun of it") is bad.

Still, for some modules, functional-style programming might work best - other places it might be mostly procedural (using C++ basically as a "super-C"), and yet again other places fullblown OOP is what you need. And there might even be some instances where heavy operator overloading can make sense (e.g. a mini-DSL inside C++). For a large project, it's not unthinkable that the project as a whole ends up using a very large amount of language features - but as long as each module is kept in a clean and coherent style, that's not a problem Smile

AsmGuru62 wrote:
Personally, I use C++ as it was drafted looong ago.

Humm, as long as you don't write code as most people seemed to do back in pre/early 2000's Razz - there's a lot of horrid code out there, and horrid teaching material as well. I think it was close to mid 2k before "good" C++ stuff started appearing on teh intarwebz.

_________________
Image - carpe noctem
Post 17 Jan 2013, 17:53
View user's profile Send private message Visit poster's website Reply with quote
rugxulo



Joined: 09 Aug 2005
Posts: 2341
Location: Usono (aka, USA)
rugxulo
This is an impossible debate to win. There is no obvious answer. Any general purpose language (including whatever variant of Pascal or C++ you're using) can get data, crunch it, and spit out some results. Anything more than that is likely to be an environmental dependency. These days, as long as something works on POSIX or Windows, somebody calls it "portable", but for me, true portability is working in as many environments as possible. But that's usually difficult because you can assume almost nothing in common.

Yes, it's easy to say certain languages are "better" than others, but usually they have heavier runtime requirements, don't run on less popular platforms (cpu arch + OS), or just have much more detailed specifications. This is what I call creeping featurism, everybody seems to one-up the other guy ever six months or so. "My (C++)++)++ can do xyz, upgrade now! Faster, better, flashier!" A lot of so-called languages (and implementations) fall into this trap. (Keep in mind that there are many OSes and languages that omit those features you "can't live without" and still work fine.)

Pure syntax can be slightly worse in some languages. Maybe it's harder to learn, harder to parse, hard to read or understand or fully use, but as long as the output is the same, somebody somewhere will use it, even if you don't like it. It doesn't have to be perfect, it just has to work.

Anyways, if a language / compiler / platform gets less love (or elbow grease) than others, it's easy to misdiagnose it as the weak spot instead of realizing that there's always more that can be improved. However, one of the problems with computers is trying to interoperate, which is hard when things change too much. You have to stabilize at some point or nothing will ever get done. Unfortunately, it's hard (or even impossible) to totally get everyone to agree, hence why we have so many competing technologies.


Last edited by rugxulo on 21 Jan 2013, 19:17; edited 1 time in total
Post 21 Jan 2013, 18:58
View user's profile Send private message Visit poster's website Reply with quote
rugxulo



Joined: 09 Aug 2005
Posts: 2341
Location: Usono (aka, USA)
rugxulo
How would you choose which language to use? (Or are you a part of a group where the language is decided for you?)


  • specification (standard?)
  • host (architecture + OS)
  • target (architecture + OS)
  • compiler (which?)
  • associated tools (which?)
  • compile times
  • optimization (runtime speed)
  • error checking
  • debugging
  • extra features
  • cost
  • experience, familiarity, comfort, taste, etc.


BTW, there is no reason you can't alternate languages for projects or even mix multiple languages within the same one.

P.S. "A poor carpenter blames his tools."
Post 21 Jan 2013, 18:59
View user's profile Send private message Visit poster's website Reply with quote
rugxulo



Joined: 09 Aug 2005
Posts: 2341
Location: Usono (aka, USA)
rugxulo
BTW, just for the record, over the past three years, I have become a fan of Wirth-ian languages (also sometimes called Algol-inspired in that tradition due to history.) Here's a few things I've learned:

Just having a decent official standard or two (ISO 7185, ISO 10206) isn't enough to make a language well-supported or popular. Just like Latin spawned many offshoots and is now "mostly" dead, the same has happened to Pascal (etc).

BTW, I don't claim to be great at understanding OOP nor do I think it's totally necessary, but almost every language these days has it, for good or bad. "Object Pascal" is actually not standard at all, not even close. There was an unfinished draft ANSI spec circa 1993, but it was mostly ignored. GPC appears to claim to optionally implement part of this. Old MS Pascal had another variant, which is incompatible with TP OOP syntax as well. Delphi was originally called "Object Pascal" until whatever version (4? 5?), yet it has yet another OOP syntax ("class") vs. the older TP ("object") form.

Latest FreePascal (2.6.0), AFAIK, claims to mostly support Delphi 7 as well as additional features. I'm not sure exactly where or when certain things were added, but FPC supports generics, exceptions, ANSI strings (refcounted), properties, among other things. However, keep in mind that (just as "Pascal"), FPC has changed much over time: it started entirely as a 32-bit DOS clone of "Turbo Pascal"! (Only later did it move almost entirely to preferring Delphi language and other more modern platforms.)

BTW, keep in mind that C++ has indeed changed a lot since 1979, 1984, etc. (AT&T 2.0, 2.1, 3.0) GCC 4.8.0 (almost finalized) is compiled as C++03 (C++98 + '03 corrections?) nowadays. (And of course Clang is written in C++ as well.)

P.S. As alluded to in previous post, many languages consider themselves 100% replacements for others, e.g C++, C#, D, Objective C, Ada, Modula-3, Oberon, etc. So even if you were to erroneously think that Pascal (in whatever form) is "dead" or "obsolete", there are many spiritual successors still out there. Though, again, I'm not sure it's fair to compare most languages as they aren't very portable and are too heavyweight (creeping featurism) for their own good. "All the world's a VAX." Sad
Post 21 Jan 2013, 19:17
View user's profile Send private message Visit poster's website Reply with quote
Spool



Joined: 08 Jan 2013
Posts: 154
Spool
[ Post removed by author. ]


Last edited by Spool on 17 Mar 2013, 10:57; edited 1 time in total
Post 21 Jan 2013, 20:56
View user's profile Send private message Reply with quote
KevinN



Joined: 09 Oct 2012
Posts: 161
KevinN
Where FORTRAN?
Post 21 Jan 2013, 21:01
View user's profile Send private message Reply with quote
f0dder



Joined: 19 Feb 2004
Posts: 3170
Location: Denmark
f0dder
Quote:
P.S. "A poor carpenter blames his tools."

...and a good carpenter wouldn't use a hammer when what he needs is a saw Smile
Post 21 Jan 2013, 21:03
View user's profile Send private message Visit poster's website Reply with quote
f0dder



Joined: 19 Feb 2004
Posts: 3170
Location: Denmark
f0dder
rugxulo: decent observations. A couple of comments:

rugxulo wrote:
These days, as long as something works on POSIX or Windows, somebody calls it "portable", but for me, true portability is working in as many environments as possible. But that's usually difficult because you can assume almost nothing in common.

To a lot of people, "portable" means "a handful of linux distros" - not even POSIX (often BSD developers need to fix up linuxisms), and possibly not even several CPU architectures (hopefully x86 and x64, but not necessarily anything with whacky requirements like aligned word access).

It is hard to write portable code - and C/C++ isn't the easiest language to do it in. And apart from language, there's also runtime... either you need a huge language runtime, or you need to manually abstract the cross-OS functinality you need (or depend on 3rd party libraries). The languages that run on the JVM does have an advantage here, with the huge amount of libraries and frameworks available... but Java is somewhat heavy, and definitely isn't write-once-run-everywhere, at least not if you need things like a GUI Smile

rugxulo wrote:
(Keep in mind that there are many OSes and languages that omit those features you "can't live without" and still work fine.)

I guess it's one of those "productivity" and "maintainability" things. Take for instance the LINQ snippet in another post. It might be slower than doing things manually, and you could probably blow it to kingdom come speedwise in C++ or assembly. The important thing, though, is that those 4 lines don't require any comments to be readable (the last toList , and replaced 30 lines that were relatively messy.

rugxulo wrote:
BTW, keep in mind that C++ has indeed changed a lot since 1979, 1984, etc. (AT&T 2.0, 2.1, 3.0) GCC 4.8.0 (almost finalized) is compiled as C++03 (C++98 + '03 corrections?) nowadays. (And of course Clang is written in C++ as well.)

Indeed. I'm not actually sure whether C++ is in better shape than Object Pascal wrt. standardization... sure, there's formal specs - but there's a wide range of compilers out there, supporting different versions of C++, and probably none of them that implement their chosen spec 100% correctly. At least there is a spec, though Razz

Btw, I don't believe in One True Language, nor do I believe that there's necessarily one right tool for the job - but for a given project, some tools are better suited than others. Polyglot programming ftw Smile

There's obviously different parameters to go by depending on your kind of project. For something enterprisey, 'they' will usually want a mature-and-proven language that seems stable enough to be around the next many years, have easy access to replacable developers, and decent tooling. For a hip startup, the requirements will be different Smile
Post 21 Jan 2013, 22:06
View user's profile Send private message Visit poster's website Reply with quote
OzzY



Joined: 19 Sep 2003
Posts: 1029
Location: Everywhere
OzzY
Ok. So I've tried Free Pascal variant of Pascal and I must say I'm impressed.

Here are some things I noticed:
- Together with Lazarus IDE it's VERY FAST to create applications, including database and stuff.

- FPC is a very fast compiler.

- Pascal language is actually nice when you have all FPC extensions.

- It was easy to cross-compile to lots of platforms using Code Typhon: http://www.pilotlogic.com/sitejoom/index.php/codetyphon

Win32, Win64, Linux 32, Linux 64, Mac OS X, Android, iOS, GBA, Wii, it's all there. Shocked

I realize to succeed commercially you need to deliver your project very quick and support as many platforms as you can. Lazarus/fpc does that. I think I'll try it more.
Post 24 Jan 2013, 14:22
View user's profile Send private message Reply with quote
TmX



Joined: 02 Mar 2006
Posts: 821
Location: Jakarta, Indonesia
TmX
OzzY wrote:

- FPC is a very fast compiler.


Probably you'll be amazed more if you notice FPC & GCC compilation time.
On my Windows & Linux box, I can build FPC itself in less than 5 minutes.
GCC is... more than 1 hour. Plenty of time for cooking dinner & watching TV.
Probably there's something wrong... Laughing
Post 24 Jan 2013, 16:32
View user's profile Send private message Reply with quote
rugxulo



Joined: 09 Aug 2005
Posts: 2341
Location: Usono (aka, USA)
rugxulo
TmX wrote:
OzzY wrote:

- FPC is a very fast compiler.


Probably you'll be amazed more if you notice FPC & GCC compilation time.
On my Windows & Linux box, I can build FPC itself in less than 5 minutes.
GCC is... more than 1 hour. Plenty of time for cooking dinner & watching TV.
Probably there's something wrong... Laughing


Pascal has (at least "traditionally") been faster and easier to parse, being LL(1). (C needs a symbol table for typedef ambiguity.) FreePascal 2.x added a built-in assembler (allegedly very big speed increase), hence no need to shell out just to assemble to object file. The Win32 version even has built-in linker for faster speed. (GNU ld is not the best nor fastest linker, by far. Though using Gold may help, at least for ELF systems.)

GCC is always faster on *nix for various reasons (since fork is optimized heavily there), esp. compared to slower API emulation like Cygwin. Did you "--enable-languages=c" or leave as default (thus building most frontends and runtimes also)? I don't know if FPC can multithread (much, if at all) yet, nor if rebuilding can easily use "make -j4" or similar. But anyways, GCC used to be much much faster to build (e.g. 2.7.2.3 could rebuild on a P166 in ten minutes, and that was relatively slow DOS/DJGPP), so it's just newer bloat / added features, optimizations, etc. You could always try again compiling it with Clang or -O1 or whatever. (Were you using precompiled headers?) Various other C compilers are faster than GCC anyways, but that's usually at expense of omitting optimizations, targets, features, etc. TCC (TinyC) is faster, one-pass, built-in assembler and linker, but much weaker optimizations. (Though I agree, I wish GCC was faster, esp. for -O0 .)
Post 24 Jan 2013, 23:06
View user's profile Send private message Visit poster's website Reply with quote
TmX



Joined: 02 Mar 2006
Posts: 821
Location: Jakarta, Indonesia
TmX
rugxulo wrote:

Pascal has (at least "traditionally") been faster and easier to parse, being LL(1). (C needs a symbol table for typedef ambiguity.)


Interesting. I'll do a little research about this.
Another insight, btw:
http://prog21.dadgum.com/47.html


rugxulo wrote:

GCC is always faster on *nix for various reasons (since fork is optimized heavily there), esp. compared to slower API emulation like Cygwin. Did you "--enable-languages=c" or leave as default (thus building most frontends and runtimes also)? I don't know if FPC can multithread (much, if at all) yet, nor if rebuilding can easily use "make -j4" or similar.


The last gcc I tried to build was GCC 4.5 (both on Linux and Windows). I only enabled C & C++, and the compilation time took more than 1 hour (yes, Windows was way slower). Of course I didn't mess with compilation options much. And probably this was due to "3-step bootstrapping process".
Post 25 Jan 2013, 04:46
View user's profile Send private message Reply with quote
HaHaAnonymous



Joined: 02 Dec 2012
Posts: 1180
Location: Unknown
HaHaAnonymous
OzzY wrote:
How does Object Pascal TODAY compares to C++?

I think if people compared without looking at money, industry standard, and focus only in quality, features, and logic. I think Object Pascal would be compared better overall.

OzzY wrote:
I've been looking recently at Free Pascal (and the Lazarus IDE). It's a very interesting project as it aims to compile Delphi apps and it supports multiple platforms.

I feel that the need of being Delphi compatible is not as needed anymore, but it still is appreciated.

OzzY wrote:
If anyone here uses it, what are your thoughts?

I already tried to program in C/C++ (mainly motivated by "mass media"), "many" times (all I know today is the basic syntax rules and types, which is enough to decipher other people's code). Despite all the people bashing the Free Pascal compiler, I always preferred it because I felt it was more logical, and clean than its competitors (especially C). While maintaining near the same basic attributes (portability, performance, features).

And after I learned more tricks and features of Free Pascal recently, I don't think it is gonna change soon.

While GCC can still generate faster code, and in most cases that does not mean much. I still think the readability and possibilities Free Pascal offer is enough to compensate that, even if it was 2x speed penalty. If I want to optimize critical code I'd use assembly anyway.

And there are those people who say it is for newbies who are learning and bla, bla, bla. All bullshit, it is a quite sophisticated compiler actually.

I can say "Free Pascal" is my favorite compiler (yea, I do use a compiler. And a LOT), and "FASM" is my favorite assembler (yea, I use an assembler too). Coincidentally, both start with an "F". LOL!
Post 07 Jul 2016, 06:19
View user's profile Send private message Reply with quote
rugxulo



Joined: 09 Aug 2005
Posts: 2341
Location: Usono (aka, USA)
rugxulo
Hi,

3.5 years later ... Cool Cool

HaHaAnonymous wrote:
OzzY wrote:
How does Object Pascal TODAY compares to C++?

I think if people compared without looking at money, industry standard, and focus only in quality, features, and logic. I think Object Pascal would be compared better overall.


I think the brainwashing towards C++ is too strong. They all just know it's better, even without knowing why.

Of course, the POSIX crowd will never switch away from C/C++, but on Windows you presumably have to use what everyone else uses (MSVC, MinGW, C#/.NET, etc).

C++11/14/17 generates a lot of buzz. "It's NEW!!!1"

Quote:

OzzY wrote:
I've been looking recently at Free Pascal (and the Lazarus IDE). It's a very interesting project as it aims to compile Delphi apps and it supports multiple platforms.

I feel that the need of being Delphi compatible is not as needed anymore, but it still is appreciated.


I disagree, it wouldn't be worth much (to me) without some form of dialect compatibility. Though "delphi" isn't my preferred dialect, and there are several others supported too.

Sure, you can invent your own dialect (or even new language), but reinventing the wheel is rarely popular for long. Eventually the novelty wears off, people get bored, move on to other projects, change architectures, retire, etc.

While standards are often baroque, expensive, and heavily ignored (esp. test suites), I do think ("in theory"!) that they are worthwhile. The real problem is that portability is a lot of work, and most developers just don't care (maybe because the entire computing world reinvents itself, incompatibly, every few years).

Quote:

OzzY wrote:
If anyone here uses it, what are your thoughts?

I already tried to program in C/C++ (mainly motivated by "mass media"), "many" times (all I know today is the basic syntax rules and types, which is enough to decipher other people's code). Despite all the people bashing the Free Pascal compiler, I always preferred it because I felt it was more logical, and clean than its competitors (especially C). While maintaining near the same basic attributes (portability, performance, features).


Classic C isn't bad, but it's definitely too complicated. Classic Pascal wasn't badly designed either, but it couldn't do everything for everyone. Both had "dark corners". It's very easy to nitpick either one or say that they're roughly similar (false equivalence to discount any minor advantages in the other).

The old cliche (from BWK's 1981 paper) is only half true at the smallest level. (Heck, 90% of his complaints were already solved by Modula-2, and that's ignoring Extended Pascal, aka ISO 10206, or Oberon or ....)

FPC does have some advantages, but (as with any deficiencies in software) there are always workarounds for the alternatives.

Just to mention some obvious advantages (Free Pascal vs. C): safer pointers and arrays, better strings, stricter typing, better modularity, etc. Heck, you can easily link with C code!

But there is no "one size fits all" (language, dialect, compiler, OS, architecture).

Quote:

And after I learned more tricks and features of Free Pascal recently, I don't think it is gonna change soon.

While GCC can still generate faster code, and in most cases that does not mean much.


Benchmarks comparing milliseconds aren't worth much. Seriously, FPC output is plenty fast. Of course, I've never messed with multithreading or SIMD, so perhaps it's (slightly) better in C with OpenMP, etc., who knows. (FPC may partially support some of this already.)

Quote:

I still think the readability and possibilities Free Pascal offer is enough to compensate that, even if it was 2x speed penalty. If I want to optimize critical code I'd use assembly anyway.


It's definitely not near 2x in most average cases. Anyways, FPC supports inline asm, if you need it.

Quote:

And there are those people who say it is for newbies who are learning and bla, bla, bla. All bullshit, it is a quite sophisticated compiler actually.


They're talking about "classic" (ISO 7185) Pascal, which was designed by an engineer / compiler writer for his own practical use as well as for teaching fellow engineers, mathematicians, physicists, compiler authors, etc.

But 99% of the C world doesn't understand the intricacies of Pascal, even the simplest dialect. (Though even K&R, ANSI, C99 are all obsolete now, maybe even C11 compared to C++. My point is that everything is arguably obsolete at some point.)

Quote:

I can say "Free Pascal" is my favorite compiler (yea, I do use a compiler. And a LOT), and "FASM" is my favorite assembler (yea, I use an assembler too). Coincidentally, both start with an "F". LOL!


Yes, it's probably my favorite compiler too (although GCC/DJGPP is still very nice). Free Pascal has done tons of stuff, supported billions of things, portably (even i8086-msdos target now in 3.0.0), freely. It's fast, it's good, it's compatible, so what's the problem?

I mean, to reiterate, there's nothing hugely wrong with C. (And I still like ISO 7185 a lot!) But yeah, Free Pascal is extremely well done.

P.S. Two more relevant links:

* Delphi Outdated? Says Who? (2014)
* FPC is April 2014 Project of the Month
Post 07 Jul 2016, 23:13
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  
Goto page Previous  1, 2, 3  Next

< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar.

Powered by rwasa.