memory barrier

Go To Last Post
4 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Freaks, I use the barrier(); instruction in UC3, however, I'm porting the software to ARM and it does not support memory barrier();

 

barrier(); is declared as asm ("nop" ::: "");

 

however the ARM does not like the clobber list "".

 

Can I just list all the registers in the clobber list to do the same thing, such as:

 

asm volatile ("nop" ::: "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12"); 

This topic has a solution.
Last Edited: Fri. Sep 28, 2018 - 10:30 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You are asking ARM questions in the wrong forum.

This reply has been marked as the solution. 
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

found a barrier, __sync_syncronize()

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Got it wrong

 

asm volatile ("" ::: "memory");