Hi!

1-Мар-2004 21:05 [EMAIL PROTECTED] (Bart Oldeman) wrote to
[EMAIL PROTECTED]:

>> BO> In the current sys it simply happens to work since the int 25/26 is
>> BO> followed by "mov sp, bp".
>> - BP itself should be preserved somewhere (because "modify[]"). Where if not
>>   on stack?
BO> that's a question for me as well.

     Probably (I don't read yet help files about #pragma aux) should be
reported as bug to Warcom team.

BO> It just happens to be preserved by the
BO> FreeDOS kernel for int 25/26.

     Of course - this kernel written (almost) in C. :)

>> - I not (yet) compile kernel by Watcom (so don't know, how WCC compiles this
>>   code), but in excerpt there are no "mov sp,bp" after compilation.
BO> Looking at sys.obj disassembly:
BO> 043F    CD 26                     int       0x00000026
BO> 0452    B8 05 73                  mov       ax,0x7305
BO> 0455    B9 FF FF                  mov       cx,0xffff
BO> 0458    CD 21                     int       0x00000021
BO> 0460    89 EC                     mov       sp,bp   <---
BO> 0465    C2 04 00                  ret       0x00000004

     Yes, I see, thank you. This is "mov sp,bp" from calling function
(MyAbsReadWrite), which have frame on stack (unlike my short exampled
function f()). So, yes, there is bug in absread() definition in current SYS,
which masked by other code.

>> BO> Strange that in your example the pragma doesn't seem to preserve bp
>> BO> however ... FreeDOS preserves it, don't no about others..
>>      "FreeDOS"?
BO> the Freedos kernel preserves the "bp" register for int25 and int26.

     Now understand: under "preserve" I was understand SYS code, but you
extend this context to SYS+FreeDOS.

>> BO> I don't think dx=ffff is a problem for floppies / <32MB for any DOS >= 3.31.
>>      Bug in RBIL?
BO> don't know ... RBIL is only sufficient in this case -- it simply tells us
BO> that it works for "32M-2047M hard-disk partition" but tells nothing about
BO> the behaviour outside these ranges (only about FAT32).

     Well, checking another sources...

______________O\_/_________________________________\_/O______________
  To address partition sizes greater than 32Mb an extended format is
provided in Compaq DOS 3.31, DOS 4.0, and DR-DOS.  This format passes
a 32-bit address value by means of a parameter block.  The extended
format may be used to address disks smaller than 32Mb as well as
larger.
_____________________________________________________________________
              O/~\                                 /~\O

This is from Dave Willims "Programmer's Technical Reference for MSDOS and
the IBM PC".




-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id56&alloc_id438&op=click
_______________________________________________
Freedos-kernel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freedos-kernel

Reply via email to