VOGONS


Reply 80 of 132, by spiroyster

User metadata
Rank Oldbie
Rank
Oldbie

Yes agree with what others have said... there is no silver bullet language here... no language which gives the speed of a low level (ASM) with higher level syntax (C/C++). If there was, everybody would be using it.

If you know C, just expand on that, you won't regret it. C is basically the lowest (platform agnostic-ish) common denominator, even today. Most shared objects (.dll, .so) expose C interfaces, C allows inline assembly for extra ease (if you want to squeeze that extra bit out), pretty much every OS have C API's, and most libs that you will probably want to use have C API's (or if not there will probably be a equivalent lib with C API of what you want). This can't be said for many other languages tbh. If you used C, I doubt you would question learning other languages any time soon, If you didn't, I guarantee there will come the time when you will wish you knew C. 😉

When you write ASM, you are as close to metal as you are going to get so can program your intentions exactly as you need them. When you use a higher level language you are basically relegating your intentions to the language semantics and it's compiler or interpreter and are subsequently restricted by these metrics. Compilers can only guess at what your intentions are so can't always provide the most optimal code in all situations. Thats the trade off, and always has been. It could be argued that the performance of a language comes from the quality of its compilers... both C and C++ have very good ones!

Personally, ASM, I would stay away from in most/all cases, however since the platform is well defined in this case (DOS, x86). You would find this extremely beneficial and it will give you the best performance, but is obviously a completely different mind-set to higher level stuff.

Of course it all depends on what you want to do, if you just want to experiment with theory etc, an interpreted language (like BASIC) will probably be the fastest (and potentially easiest to learn) in terms of implementation and testing of algorithms.... but you would no doubt be rewriting in another language (C/ASM) if/when performance ever becomes an issue. tbh The more you practice with C, the less scary it would become, and some of the worries you mention would not even cross your mind. When I write something, while I do sometimes think, damn I got to write that scheduler or management logic... that’s half the fun of programming imo. That’s the creativity, conveyed in the architecture of how you design solution to the problem you are solving... all the nitty gritty details.

Also there is no excuse for not wanting to learn about memory!!! As been stated, memory management is not for your benefit, it's for the benefit of the stability of the rest of the system... relying on that is like saying you don't think it would be so bad to crash your car because you have air-bags 😵

Reply 81 of 132, by gdjacobs

User metadata
Rank l33t++
Rank
l33t++

The crime of Forth, for instance, is that it's very different from the pre-existing paradigm. Success is no indicator of technical superiority.

All hail the Great Capacitor Brand Finder

Reply 82 of 132, by ruthan

User metadata
Rank Oldbie
Rank
Oldbie
SirNickity wrote on 2020-02-05, 20:32:

That's fine when you're running on 2GHz+ processors with 4GB RAM. It isn't going to cut it on Pentium and older hosts. The overhead of all the programming guard rails is just too high. Especially in DOS, where you get (what's left of) what an 8086 could address.

It not simply true, if we avoid garbage collection as usual argument for that we need lots of horsepower, because with it really need lots of operations in very short time period, no way around it and to be hones for performance heavy app - like games, its not completely fixed even with todays tech, that is why we are still stuck with lowlevel for main engine and we are "wasting" power only on some scripting - usually some gameplay and mission code.
But even back in computers stone age, there are was some functional and conceptional programming which generated fast enough code. So we need only some good translation and compilation more easy to code lang to fast lowlevel code and in general its has to be possible... i thing that is smaller or similar jump that from ASM to C or at least to Pascal.

I dont know details but even above mentioned DIV its probably proof of that. I know that is corner case, i already wrote that for games and dos is lowlevel must have, but some great Quake mods (no so called total conversions.. which were more lowlevel and edited source code ) are actually example that with some low level fast enough code and high level framework you can make fast enough games. QuakeC scripting was 10x slower than native C or something like that but it good enough for make custom gameplay, design to live.

I cant find link right now, but there is very nice online presentation of programming environment picture. from the past to today.. there are lots of strange high level stuff.

brownk wrote:

Sorry to wake you up. I believe the biggest motivation for innovation known to mankind is M.O.N.E.Y. Without it, you cannot simply put the blame for not bringing one.

Point was, that were are different types of programmers, as there different types of people. Yes there are people in situation when are doing anything because they were told so.. but its not argument against my original idea. But that low level bias i thing also brought some negativity.. prevented more or other types of people to participate, or prevent them gain official education in area ( there is classic theme if need or not be good in math for coding.)

