• Turbo Pascal 6.0 editor sources

    From Noon@21:1/5 to All on Wed Aug 20 16:45:25 2025
    Hello community,

    I just wanted to let you know that the Internet recovered the sources of
    Turbo Pascal 6.0. I haven't tried to compile them yet, but they look
    complete: https://archive.org/details/tpascal

    What's interesting is that the compiler contains an opcode generator for
    x86 assembly commands - which potentially could pave the way to extend
    the integrated assembler by 386 commands or above.

    I hope that Borland Pascal 7 will appear at some point as well, as this
    would open up the world for the community to extend their favourite
    compilers!

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Robert Prins@21:1/5 to Noon on Wed Aug 20 22:21:41 2025
    On 2025-08-20 14:45, Noon wrote:
    Hello community,

    I just wanted to let you know that the Internet recovered the sources of Turbo
    Pascal 6.0. I haven't tried to compile them yet, but they look complete: https://archive.org/details/tpascal

    What's interesting is that the compiler contains an opcode generator for x86 assembly commands - which potentially could pave the way to extend the integrated assembler by 386 commands or above.

    I hope that Borland Pascal 7 will appear at some point as well, as this would open up the world for the community to extend their favourite compilers!

    I've had these for probably two or more decades. Also never tried to recompile/reassemble them, but I did (and still do, somewhere...) have a program
    to actually modify the builtin BASM hash table to include some 386(+) instructions, but using 386(+) code is also possible using const's to define opcodes and use them via db/dw/dd. Extending the assembler to actually handle the new addressing modes of 386(+) instructions will probably be pretty hard.

    It would be far more useful to have the source for Virtual Pascal, and work with
    that one, although given that that compiler is also written in pretty much uncommented x86 assembler (now how do I know that...), it will be just as hard, but probably far more useful, right now I'm using it with lots of db/dw/dd codes
    post Pentium instructions, like (wrapping lines)

    { cmovg edi, eax } db $0f,$4f,$f8
    { cmovg edi, esi } db $0f,$4f,$fe
    { movq [ebx + offset lift_list.sum.km], mm0 } db $0f,$7f,$83; dd offset lift_list.sum.km
    { movq mm0, sum.km } db $0f,$6f,$05; dd offset sum.km
    { movq sum.km, mm0 } db $0f,$7f,$05; dd offset sum.km
    { paddd mm0, [ebx + offset lift_list.dtv.km] } db $0f,$fe,$43,offset lift_list.dtv.km
    { vmovdqu [eax + ecx], ymm0 } db $c5,$fe,$6f,$04,$08
    { vmovdqu [edi + 32], ymm1 } db $c5,$fe,$7f,$4f,32
    { vmovdqu [edi + eax], ymm0 } db $c5,$fe,$7f,$04,$07
    { vmovdqu [edi], ymm0 } db $c5,$fe,$7f,$07
    { vmovdqu [edx + offset minmax.max.km], xmm0 } db $c5,$fa,$7f,$42,offset minmax.max.km
    { vmovdqu swaits, ymm0 } db $c5,$fe,$7f,$05; dd offset swaits
    { vmovdqu xmm0, [edx + offset minmax.min.km] } db $c5,$fa,$6f,$42,offset minmax.min.km
    { vmovdqu ymm0, [esi + eax] } db $c5,$fe,$6f,$04,$06
    { vmovdqu ymm0, [esi] } db $c5,$fe,$6f,$06
    { vmovdqu ymm1, [esi + 32] } db $c5,$fe,$6f,$4e,32
    { vpmaxsd xmm0, xmm0, [ecx + offset minmax.max.km] } db $c4,$e2,$79,$3d,$41,offset minmax.max.km
    { vpminsd xmm0, xmm0, [ecx + offset minmax.min.km] } db $c4,$e2,$79,$39,$41,offset minmax.min.km
    { vpxor xmm0, xmm0, xmm0 } db $c5,$f9,$ef,$c0

    generating the byte-code via <https://defuse.ca/online-x86-assembler.htm>

    Robert
    --
    Robert AH Prins
    robert(a)prino(d)org
    The hitchhiking grandfather - https://prino.neocities.org/
    Some REXX code for use on z/OS - https://prino.neocities.org/zOS/zOS-Tools.html

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Noon@21:1/5 to All on Sat Aug 30 22:41:43 2025
    Hello Robert,

    I've had these for probably two or more decades. Also never tried to
    If you happen to have the sources of BP7 as well, please upload them to archive.org!
    (and the named Virtual Pascal... well, it's better to have backups as
    well! ;)

    program to actually modify the builtin BASM hash table to include some
    386(+) instructions, but using 386(+) code is also possible using
    const's to define opcodes and use them via db/dw/dd. Extending the
    assembler to actually handle the new addressing modes of 386(+)
    instructions will probably be pretty hard.
    That is already known of course, I use it a lot. But it's a hassle, unfortunately. You can prefix many 16 bit commands with db66h to make
    the work with 32 bits registers.

    It would be ideal to be able to mod the integrated assembler to properly
    handle most 32 bits commands. The named opcode generator would be where
    this probably can be done.
    I only need it for BP7, as most of my most important code is Protected
    Mode only.

    generating the byte-code via <https://defuse.ca/online-x86-assembler.htm>Another nice one I'm using is shell-storm:
    https://shell-storm.org/online/Online-Assembler-and-Disassembler/

    There were only a few commands that weren't properly translated. Can't
    remember right now which ones that were. But there were not too usual.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Robert Prins@21:1/5 to Noon on Mon Sep 1 18:45:59 2025
    On 2025-08-30 20:41, Noon wrote:
    Hello Robert,

    I've had these for probably two or more decades. Also never tried to
    If you happen to have the sources of BP7 as well, please upload them to archive.org!
    (and the named Virtual Pascal... well, it's better to have backups as well! ;)

    program to actually modify the builtin BASM hash table to include some
    386(+) instructions, but using 386(+) code is also possible using const's to >> define opcodes and use them via db/dw/dd. Extending the assembler to actually
    handle the new addressing modes of 386(+) instructions will probably be pretty
    hard.
    That is already known of course, I use it a lot. But it's a hassle, unfortunately. You can prefix many 16 bit commands with db66h to make the work
    with 32 bits registers.

    It would be ideal to be able to mod the integrated assembler to properly handle
    most 32 bits commands. The named opcode generator would be where this probably
    can be done.

    Of course it can be done, but how useful is it?

    I only need it for BP7, as most of my most important code is Protected Mode only.

    In that case, why don't you use Virtual Pascal? (Or FreePuscal)

    generating the byte-code via
    <https://defuse.ca/online-x86-assembler.htm>Another nice one I'm using is
    shell-storm:
    https://shell-storm.org/online/Online-Assembler-and-Disassembler/

    Bookmarked. Interesting that is can handle z/OS binaries, might try downloading the backend to see what it can do on some old PL/I compiler RTL that falls over.

    There were only a few commands that weren't properly translated. Can't remember
    right now which ones that were. But there were not too usual.

    That's irrelevant. If it cannot translate all code, it's not useable!

    Robert
    --
    Robert AH Prins
    robert(a)prino(d)org
    The hitchhiking grandfather - https://prino.neocities.org/
    Some REXX code for use on z/OS - https://prino.neocities.org/zOS/zOS-Tools.html

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)