BZ #84: reorder cache flushes in patcher functions

Status fields:

creation_ts:2008-07-02 13:40
component:jit
version:default branch
rep_platform:All
op_sys:All
bug_status:RESOLVED
resolution:FIXED
reporter:twisti@complang.tuwien.ac.at
To avoid a nasty race condition we have to flush the data relevant to a specific patcher
_before_ we patch the traping instruction.  Otherwise the patched instruction could read
wrong data, e.g. a function pointer from the data segment.

This applies to all architectures and all patcher functions need a review.

Comment #1 by twisti@complang.tuwien.ac.at on 2008-08-13 17:57:58

Fixed for powerpc64:

http://mips.complang.tuwien.ac.at/hg/cacao/rev/6939742f4cba

Comment #2 by twisti@complang.tuwien.ac.at on 2008-08-14 16:12:12

Fix for ARM: http://mips.complang.tuwien.ac.at/hg/cacao/rev/ad79285abc2d

Comment #3 by twisti@complang.tuwien.ac.at on 2008-08-18 17:16:33

Fix for MIPS: http://mips.complang.tuwien.ac.at/hg/cacao/rev/ce2a6512a611

Comment #4 by twisti@complang.tuwien.ac.at on 2008-09-12 14:29:00

Fixed for x86_64: http://mips.complang.tuwien.ac.at/hg/cacao/rev/56697326cf27

Comment #5 by twisti@complang.tuwien.ac.at on 2008-09-12 14:29:39

Fixed for powerpc: http://mips.complang.tuwien.ac.at/hg/cacao/rev/05f3604328bc

Comment #6 by stefan@complang.tuwien.ac.at on 2008-12-29 19:52:41

Fixed for i386: http://mips.complang.tuwien.ac.at/hg/cacao/rev/d59d98535d79

Comment #7 by stefan@complang.tuwien.ac.at on 2011-01-20 22:20:18

The remaining architectures will not receive any attention going forward, so there's no
point in keeping this open.