How do I write a memory barrier for a TMS320F2812 DSP?
问题 I've looked through the TI C/C++ compiler v6.1 user's guide (spru514e) but didn't find anything. The asm statement doesn't seem to provide anything in this regard, the manual even warns against changing values of variables (p132). The GNU extension for declaring effects on variables is not implemented (p115). I also didn't find any intrinsic for memory barriers (like __memory_changed() in Keil's armcc). Searching the web or the TI forums also turned up nothing. Any other hints how to proceed?