Converting to 64bit hardware?

Posted on 2006-05-17
Medium Priority
Last Modified: 2013-12-26
We have some clients that are going to 64 bit hardware. The question I have is what do I need to do to convert our current app to make use of the 64 bit hardware? We're currently using PB 8.5 and going to 10.5 soon if that makes a difference.
Would I need to convert some datatypes from say Int to Long? Maybe have a sperate set of DLL's so when the application runs it can determine weather to use the 64bit DLL's or the 32bit DLL's since some clients will be running against 32bit machines and others against 64 bit ones.
Question by:byteboy1
  • 2
LVL 18

Expert Comment

ID: 16706144

i dont think that will b too much of an issue... i have an application in PB9 which is compiled on a 64bit machine and is working just fine at the clients place on both 32 and 64bit machines... with the same set of dlls...

cant recollect anything serious at the moment... what u can do is go ahead and deploy ur application... if u face any probs we will help u out...



Expert Comment

ID: 16713045

When you move to 64 bit hardware not necesary you are using 64 bits arithmetic or datatypes, it will depend on your software.

For example, if your clients are just changing user PC's to have i.e. AMD64 nothing will happen to your application, just compile it in a procesor like that and check if it run (and it will), so don't boder about that.

But there is something different if your client is changing his servers AND databases to use 64 bit hardware and in new database you use Biginteger fields or Int64 or whatever name they put on it.  If this is the case you must change your application sooner or later to 10.5 +  because here they are including support to this big integer datatypes.

Bigint support 10.5:
PowerBuilder supports the 64-bit integer signed BigInt datatype, which maps to the PowerScript longlong datatype, and the unsigned BigInt datatype, which maps to the PowerScript decimal datatype.

Decimal datatypes are supported in the DataWindow, but in previous releases of PowerBuilder, decimal values were converted to doubles in DataWindow expressions. PowerBuilder 10.5 adds support for decimal values in DataWindow expressions and new DataWindow expression functions to support decimal values. You can also use decimal values as retrieval arguments. In PowerBuilder 10.5, the decimal datatype supports up to 28 digits.

I think the only real difference you will get to move to version 10.5 is the use of new Decimal datatype like it does .Net or the LongLong datatype, but as you said your are using PB 8.5 then you are not using yet any 64 bit datatypes, like LongLong datatype introduced in version 9.0.  

So you do not need to convert any datatypes from say Long to LongLong unless your database it's going to use that new big integers and your Powerscript need to deal with them.




Author Comment

ID: 16713156
This is interesting because we are going from 8.5 to PB 10.5 in a couple months. I would say whats likely is that the client will still have their desktops using regular 32 bit hardware but they are upgrading their servers and databases to 64bit.
In most cases for us we have a copy of our inventory control software running on both the server and the same software running on that companies desktops for their users.

So assuming we're running PB 10.5 would we need a 'server' version of our software that  has long's converted to the longlong datatype and a different version of our software that doenst have the longs coverted to longlong to run on the workstations?
Would it hurt to be runnning the 64 bit version on the 32bit user workstations, so that we can just have one version that runs on both 32bit and 64bit?

What advantages are there in our software to write it to make use of the 64bit hardware...is it much faster?


Accepted Solution

berXpert earned 1000 total points
ID: 16713566
I think you only need to have a '64 bit version' if you start to using Big integer types and start operating on them by powerscript.


In MS SQL Server there is a datatype Bigint (64 bits integer), let's create a table

create table my_table( x bigint )
insert into my_table values( 9223372036854775807)

and suppose you want to operate on this value, but as in Powerbuilder 8.5 there is not a datatype to handle it you are using right now a decimal(19,0)

// Some where in your code

Decimal {0} ld_x       // local decimal _ x

select x into :ld_x
from my_table;

f_use_your_number_for_something(  ld_x )
//... end

Now if you are planning to use PB 10.5 and it's new datatypes in a natural way you should change your code to:

// Some where in your code

LongLong lll_x   //  local long long _ x

select x into :lll_x
from my_table;

f_use_your_number_for_something(  lll_x )
//... end

So, while your logic in your program and your data keeps 32 bit integer operations you do not neet to rush of this. And I bet you are the owner of data definition then your users wont be freely allowed to change a table from an int to a bigint datatype.

And about 64 bit hardware it's faster only if all operations and data are used as 64 bit because it's moving double rate of data, but if you are still using 32 bit operations and 32 bit data you wont notice any difference.

Just because the hardware is 64 bit compatible does not mean that you will be taking advantage of it. In order to take adventage of that capability, you need to run 64 bit software.... like Windows XP x64.
And even then, you need a program that is 64 bit in order to see an improvement.
32 bit programs that are installed under 64 bit operating systems will not run much faster than on a 32 bit operating system.

By the way I don't know if it will be a Powerbuilder x64 soon.



Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

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

In our object-oriented world the class is a minimal unit, a brick for constructing our applications. It is an abstraction and we know well how to use it. In well-designed software we are not usually interested in knowing how objects look in memory. …
Programmer's Notepad is, one of the best free text editing tools available, simply because the developers appear to have second-guessed every weird problem or issue a programmer is likely to run into. One of these problems is selecting and deleti…
The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…
The viewer will learn how to synchronize PHP projects with a remote server in NetBeans IDE 8.0 for Windows.

607 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