Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re: emulate 32-bit on perl 64

by BrowserUk (Patriarch)
on Jan 11, 2012 at 15:16 UTC ( #947359=note: print w/replies, xml ) Need Help??

in reply to emulate 32-bit on perl 64

How can I force it to work correct on perl based 64 ?

It gets very messy.

Effectively you have to mask the resultant from operation after any operation that might cause the resultant to be promoted to more than 32 bits. eg.

C:\test>\perl32\bin\perl -le"print 11 | 29 | ~15" 4294967295 C:\test>\perl64\bin\perl -le"print 11 | 29 | ~15" 18446744073709551615 C:\test>\perl64\bin\perl -le"print 11 | 29 | ( ~15 & 0xffffffff )" 4294967295

And if you are manipulating signed rather than unsigned values it gets really tiresome.

I don't know of a good solution to this problem.

With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.

The start of some sanity?

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://947359]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (3)
As of 2022-01-29 08:22 GMT
Find Nodes?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:

    Results (74 votes). Check out past polls.