Mercurial > hg > graal-jvmci-8
changeset 12329:f2512d89ad0c
8025613: clang: remove -Wno-unused-value
Reviewed-by: iveresov
author | twisti |
---|---|
date | Sat, 28 Sep 2013 12:42:22 -0700 |
parents | 303826f477c6 |
children | 29bdcf12457c |
files | agent/src/os/linux/LinuxDebuggerLocal.c agent/src/os/linux/ps_proc.c agent/src/os/linux/salibelf.c agent/src/os/linux/symtab.c make/bsd/makefiles/gcc.make make/linux/makefiles/gcc.make src/cpu/x86/vm/assembler_x86.cpp src/share/vm/classfile/defaultMethods.cpp |
diffstat | 8 files changed, 13 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/agent/src/os/linux/LinuxDebuggerLocal.c Sat Sep 28 12:32:10 2013 +0400 +++ b/agent/src/os/linux/LinuxDebuggerLocal.c Sat Sep 28 12:42:22 2013 -0700 @@ -29,6 +29,7 @@ #include <sys/types.h> #include <sys/stat.h> #include <fcntl.h> +#include <stdlib.h> #include <string.h> #include <limits.h> @@ -80,7 +81,7 @@ (JNIEnv *env, jclass cls) { jclass listClass; - if (init_libproc(getenv("LIBSAPROC_DEBUG")) != true) { + if (init_libproc(getenv("LIBSAPROC_DEBUG") != NULL) != true) { THROW_NEW_DEBUGGER_EXCEPTION("can't initialize libproc"); }
--- a/agent/src/os/linux/ps_proc.c Sat Sep 28 12:32:10 2013 +0400 +++ b/agent/src/os/linux/ps_proc.c Sat Sep 28 12:42:22 2013 -0700 @@ -27,6 +27,8 @@ #include <string.h> #include <signal.h> #include <errno.h> +#include <sys/types.h> +#include <sys/wait.h> #include <sys/ptrace.h> #include "libproc_impl.h"
--- a/agent/src/os/linux/salibelf.c Sat Sep 28 12:32:10 2013 +0400 +++ b/agent/src/os/linux/salibelf.c Sat Sep 28 12:42:22 2013 -0700 @@ -25,6 +25,7 @@ #include "salibelf.h" #include <stdlib.h> #include <unistd.h> +#include <string.h> extern void print_debug(const char*,...);
--- a/agent/src/os/linux/symtab.c Sat Sep 28 12:32:10 2013 +0400 +++ b/agent/src/os/linux/symtab.c Sat Sep 28 12:42:22 2013 -0700 @@ -305,7 +305,7 @@ unsigned char *bytes = (unsigned char*)(note+1) + note->n_namesz; - unsigned char *filename + char *filename = (build_id_to_debug_filename (note->n_descsz, bytes)); fd = pathmap_open(filename);
--- a/make/bsd/makefiles/gcc.make Sat Sep 28 12:32:10 2013 +0400 +++ b/make/bsd/makefiles/gcc.make Sat Sep 28 12:42:22 2013 -0700 @@ -247,7 +247,7 @@ ifeq ($(USE_CLANG), true) # However we need to clean the code up before we can unrestrictedly enable this option with Clang - WARNINGS_ARE_ERRORS += -Wno-unused-value -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses + WARNINGS_ARE_ERRORS += -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses WARNINGS_ARE_ERRORS += -Wno-switch -Wno-tautological-compare # Not yet supported by clang in Xcode 4.6.2 # WARNINGS_ARE_ERRORS += -Wno-tautological-constant-out-of-range-compare @@ -262,7 +262,7 @@ # conversions which might affect the values. Only enable it in earlier versions. WARNING_FLAGS = -Wunused-function ifeq ($(USE_CLANG),) - WARNINGS_FLAGS += -Wconversion + WARNING_FLAGS += -Wconversion endif endif
--- a/make/linux/makefiles/gcc.make Sat Sep 28 12:32:10 2013 +0400 +++ b/make/linux/makefiles/gcc.make Sat Sep 28 12:42:22 2013 -0700 @@ -208,7 +208,7 @@ ifeq ($(USE_CLANG), true) # However we need to clean the code up before we can unrestrictedly enable this option with Clang - WARNINGS_ARE_ERRORS += -Wno-unused-value -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses + WARNINGS_ARE_ERRORS += -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses WARNINGS_ARE_ERRORS += -Wno-switch -Wno-tautological-constant-out-of-range-compare -Wno-tautological-compare WARNINGS_ARE_ERRORS += -Wno-delete-non-virtual-dtor -Wno-deprecated -Wno-format -Wno-dynamic-class-memaccess WARNINGS_ARE_ERRORS += -Wno-return-type -Wno-empty-body
--- a/src/cpu/x86/vm/assembler_x86.cpp Sat Sep 28 12:32:10 2013 +0400 +++ b/src/cpu/x86/vm/assembler_x86.cpp Sat Sep 28 12:42:22 2013 -0700 @@ -4769,7 +4769,7 @@ } void Assembler::adcq(Register dst, Register src) { - (int) prefixq_and_encode(dst->encoding(), src->encoding()); + (void) prefixq_and_encode(dst->encoding(), src->encoding()); emit_arith(0x13, 0xC0, dst, src); } @@ -4824,7 +4824,7 @@ } void Assembler::andq(Register dst, Register src) { - (int) prefixq_and_encode(dst->encoding(), src->encoding()); + (void) prefixq_and_encode(dst->encoding(), src->encoding()); emit_arith(0x23, 0xC0, dst, src); }
--- a/src/share/vm/classfile/defaultMethods.cpp Sat Sep 28 12:32:10 2013 +0400 +++ b/src/share/vm/classfile/defaultMethods.cpp Sat Sep 28 12:42:22 2013 -0700 @@ -977,7 +977,7 @@ return target; } -#ifndef PRODUCT +#ifdef ASSERT // Return true is broad type is a covariant return of narrow type static bool covariant_return_type(BasicType narrow, BasicType broad) { if (narrow == broad) { @@ -988,7 +988,7 @@ } return false; } -#endif // ndef PRODUCT +#endif static int assemble_redirect( BytecodeConstantPool* cp, BytecodeBuffer* buffer, @@ -1281,4 +1281,3 @@ MetadataFactory::free_array(cld, original_ordering); } } -