Browse Source

Add more comparison variants to Valgrind suppressions file.

Mike Pall 13 years ago
parent
commit
e099059afd
2 changed files with 12 additions and 1 deletions
  1. 1 0
      src/Makefile
  2. 11 1
      src/lj.supp

+ 1 - 0
src/Makefile

@@ -142,6 +142,7 @@ XCFLAGS=
 #
 # This define is required to run LuaJIT under Valgrind. The Valgrind
 # header files must be installed. You should enable debug information, too.
+# Use --suppressions=lj.supp to avoid some false positives.
 #XCFLAGS+= -DLUAJIT_USE_VALGRIND
 #
 # This is the client for the GDB JIT API. GDB 7.0 or higher is required

+ 11 - 1
src/lj.supp

@@ -1,14 +1,24 @@
-# Valgrind suppression file for LuaJIT 2.x.
+# Valgrind suppression file for LuaJIT 2.0.
 {
    Optimized string compare
    Memcheck:Addr4
    fun:lj_str_cmp
 }
+{
+   Optimized string compare
+   Memcheck:Addr1
+   fun:lj_str_cmp
+}
 {
    Optimized string compare
    Memcheck:Addr4
    fun:lj_str_new
 }
+{
+   Optimized string compare
+   Memcheck:Addr1
+   fun:lj_str_new
+}
 {
    Optimized string compare
    Memcheck:Cond