brownk wrote:
I don't know about you, but I don't smell anything in DOS. [\quote] Well i would be in month 36, so i really had no chance to av […]
Show full quote

I don't know about you, but I don't smell anything in DOS. [\quote] Well i would be in month 36, so i really had no chance to avoid Dos.. im from post communistic country and there was around me almost only PC with DOS and already dead mainframes (im from sort of science village), if someone was in some computing.. There was some Amiga community too, but not near me. Windows 3 was meh and even if someone had fast enough machines with Win95, majority of DOS game ran slower under it.
With programming it was simple too - Qbasic was integrated in Dos, Turbo Pascal and Turbo C were 1,2 floppies.. we had nothing for Windows (CDs).. i thing that first Windows programming, which i saw was Delphi, but even that we ve told that.. for right coders is better to use C++ Builder - i was i thing 1998 or something like that.. i can play with it, but i havent it available at home for next 2,3 years. Schools were also stuck in Dos, behind new trends.. so we still had to care about gates, ASM, 286 flag registers, Dos commands etc.. when i was under bench reading Quake source codes.
So maybe i dont live with Dos heydays, but i know that stuff. But maybe is problem that people which were older.. are logically more stuck with that.. I simply move away.. as some people make some ASM, C exam as part of school and never wanted to touch it again.
Even that ugly C++ on Windows i some way was move to the future and more high level concepts, which i always liked and tend to. I already made lots of comparitions.. but other is like comeback to can with manual transmission. when you are used to automatic one (BTW every dos fan should play Street rod its now free:)

Im old goal oriented goatman, i care about facts and freedom, not about egos+prejudices. Hoarding=sickness. If you want respect, gain it by your behavior. I hate stupid SW limits, SW=virtual world, everything should be possible if you have enough raw HW.

Reply 83 of 132, by ruthan

User metadata
Rank Oldbie
Rank
Oldbie

I found that programming environment presentation link:
https://docs.google.com/presentation/d/1MD-Cg … 1da0625f1b_0_56
Lots of concepts are too high level even for me (but choice is nice) and point was to show that these things were here for very long time and i want only very small piece of to make programming more user friendly.

Im old goal oriented goatman, i care about facts and freedom, not about egos+prejudices. Hoarding=sickness. If you want respect, gain it by your behavior. I hate stupid SW limits, SW=virtual world, everything should be possible if you have enough raw HW.

Reply 84 of 132, by RayeR

User metadata
Rank Oldbie
Rank
Oldbie

Ruthan, here you have some DOS JS, it's not dead but with sound support and now seems also Glide 3Dfx accel.
https://github.com/SuperIlu/DOjS

Gigabyte GA-P67-DS3-B3, Core i7-2600K @4,5GHz, 8GB DDR3, 128GB SSD, GTX970(GF7900GT), SB Audigy + YMF724F + DreamBlaster combo + LPC2ISA

Reply 85 of 132, by ruthan

User metadata
Rank Oldbie
Rank
Oldbie

Thanks nice find.. i wonder if this can make standalone exe or its same as Python for Dos? I quickly read the description, but im not sure.

Im old goal oriented goatman, i care about facts and freedom, not about egos+prejudices. Hoarding=sickness. If you want respect, gain it by your behavior. I hate stupid SW limits, SW=virtual world, everything should be possible if you have enough raw HW.

Reply 86 of 132, by RayeR

User metadata
Rank Oldbie
Rank
Oldbie

AFAIK no EXE, it's JS interpreter. It would be possible to make packer that glue whole DOJS and add a script in to run at start but probably no use case, it can be run by BAT file...

Gigabyte GA-P67-DS3-B3, Core i7-2600K @4,5GHz, 8GB DDR3, 128GB SSD, GTX970(GF7900GT), SB Audigy + YMF724F + DreamBlaster combo + LPC2ISA

Reply 87 of 132, by ruthan

User metadata
Rank Oldbie
Rank
Oldbie
RayeR wrote on 2020-02-16, 20:51:

AFAIK no EXE, it's JS interpreter. It would be possible to make packer that glue whole DOJS and add a script in to run at start but probably no use case, it can be run by BAT file...

Yeah its how i meant it, memory filesize would be probably huge, but memory footprint its more important.

