146 Commits

Author SHA1 Message Date
Gael Guennebaud
74beb218d2 Fix bug #554: include unistd.h before checking the presence of posix_memalign. 2013-06-26 22:49:14 +02:00
Gael Guennebaud
899c0c2b6c Clean source code and unit tests with respect to -Wunused-local-typedefs 2013-04-10 22:27:35 +02:00
Gael Guennebaud
7e04d7db02 Fix a serious bug in handmade_aligned_realloc: original data have to be moved if the alignment offset differs. 2013-04-10 13:58:20 +02:00
Gael Guennebaud
f29b4c435b Make cpuid not use %%esi -> dangerous if someone is using it. 2013-03-19 14:11:59 +01:00
Michael Schmidt
0d5a418048 Fix bug #566: rbx register has to be saved when calling cpuid on x84_64 with -fPIC and medium or large code models. 2013-03-19 14:00:42 +01:00
Gael Guennebaud
b6dc2613ac Fix bug #552: disable EIGEN_GLIBC_MALLOC_ALREADY_ALIGNED when compiling with -fsanitize=address, and allow users to manually tell whether EIGEN_MALLOC_ALREADY_ALIGNED. 2013-02-25 19:17:13 +01:00
Gael Guennebaud
25bcbfb10c Fix bug in aligned_free with windows CE 2013-02-13 19:09:31 +01:00
Gael Guennebaud
aa858cb43a add first_multiple helper function 2012-10-30 16:27:52 +01:00
Gael Guennebaud
138897cc06 fix bug #521: __cpuidex is not available on all architectures supported by MSVC 2012-10-24 10:21:41 +02:00
Gael Guennebaud
9b418afff6 Windows CE does not provide an aligned_malloc function. 2012-10-24 10:12:42 +02:00
Benoit Jacob
69124cfca2 Automatic relicensing to MPL2 using Keirs script. Manual fixup follows. 2012-07-13 14:42:47 -04:00
Gael Guennebaud
ce2e2fe336 bug #455: add support for c++11 in aligned_allocator 2012-05-03 11:55:30 +02:00
Jitse Niesen
3c412183b2 Get rid of include directives inside namespace blocks (bug #339). 2012-04-15 11:06:28 +01:00
Gael Guennebaud
99c694623a fix a dozen of warnings with MSVC, and get rid of some useless throw() 2012-02-06 15:57:51 +01:00
Zuiquan
a64407f086 Enable Eigen to compile on 'pure C/C++' Gcc environment (with no inline assembly or asm directive). Required if we want to use Eigen with Adobe Alchemy. 2012-02-02 12:05:02 +01:00
Gael Guennebaud
634fedaf68 proper C++ casting 2012-01-31 18:56:25 +01:00
Gael Guennebaud
9c86ee2695 fix static inline versus inline static issues (the former is the correct order) 2012-01-31 12:58:52 +01:00
Gael Guennebaud
8d6e394b06 workaround "empty macro argument" warning 2012-01-31 12:46:14 +01:00
Gael Guennebaud
59576014a9 fig bug #373: compilation error with clang 2.9 when exceptions are disabled (cannot reproduce with clang 3.0 or 3.1) 2011-12-05 09:44:25 +01:00
Benoit Jacob
1b98b73472 Refactor force-inlining macros and use EIGEN_ALWAYS_INLINE to force inlining of the integer overflow helpers, whose non-inlining caused major performance problems, see the mailing list thread 'Significant perf regression probably due to bug #363 patches' 2011-11-06 16:27:41 -05:00
Benoit Jacob
de69129f56 forgot inline keyword 2011-10-17 08:49:59 -04:00
Benoit Jacob
16b638c159 Throw std::bad_alloc even when exceptions are disabled, by doing new int[size_t(-1)].
Don't throw exceptions on aligned_malloc(0) (just because malloc's retval is null doesn't mean error, if size==0).
Remove EIGEN_NO_EXCEPTIONS option, use only compiler standard defines. Either exceptions are enabled or they aren't.
2011-10-17 08:44:44 -04:00
Benoit Jacob
0c6055c285 bug #363 - check for integer overflow in byte-size computations 2011-10-16 16:12:19 -04:00
Gael Guennebaud
22bff949c8 protect calls to min and max with parentheses to make Eigen compatible with default windows.h
(transplanted from 49b6e9143e1d74441924c0c313536e263e12a55c
)
2011-07-21 11:19:36 +02:00
Gael Guennebaud
f82b3ea241 fix aligned_allocator::allocate interface 2011-06-14 08:50:25 +02:00
Gael Guennebaud
6d3dee1b66 introduce a smart_copy internal function and fix sparse matrices with non POD scalar type 2011-06-09 19:04:06 +02:00
Gael Guennebaud
179d42bb2b fix bug #267: alloca is not aligned on arm 2011-05-17 21:30:12 +02:00
Gael Guennebaud
6441e8727b fix aligned_stack_memory_handler for null pointers 2011-04-21 09:00:55 +02:00
Gael Guennebaud
b8ecda5c66 clean a bit the stack allocation mechanism 2011-03-19 10:27:47 +01:00
Gael Guennebaud
290205dfc0 fix memory leak when a custom scalar throw an exception 2011-03-19 01:06:50 +01:00
Benoit Jacob
bfcad536e8 * bug #206: correctly forward computationOptions and work towards avoiding mallocs after preallocation, with unit test.
* added EIGEN_RUNTIME_NO_MALLOC and new set_is_malloc_allowed() function to implement that test
2011-03-06 20:59:25 -05:00
Gael Guennebaud
40526e24b4 fix memory leak (when conservatively resizing vectors of dynamically allocated scalar types such as bugnums) 2011-02-07 19:52:16 +01:00
Gael Guennebaud
1eb85b4cf1 allow the possibility to automatically call or not the ctors on a per scalar type basis, and disable automatic initialization of std::complex<> 2011-01-26 17:56:49 +01:00
Benoit Jacob
c7eaca50a0 __cpuidex is not (always) present in VS 2008 + SP1, it seems 2011-01-17 11:17:45 -05:00
Jose Luis Blanco
cbfab7204f Update of CPUID macros to fix segfaults in amd64 code. 2011-01-05 02:43:43 +01:00
Thomas Capricelli
7a29ae0b5c fix preprocessor checks for availability of cpuid 2010-12-28 13:46:39 +01:00
Jitse Niesen
cad73d9cdc Correct std::map fix (two commits ago); copy fix to aligned_allocator doc. 2010-11-12 12:06:24 +00:00
Benoit Jacob
4716040703 bug #86 : use internal:: namespace instead of ei_ prefix 2010-10-25 10:15:22 -04:00
Gael Guennebaud
a76ce042e6 MSVC for windows mobile does not have the errno.h file 2010-10-07 18:09:15 +02:00
Gael Guennebaud
90d6fc0e28 fix ei_aligned_delete for null pointers and non trivial dtors 2010-07-14 22:49:34 +02:00
Jitse Niesen
49747fa4a9 Various documentation improvements.
* Add short documentation for Array class
* Put all classes explicitly in Core module (where applicable)
* Section on Modules in Quick Reference Guide
* Put Page 7 after Page 6 in Contents :)
2010-07-06 13:10:08 +01:00
Gael Guennebaud
7d23e7f9f1 indentation 2010-07-06 11:02:01 +02:00
Gael Guennebaud
8db60afb47 oops I did not see that 2010-07-05 21:27:15 +02:00
Konstantinos Margaritis
1505221263 add check for non x86 platforms, we get a compile error on arm/powerpc without the check
(there is no known -yet- method to get cpuid, without resolving to kernel /sys interface)
2010-07-05 16:44:41 +03:00
Gael Guennebaud
f096452dfd Fix cache computation on old Intel CPUs which do not
support the cpuid function 0x4
2010-06-27 00:17:38 +02:00
Gael Guennebaud
931027f31b add a utilility to debug cpuid, and makes sure we get 0 if we query an unsupported cpuid function 2010-06-26 23:15:06 +02:00
Gael Guennebaud
28e64b0da3 email change 2010-06-24 23:21:58 +02:00
Hauke Heibel
0068d3ccf6 Added version testing for MSVC. 2010-06-24 10:05:24 +02:00
Hauke Heibel
83f1b747e7 Fixed MSVC cpuid. 2010-06-24 09:55:53 +02:00
Gael Guennebaud
0a42f8c876 fix compilation when EIGEN_CPUD is not defined 2010-06-24 09:45:17 +02:00