Jump to content
  • Advertisement
Sign in to follow this  
cvet

Bytecode x64 -> x32

This topic is 757 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, Andreas!

Something wrong with bytecode restoring compiled in x64 environment and restored in x32 environment.

LoadByteCode calls without error, but in script I've got strange 'Null pointer access'.

Please look what can be wrong, if you will not find problem then I try research this problem more.

Also I try combination of x64->x64, x32->x32, x32->x64 and it works fine.

AngelScript revision 2334, Windows, VS2015.

Share this post


Link to post
Share on other sites
Advertisement

I'll need more information. Does it happen with all scripts? Or just some? Can you narrow it down to a specific function in the script that fails?

 

The byte code when saved from x64 or from x32 should be identical. Can you do a diff on the saved bytecode to find the first byte that is different, and then debug the code while saving to let me know what is being saved at that specific byte?

Share this post


Link to post
Share on other sites

Thanks.

 

I've identified that the problem is with the byte code instruction asBC_ChkNullS. This instruction is used to check if a pointer pushed on the stack is null. The offset that the instruction takes as argument must be adjusted when saving and loading the byte code according to the size of pointers.

 

I'll provide a solution for this as soon as possible.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!