Im old goal oriented goatman, i care about facts and freedom, not about egos+prejudices. Hoarding=sickness. If you want respect, gain it by your behavior. I hate stupid SW limits, SW=virtual world, everything should be possible if you have enough raw HW.

Reply 88 of 132, by SirNickity

User metadata
Rank Oldbie
Rank
Oldbie
ruthan wrote on 2020-02-11, 21:30:

But that low level bias i thing also brought some negativity.. prevented more or other types of people to participate, or prevent them gain official education in area ( there is classic theme if need or not be good in math for coding.)

Back when I was a teenager learning to program in Visual Basic, I thought it was very unfair that the world expected you to know C. I understand what you mean by "low level bias," but the reality is... some things really can only be done when you remove the training wheels.

It's interesting to watch the archives of The Computer Chronicles, when people were first figuring out computer education -- like how to teach kids programming. It starts with sheltered applications that just convey the essentials of logic. It's not really programming, but it does teach you to think in discrete steps and provide instructions in a formal way. That's great, but at some point you have to decide whether you have the desire to graduate to something more useful, or languish in the sandbox

BASIC was a common next step. There, you're actually writing programs, and you're still insulated from the possibility of following pointers that lead to nowhere, and things like that. But it's slow, and doing more sophisticated things -- like writing TSRs, and hooking into interrupt handlers -- isn't possible because it necessarily requires advanced concepts. There's no way to (e.g.) represent a linked list without understanding pointers.

Power and responsibility are linked. It's not a bias against people who are unwilling to dip toes into those waters, it's just that the only way to accomplish some of those advanced goals is to dive in -- and for that, you just have to learn to swim. If there were an easier way, it would have been evident by now.

So you can spend your time working with novelty engines and frameworks that allow you to stay in the shallow end, and they'll do the complicated stuff for you, but there's a reality to that:
1) It'll never be as performant as purpose-built code. (Maybe close, maybe even good enough.)
2) If your intention is to create software that end-users will run, you have an uphill battle convincing them to acquire and maintain the environment around the code you write. This is always at least a mild burden above "run this EXE."
3) You'll pretty much never get anyone to help you. That means no team collaboration, no plugins, no modules, no hacks/mods, no rich set of libraries, etc. It's not worth the time for anyone else to spend on some toy language when they've already accepted the price of entry and learned C, C++, ASM.

You can fight it for as long as you want, but eventually you will hit a ceiling. Trust me, I have spent decades learning this lesson with PCB design programs. They come in two flavors: Sensible to use, or Capable. I'm currently using something that is Windows-only, a dead product (because the codebase got bought by a fab house and now it only exports to their proprietary format), and doesn't offer tools for advanced designs. I've got a hard ceiling, and I get closer and closer to it every day. Sooner or later I'll have to jump ship, and all the time I spend fighting it is just wasted.

Reply 89 of 132, by RayeR

User metadata
Rank Oldbie
Rank
Oldbie
SirNickity wrote on 2020-02-17, 19:49:

Sooner or later I'll have to jump ship, and all the time I spend fighting it is just wasted.

Do you mean join the Altium user base? 😀

Gigabyte GA-P67-DS3-B3, Core i7-2600K @4,5GHz, 8GB DDR3, 128GB SSD, GTX970(GF7900GT), SB Audigy + YMF724F + DreamBlaster combo + LPC2ISA

Reply 90 of 132, by SirNickity

User metadata
Rank Oldbie
Rank
Oldbie

Yeah, when I win the lottery. 😉 I figure I'll have to move into something with more support, more features, and a more brain-dead interface -- like KiCad or Eagle. Engineers make terrible UI designers.

Reply 91 of 132, by BloodyCactus

User metadata
Rank Oldbie
Rank
Oldbie

yeah I stick with DipTrace after I left Eagle. No going back there (and worse with current pricing 🤣). KiCad is just an utter mess with no cohesion. anyway...

