[LLVMdev] Here need your help
Eli Friedman
eli.friedman at gmail.com
Tue Oct 23 10:37:35 PDT 2012
On Tue, Oct 23, 2012 at 12:38 AM, liu chao jun <amiko212 at 126.com> wrote:
> Hi all
>
> when i compiled llvm-3.0 with icedtea1.11.4 together,A memory_barrier
> error happened ,And now I write to all of you for the following questions
> need your help and suggestion :
> 1, Is any function which can replace the "make_function" in the
> following function,
> 2 , Or is there any different paramters in make_function with the
> similar action with the following one
> 3 ,Is there a function similar with "nop" which can return a address in
> LLVM or Shark ,
>
> Value* SharkBuilder::memory_barrier() {
> return make_function(
> #if defined(ARM)
> (address) 0xffff0fa0, // __kernel_dmb
> #else
> "llvm.memory.barrier",
> #endif // ARM
> "11111", "v");
> }
In newer versions of LLVM, llvm.memory.barrier has been replaced by
new atomic instructions; you're probably interested in the "fence"
instruction in particular. See
http://llvm.org/docs/LangRef.html#i_fence
-Eli
More information about the llvm-dev
mailing list