From 2a987c1e0a8d44e4d024e520127a6c48bad90261 Mon Sep 17 00:00:00 2001 From: Lutz Helwing Date: Fri, 16 Oct 2015 15:02:47 +0200 Subject: Updated version to 2.13.0 STABLE Updated release notes Fixed CMakeLists.txt Added -Wno-strict-aliasing Added license information for cityhash Added README for cityhash Signed-off-by: Lutz Helwing Signed-off-by: Alexander Wenzel --- CMakeLists.txt | 7 +- README | 1 + ReleaseNotes.txt | 27 ++++- src/core_dump_handler/cityhash_c/COPYING | 19 +++ src/core_dump_handler/cityhash_c/README | 196 +++++++++++++++++++++++++++++++ 5 files changed, 246 insertions(+), 4 deletions(-) create mode 100644 src/core_dump_handler/cityhash_c/COPYING create mode 100644 src/core_dump_handler/cityhash_c/README diff --git a/CMakeLists.txt b/CMakeLists.txt index 35cb7a8..3f68c59 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -24,8 +24,8 @@ set( CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS TRUE ) include ( GNUInstallDirs ) # Set version parameters set( DLT_MAJOR_VERSION 2) -set( DLT_MINOR_VERSION 12) -set( DLT_PATCH_LEVEL 1) +set( DLT_MINOR_VERSION 13) +set( DLT_PATCH_LEVEL 0) set( DLT_VERSION ${DLT_MAJOR_VERSION}.${DLT_MINOR_VERSION}.${DLT_PATCH_LEVEL}) set( DLT_VERSION_STATE STABLE ) set( DLT_REVISION "") @@ -69,7 +69,7 @@ option(WITH_DLT_SYSTEM "Set to ON to build src/system binaries" option(WITH_DLT_DBUS "Set to ON to build src/dbus binaries" ON) option(WITH_DLT_TESTS "Set to ON to build src/test binaries" ON) option(WITH_DLT_CXX11_EXT "Set to ON to build C++11 extensions" OFF) -option(WITH_DLT_COREDUMPHANDLER "EXPERIMENTAL! Set to ON to build src/core_dump_handler binaries. EXPERIMENTAL" OFF +option(WITH_DLT_COREDUMPHANDLER "EXPERIMENTAL! Set to ON to build src/core_dump_handler binaries. EXPERIMENTAL" OFF) # RPM settings set( GENIVI_RPM_RELEASE "1")#${DLT_REVISION}") set( LICENSE "Mozilla Public License Version 2.0" ) @@ -116,6 +116,7 @@ add_definitions( "-Wall" ) add_definitions( "-Wextra" ) #add_definitions( "-pedantic" ) add_definitions( "-Wno-variadic-macros" ) +add_definitions( "-Wno-strict-aliasing" ) IF(${WITH_DOC} STREQUAL "OFF") SET(PACKAGE_DOC "#") diff --git a/README b/README index e20a523..7d7f5ab 100644 --- a/README +++ b/README @@ -56,6 +56,7 @@ Developped and tested with Ubuntu Linux 12.04 32-bit / Intel PC License ------- Full information on the license for this software is available in the "LICENSE" file. +Full information on the license for the cityhash code is available in "LICENSE" file in src/core_dump_handler/cityhash_c. Source Code ----------- diff --git a/ReleaseNotes.txt b/ReleaseNotes.txt index ee94c35..56254a5 100644 --- a/ReleaseNotes.txt +++ b/ReleaseNotes.txt @@ -4,11 +4,36 @@ Alexander Wenzel Version ------- -2.12.1 STABLE +2.13.0 STABLE Changes ------- +2.13.0 + + * Added core dump handler code + * Purged all warnings for -Wall -Wextra with gcc 4.9.1 + * Set DLT_USER_BUF_MAX_SIZE to 1390 to prepare UDP message transport + * dlt-test-client and dlt-test-filetransfer have global failed test counter so they can return 1 on failure + * Using DLT_USER_BUF_MAX_SIZE in dlt-test-client.c truncated check + * Set path to /usr/local/share/ in dlt-test-filetransfer.c + * Added programme to test repeated calls of dlt_init and dlt_free + * DLT daemon improvement - dlt_init()-check + * DLT daemon improvement - parameter value range check + * Adapt unit tests to check for enum return values + * Changed C version to gnu99 and C++ version to gnu++0x + * Fixed bug in INTERNAL-mode connection + * Use the best possible timestamp for all system journal entries + * Make timeout in at_exit handler configurable + * Allow multiple instances of dlt-daemon + * Fixed whitespace, formatting and licence headers of new code + * Add C++ extension which uses variadic templates from C++ 11 (disabled by default) + * Allow registration of contexts before application is registered + * Add env-var to set initial log-levels + * Allow applications to fork() + * Fixed file permissions + * Added offline logstorage implementation which can be used instead of the already available offline trace functionality + 2.12.1 * Removed all trailing whitespaces diff --git a/src/core_dump_handler/cityhash_c/COPYING b/src/core_dump_handler/cityhash_c/COPYING new file mode 100644 index 0000000..5f9b126 --- /dev/null +++ b/src/core_dump_handler/cityhash_c/COPYING @@ -0,0 +1,19 @@ +// Copyright (c) 2011 Google, Inc. +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. \ No newline at end of file diff --git a/src/core_dump_handler/cityhash_c/README b/src/core_dump_handler/cityhash_c/README new file mode 100644 index 0000000..4155a85 --- /dev/null +++ b/src/core_dump_handler/cityhash_c/README @@ -0,0 +1,196 @@ +CityHash, a family of hash functions for strings. + + +Introduction +============ + +CityHash provides hash functions for strings. The functions mix the +input bits thoroughly but are not suitable for cryptography. See +"Hash Quality," below, for details on how CityHash was tested and so on. + +We provide reference implementations in C++, with a friendly MIT license. + +CityHash32() returns a 32-bit hash. + +CityHash64() and similar return a 64-bit hash. + +CityHash128() and similar return a 128-bit hash and are tuned for +strings of at least a few hundred bytes. Depending on your compiler +and hardware, it's likely faster than CityHash64() on sufficiently long +strings. It's slower than necessary on shorter strings, but we expect +that case to be relatively unimportant. + +CityHashCrc128() and similar are variants of CityHash128() that depend +on _mm_crc32_u64(), an intrinsic that compiles to a CRC32 instruction +on some CPUs. However, none of the functions we provide are CRCs. + +CityHashCrc256() is a variant of CityHashCrc128() that also depends +on _mm_crc32_u64(). It returns a 256-bit hash. + +All members of the CityHash family were designed with heavy reliance +on previous work by Austin Appleby, Bob Jenkins, and others. +For example, CityHash32 has many similarities with Murmur3a. + +Performance on long strings: 64-bit CPUs +======================================== + +We are most excited by the performance of CityHash64() and its variants on +short strings, but long strings are interesting as well. + +CityHash is intended to be fast, under the constraint that it hash very +well. For CPUs with the CRC32 instruction, CRC is speedy, but CRC wasn't +designed as a hash function and shouldn't be used as one. CityHashCrc128() +is not a CRC, but it uses the CRC32 machinery. + +On a single core of a 2.67GHz Intel Xeon X5550, CityHashCrc256 peaks at about +5 to 5.5 bytes/cycle. The other CityHashCrc functions are wrappers around +CityHashCrc256 and should have similar performance on long strings. +(CityHashCrc256 in v1.0.3 was even faster, but we decided it wasn't as thorough +as it should be.) CityHash128 peaks at about 4.3 bytes/cycle. The fastest +Murmur variant on that hardware, Murmur3F, peaks at about 2.4 bytes/cycle. +We expect the peak speed of CityHash128 to dominate CityHash64, which is +aimed more toward short strings or use in hash tables. + +For long strings, a new function by Bob Jenkins, SpookyHash, is just +slightly slower than CityHash128 on Intel x86-64 CPUs, but noticeably +faster on AMD x86-64 CPUs. For hashing long strings on AMD CPUs +and/or CPUs without the CRC instruction, SpookyHash may be just as +good or better than any of the CityHash variants. + +Performance on short strings: 64-bit CPUs +========================================= + +For short strings, e.g., most hash table keys, CityHash64 is faster than +CityHash128, and probably faster than all the aforementioned functions, +depending on the mix of string lengths. Here are a few results from that +same hardware, where we (unrealistically) tested a single string length over +and over again: + +Hash Results +------------------------------------------------------------------------------ +CityHash64 v1.0.3 7ns for 1 byte, or 6ns for 8 bytes, or 9ns for 64 bytes +Murmur2 (64-bit) 6ns for 1 byte, or 6ns for 8 bytes, or 15ns for 64 bytes +Murmur3F 14ns for 1 byte, or 15ns for 8 bytes, or 23ns for 64 bytes + +We don't have CityHash64 benchmarks results for v1.1, but we expect the +numbers to be similar. + +Performance: 32-bit CPUs +======================== + +CityHash32 is the newest variant of CityHash. It is intended for +32-bit hardware in general but has been mostly tested on x86. Our benchmarks +suggest that Murmur3 is the nearest competitor to CityHash32 on x86. +We don't know of anything faster that has comparable quality. The speed rankings +in our testing: CityHash32 > Murmur3f > Murmur3a (for long strings), and +CityHash32 > Murmur3a > Murmur3f (for short strings). + +Installation +============ + +We provide reference implementations of several CityHash functions, written +in C++. The build system is based on autoconf. It defaults the C++ +compiler flags to "-g -O2", which is probably slower than -O3 if you are +using gcc. YMMV. + +On systems with gcc, we generally recommend: + +./configure +make all check CXXFLAGS="-g -O3" +sudo make install + +Or, if your system has the CRC32 instruction, and you want to build everything: + +./configure --enable-sse4.2 +make all check CXXFLAGS="-g -O3 -msse4.2" +sudo make install + +Note that our build system doesn't try to determine the appropriate compiler +flag for enabling SSE4.2. For gcc it is "-msse4.2". The --enable-sse4.2 +flag to the configure script controls whether citycrc.h is installed when +you "make install." In general, picking the right compiler flags can be +tricky, and may depend on your compiler, your hardware, and even how you +plan to use the library. + +For generic information about how to configure this software, please try: + +./configure --help + +Failing that, please work from city.cc and city*.h, as they contain all the +necessary code. + + +Usage +===== + +The above installation instructions will produce a single library. It will +contain CityHash32(), CityHash64(), and CityHash128(), and their variants, +and possibly CityHashCrc128(), CityHashCrc128WithSeed(), and +CityHashCrc256(). The functions with Crc in the name are declared in +citycrc.h; the rest are declared in city.h. + + +Limitations +=========== + +1) CityHash32 is intended for little-endian 32-bit code, and everything else in +the current version of CityHash is intended for little-endian 64-bit CPUs. + +All functions that don't use the CRC32 instruction should work in +little-endian 32-bit or 64-bit code. CityHash should work on big-endian CPUs +as well, but we haven't tested that very thoroughly yet. + +2) CityHash is fairly complex. As a result of its complexity, it may not +perform as expected on some compilers. For example, preliminary reports +suggest that some Microsoft compilers compile CityHash to assembly that's +10-20% slower than it could be. + + +Hash Quality +============ + +We like to test hash functions with SMHasher, among other things. +SMHasher isn't perfect, but it seems to find almost any significant flaw. +SMHasher is available at http://code.google.com/p/smhasher/ + +SMHasher is designed to pass a 32-bit seed to the hash functions it tests. +No CityHash function is designed to work that way, so we adapt as follows: +For our functions that accept a seed, we use the given seed directly (padded +with zeroes); for our functions that don't accept a seed, we hash the +concatenation of the given seed and the input string. + +The CityHash functions have the following flaws according to SMHasher: + +(1) CityHash64: none + +(2) CityHash64WithSeed: none + +(3) CityHash64WithSeeds: did not test + +(4) CityHash128: none + +(5) CityHash128WithSeed: none + +(6) CityHashCrc128: none + +(7) CityHashCrc128WithSeed: none + +(8) CityHashCrc256: none + +(9) CityHash32: none + +Some minor flaws in 32-bit and 64-bit functions are harmless, as we +expect the primary use of these functions will be in hash tables. We +may have gone slightly overboard in trying to please SMHasher and other +similar tests, but we don't want anyone to choose a different hash function +because of some minor issue reported by a quality test. + + +For more information +==================== + +http://code.google.com/p/cityhash/ + +cityhash-discuss@googlegroups.com + +Please feel free to send us comments, questions, bug reports, or patches. \ No newline at end of file -- cgit v1.2.1