--/\-[ Stu : Bloody Cactus :: [ https://bloodycactus.com :: http://kråketær.com ]-/\--

Reply 92 of 132, by ruthan

User metadata
Rank Oldbie
Rank
Oldbie

I wonder if there is someone who is part of both worlds. Someone who is coding new apps in modern language like C#,Java, Python, PHP, Ruby on professional level (to exclude some simple webpages) etc.. and still is using low level C on Dos for some other work or hobby? Because such persons ideas would be most valid and interesting.

Im old goal oriented goatman, i care about facts and freedom, not about egos+prejudices. Hoarding=sickness. If you want respect, gain it by your behavior. I hate stupid SW limits, SW=virtual world, everything should be possible if you have enough raw HW.

Reply 93 of 132, by BloodyCactus

User metadata
Rank Oldbie
Rank
Oldbie
ruthan wrote on 2020-02-18, 15:04:

I wonder if there is someone who is part of both worlds. Someone who is coding new apps in modern language like C#,Java, Python, PHP, Ruby on professional level (to exclude some simple webpages) etc.. and still is using low level C on Dos for some other work or hobby? Because such persons ideas would be most valid and interesting.

I spend all day doing java/ee/ui5/sap... and at home write c + asm for dos stuff. ruby/c/lua/sdl on linux, etc.

--/\-[ Stu : Bloody Cactus :: [ https://bloodycactus.com :: http://kråketær.com ]-/\--

Reply 94 of 132, by root42

User metadata
Rank l33t
Rank
l33t

Same here. Currently C++ for work. With some Java, Python and the like sprinkled here and there. C, Basic and maybe some ASM for DOS for a hobby. 😀 Also doing Clojure for fun.

I code in Emacs with rtags and some other modules at work (to navigate a millions of lines project). But switch to IntelliJ or Netbeans when necessary, for Java stuff. A complex IDE is only needed for large projects. So I love my TurboC in DOS, which is good enough for a project of a couple of dozen files. Also, you can still use ${EDITOR} outside of DOSBox and then compile all with tcc / make.

YouTube and Bonus
80486DX@33 MHz, 16 MiB RAM, Tseng ET4000 1 MiB, SnarkBarker & GUSar Lite, PC MIDI Card+X2+SC55+MT32, OSSC

Reply 95 of 132, by ruthan

User metadata
Rank Oldbie
Rank
Oldbie

Ok.. from your point of view, what is better for return to C/C++ stuff. Use in in old Dos fashion way with DJGPP or use it with Windows with Dev-C++ / Visual Studio / Netbeans etc and after go back to Dos stuff?

Im old goal oriented goatman, i care about facts and freedom, not about egos+prejudices. Hoarding=sickness. If you want respect, gain it by your behavior. I hate stupid SW limits, SW=virtual world, everything should be possible if you have enough raw HW.

Reply 96 of 132, by BloodyCactus

User metadata
Rank Oldbie
Rank
Oldbie

I do it two ways 😀

Since I am on Linux, I use Netbeans with C/C++ plugin and openwatcom. it compiles native in linux outputting dos binaries (super fast), since I just "wmake", I can also dev in jEdit and indosbox run "wmake".

I dont really do line level integrated debugging.

I dont program "in dos" using a dos ide. thats useless imo. I still want good ide abilities in good font easy on my eyes when looking at code.

I do basic testing in dosbox then on my real machine to make sure it really works.

--/\-[ Stu : Bloody Cactus :: [ https://bloodycactus.com :: http://kråketær.com ]-/\--

Reply 97 of 132, by root42

User metadata
Rank l33t
Rank
l33t

Watcom is a great idea. Does it emit real mode code as well?

Planet X3 was written using notepad and a simple assembler... so most important is the coder, the tools come second. 😉

YouTube and Bonus
80486DX@33 MHz, 16 MiB RAM, Tseng ET4000 1 MiB, SnarkBarker & GUSar Lite, PC MIDI Card+X2+SC55+MT32, OSSC

Reply 98 of 132, by BloodyCactus

User metadata
Rank Oldbie
Rank
Oldbie

yes openwatcom can do 8086 up to 80586 pmode or 80586 real mode

I dont know why he chose to use A86 instead of Nasm (well I do know, he wanted to run it on real xt class hardware, which probably slowed his development down by an order of magnitude) and as someone who used A86 a lot back in the day, nasm in dosbox > a86 by a very very wide margin (I do like d386 for debugging tho).

--/\-[ Stu : Bloody Cactus :: [ https://bloodycactus.com :: http://kråketær.com ]-/\--

Reply 99 of 132, by root42

User metadata
Rank l33t
Rank
l33t

Well, I think mobygamer said it in the making of video: he wanted him to use a86 only as a learning tool, but suddenly David had written the whole game in it already. 😀 Determination goes a long way...

YouTube and Bonus
80486DX@33 MHz, 16 MiB RAM, Tseng ET4000 1 MiB, SnarkBarker & GUSar Lite, PC MIDI Card+X2+SC55+MT32, OSSC