Opened 14 years ago

Last modified 9 years ago

#433 new task

Sort out FP rounding modes

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

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 (3)

comment:1 by (none), 14 years ago

Milestone: Unclassified

Milestone Unclassified deleted

comment:2 by Andrew, 14 years ago

Milestone: Backlog

comment:3 by Stan, 9 years ago

Is it still relevant with the latest version ?

Note: See TracTickets for help on using tickets.