Announcement

Collapse
No announcement yet.

powerbasic data segment in inline asm

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Clay Clear
    replied
    Ahhhh! Good information to have! Thanks, Bob.


    ------------------

    Leave a comment:


  • Bob Zale
    replied
    Actually, with the memory model we use, SS always equals DS. Therefore, if you ever alter DS, Just...

    Push SS
    Pop DS

    ...to restore it, so it points to the main data segment.

    Bob Zale
    PowerBASIC Inc.


    ------------------

    Leave a comment:


  • Clay Clear
    replied
    As far as I have seen, PB internally assigns its data segment
    to DS, so there is no reason to have to do it explicitly.
    IMPORTANT NOTE: before the ASM code in your procedures, make sure
    you include ! push ds. Then, be sure to include the corresponding
    ! pop ds at the end of the ASM stuff.


    ------------------

    Leave a comment:


  • Guest's Avatar
    Guest started a topic powerbasic data segment in inline asm

    powerbasic data segment in inline asm

    Is it possible to load ds with powerbasic's data segment when you
    can't assume ds does? Something like a powerbasic internal variable
    or inline asm directive?

    Thanks,
    Ed

    ------------------
Working...
X