Ticket #433 (new task)

Opened 4 years ago

Last modified 4 years ago

Sort out FP rounding modes

Reported by: Philip Owned by:
Priority: Should Have Milestone: Backlog
Component: Core engine Keywords:
Cc:

Description

SpiderMonkey likes to change the FPU rounding mode (see "Rounding difference between JIT and interpreter") to guarantee consistency. We need to guarantee consistency in SpiderMonkey for the synchronised simulation to work (though we might not use the JIT; not sure yet). So we need to be careful about these modes and make sure they're correct before we call into any SpiderMonkey code.

It's hard to know when the mode will be changed (platform default, our init code, SpiderMonkey init code, other code, drivers, etc); probably it would be good to add run-time checks to make sure it sticks with what SpiderMonkey requires. Might need to worry about SSE FTZ/DAZ flags too.

Also need to test it across OSes and 32/64-bit and compilers. And, just to be certain, the game itself should probably run some JS test code on startup to check the results are consistent rather than getting mysterious OOS errors in a network game.

Change History

comment:1 Changed 4 years ago by anonymous

  • Milestone Unclassified deleted

Milestone Unclassified deleted

comment:2 Changed 4 years ago by wacko

  • Milestone set to Backlog
Note: See TracTickets for help on using tickets.