summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp
diff options
context:
space:
mode:
authorVinson Lee <vlee@freedesktop.org>2012-03-13 22:40:52 -0700
committerVinson Lee <vlee@freedesktop.org>2012-03-14 09:30:40 -0700
commitfe34006908f1ff99ada34d52c06fd80197e452ec (patch)
tree3ae60349f5f65cb6ca552ecd1a869545067884ba /src/gallium/auxiliary/gallivm/lp_bld_misc.cpp
parentdc382e5c35a6e91a323789327c9a1ba3bc9f8c72 (diff)
gallivm: Fix createOProfileJITEventListener namespace with llvm-3.1.
llvm-3.1svn r152620 refactored the OProfile profiling code. createOProfileJITEventListener was moved from the llvm namespace to the llvm::JITEventListener namespace. Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Brian Paul <brianp@vmware.com>
Diffstat (limited to 'src/gallium/auxiliary/gallivm/lp_bld_misc.cpp')
-rw-r--r--src/gallium/auxiliary/gallivm/lp_bld_misc.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp b/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp
index fe7616b9ecf..68f8808f3ef 100644
--- a/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp
+++ b/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp
@@ -62,7 +62,11 @@
extern "C" void
lp_register_oprofile_jit_event_listener(LLVMExecutionEngineRef EE)
{
+#if HAVE_LLVM >= 0x0301
+ llvm::unwrap(EE)->RegisterJITEventListener(llvm::JITEventListener::createOProfileJITEventListener());
+#else
llvm::unwrap(EE)->RegisterJITEventListener(llvm::createOProfileJITEventListener());
+#endif
}