[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4762: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3897)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4764: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3897)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4765: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3897)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4766: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3897)
GameMonkey Script • View topic - Compile guides for 64bit linux?

GameMonkey Script

GameMonkey Script Forums
It is currently Sat Sep 26, 2020 9:12 pm

All times are UTC




Post new topic Reply to topic  [ 18 posts ]  Go to page 1, 2  Next
Author Message
PostPosted: Fri Feb 15, 2008 2:35 pm 
Offline

Joined: Fri Feb 15, 2008 1:51 pm
Posts: 14


Top
 Profile  
Reply with quote  
PostPosted: Mon Feb 18, 2008 9:03 am 
Offline

Joined: Fri Feb 15, 2008 1:51 pm
Posts: 14


Top
 Profile  
Reply with quote  
PostPosted: Tue Feb 19, 2008 1:25 pm 
Offline

Joined: Mon Dec 15, 2003 1:38 pm
Posts: 708


Top
 Profile  
Reply with quote  
PostPosted: Tue Feb 19, 2008 5:50 pm 
Offline

Joined: Fri Feb 15, 2008 1:51 pm
Posts: 14


Top
 Profile  
Reply with quote  
PostPosted: Wed Feb 20, 2008 6:30 am 
Offline

Joined: Mon Dec 15, 2003 1:38 pm
Posts: 708
Thanks for that, let us know how you go with your 64bit version.

I am looking into the forum attachment problem. I just did a test and wasn't able to attach a file myself. I will get back to you soon on this issue.


Top
 Profile  
Reply with quote  
PostPosted: Wed Feb 20, 2008 11:29 am 
Offline

Joined: Mon Dec 15, 2003 1:38 pm
Posts: 708
Attachments should work fine now.


Top
 Profile  
Reply with quote  
PostPosted: Wed Feb 20, 2008 3:37 pm 
Offline

Joined: Fri Feb 15, 2008 1:51 pm
Posts: 14
Thanks for the fix,I have attached the modified files:


Attachments:
gmamd64.zip [81.62 KiB]
Downloaded 547 times
Top
 Profile  
Reply with quote  
PostPosted: Mon Feb 25, 2008 12:45 pm 
Offline

Joined: Mon Dec 15, 2003 1:38 pm
Posts: 708
Thanks for that MagickPanda. I've had a quick look through the code and it appears you've mainly made sure that all references to BOTH integer and pointer are now 64 bit, is that correct? This is fine, though we really need to update the code one day to allow arbitrary sized int and pointers where, for example an xbox person may want 64bit ints and floats while retaining 32bit addressing, or a Windows 64 person may want 64bit addressing but still 32bit int values.


Top
 Profile  
Reply with quote  
PostPosted: Wed Feb 27, 2008 3:51 pm 
Offline

Joined: Fri Feb 15, 2008 1:51 pm
Posts: 14


Top
 Profile  
Reply with quote  
PostPosted: Thu Feb 28, 2008 6:02 am 
Offline

Joined: Mon Dec 15, 2003 1:38 pm
Posts: 708
Thanks for clarifying that. I'll see if I can at least fix the cases where native 'int' was used instead of 'gmptr' or such as those should work for everyone.


Top
 Profile  
Reply with quote  
PostPosted: Thu Feb 28, 2008 11:29 am 
Offline

Joined: Mon Dec 15, 2003 1:38 pm
Posts: 708
Hmm, I'm not happy. I just had a look into the gm code. There are so many issues to make the thing truely 64bit and safe. I believe you got lucky with your changes, but there are still risks with them. For example, Bison has a stack which contains both code tree node pointers and integer values. Because the new code uses 64bits for gmint/gmuint, it works, but those get cast to int which may not be. The code really should use gmptr and gmuptr when casting from void* or such and gmint/gmuint for all true integer operations. The GM code is inconsistent with this usage, and code like that in Bison is not easy to correct. What about gmVariable? Unless your int and float values are zeroed or scaled up to 64bit, the top bits will contain junk since they are unioned with pointer size values. The gmVariables are hashed so gmTable indices for example might get screwed up.

I'm thinking a safe hack might be to make most integers 64bit to match pointer size AND zero values as much as possible so that operations on union values will produce consistent results.

A proper solution might take considerable effort and a bunch of testing. A proper solution would allow different sizes for integers and pointers, used internally by the machine and used as a value (gmVariable) choice by the user.


Top
 Profile  
Reply with quote  
PostPosted: Fri Feb 29, 2008 9:37 am 
Offline

Joined: Fri Feb 15, 2008 1:51 pm
Posts: 14


Top
 Profile  
Reply with quote  
PostPosted: Fri Feb 29, 2008 11:07 am 
Offline

Joined: Mon Dec 15, 2003 1:38 pm
Posts: 708


Top
 Profile  
Reply with quote  
PostPosted: Sun Mar 09, 2008 11:05 am 
Offline

Joined: Fri Feb 15, 2008 1:51 pm
Posts: 14
Thanks for the info,I will add memset to gmVariables so it won't make wrong/erroneous table hash off high-bits junk.
I am only using the very basic features of GM,I am not even binding C++ objects to GM,so it will be hard to test anything other than table hashing/accessing under 64bit.


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 10, 2008 9:24 am 
Offline

Joined: Mon Dec 15, 2003 1:38 pm
Posts: 708
There's a good chance you'll be fine. If you add a constructor to gmVariable, instead of the memset (which may or may not compile nicely as an intrinsic), you could just set m_ref or the largest union member to zero. Another alternative is to modify gmTableObject::GetAtHashPos to perform a different hash based on the variable type. If you're happy with performance and behavior, despite what I said, I think there's a good chance it will all work.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 18 posts ]  Go to page 1, 2  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group