Solved

Assembling in Delphi 3.0

Posted on 1998-06-19
3
120 Views
Last Modified: 2010-04-04
Hi,

Does any one know how to use PUSH instruction built-in Delphi 3.0 to push a double data type (64bit) to the stack whose resgister is only 32bit?

Thanks.
0
Comment
Question by:NYang
3 Comments
 
LVL 3

Expert Comment

by:rickpet
ID: 1354150
If your not worried about losing the high bits you can type it to a pointer...

var
  myComp: comp

.

  pointer(myComp);
0
 
LVL 3

Accepted Solution

by:
vladika earned 10 total points
ID: 1354151
Let exists such code

procedure Test(T: Double);
begin
end;

procedure Push1;
var T: Double;
begin
  T := 1;
  Test(T);
end;

It's equivalent
procedure Push2;
var T: Double;
begin
  T := 1;
  asm
    push dword ptr T.4
    push dword ptr T
    call Test
  end;
end;

So, use PUSH instruction 2 times

0
 

Author Comment

by:NYang
ID: 1354152
Many thanks to vladika for solving my problem.

NYang
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, just open a new email message. In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

25 Experts available now in Live!

Get 1:1 Help Now