From d5b8e843520c2de96795a6b60d4c9495b2025423 Mon Sep 17 00:00:00 2001 From: nickysn Date: Wed, 23 Jan 2019 15:02:38 +0000 Subject: [PATCH] * use only 8086/8088-compatible instructions in the asm GetPixelX git-svn-id: trunk@41017 - --- packages/graph/src/msdos/graph.pp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/graph/src/msdos/graph.pp b/packages/graph/src/msdos/graph.pp index 749ed8b127..53340bbae3 100644 --- a/packages/graph/src/msdos/graph.pp +++ b/packages/graph/src/msdos/graph.pp @@ -2501,9 +2501,11 @@ const CrtAddress: word = 0; {$endif FPC_MM_HUGE} mov di,[Y] ; (* DI = Y coordinate *) (* Multiply by 80 start *) + mov cl, 4 + shl di, cl mov bx, di - shl di, 6 ; (* Faster on 286/386/486 machines *) - shl bx, 4 + shl di, 1 + shl di, 1 add di, bx ; (* Multiply Value by 80 *) (* End multiply by 80 *) mov cx, [X]