Merged the patch submitted by Tamas Nepusz to fix some problems on Mac OS X.
This commit is contained in:
parent
94854170e7
commit
327d0a5f80
@ -2,6 +2,7 @@
|
||||
|
||||
* libLBFGS 1.10:
|
||||
- Fixed compiling errors on Mac OS X; this patch was kindly submitted by Nic Schraudolph.
|
||||
- Reduced compiling warnings on Mac OS X; this patch was kindly submitted by Tamas Nepusz.
|
||||
|
||||
|
||||
2010-01-29 Naoaki Okazaki <okazaki at chokkan org>
|
||||
|
@ -601,6 +601,8 @@ libLBFGS is distributed under the term of the
|
||||
- Version 1.10 (2010-xx-xx):
|
||||
- Fixed compiling errors on Mac OS X; this patch was kindly submitted by
|
||||
Nic Schraudolph.
|
||||
- Reduced compiling warnings on Mac OS X; this patch was kindly submitted
|
||||
by Tamas Nepusz.
|
||||
- Version 1.9 (2010-01-29):
|
||||
- Fixed a mistake in checking the validity of the parameters "ftol" and
|
||||
"wolfe"; this was discovered by Kevin S. Van Horn.
|
||||
@ -721,7 +723,7 @@ Special thanks go to:
|
||||
- Yoshimasa Tsuruoka and Daisuke Okanohara for technical information about
|
||||
OWL-QN
|
||||
- Takashi Imamichi for the useful enhancements of the backtracking method
|
||||
- Kevin S. Van Horn and Nic Schraudolph for bug fixes
|
||||
- Kevin S. Van Horn, Nic Schraudolph, and Tamas Nepusz for bug fixes
|
||||
|
||||
Finally I would like to thank the original author, Jorge Nocedal, who has been
|
||||
distributing the effieicnt and explanatory implementation in an open source
|
||||
|
@ -65,6 +65,7 @@ licence.
|
||||
#include <config.h>
|
||||
#endif/*HAVE_CONFIG_H*/
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <math.h>
|
||||
@ -73,7 +74,6 @@ licence.
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#define inline __inline
|
||||
typedef unsigned int uint32_t;
|
||||
#endif/*_MSC_VER*/
|
||||
|
||||
#if defined(USE_SSE) && defined(__SSE2__) && LBFGS_FLOAT == 64
|
||||
@ -290,7 +290,7 @@ int lbfgs(
|
||||
if (n % 8 != 0) {
|
||||
return LBFGSERR_INVALID_N_SSE;
|
||||
}
|
||||
if (((unsigned short)x & 0x000F) != 0) {
|
||||
if ((uintptr_t)(const void*)x % 16 == 0) {
|
||||
return LBFGSERR_INVALID_X_SSE;
|
||||
}
|
||||
#endif/*defined(USE_SSE)*/
|
||||
@ -490,7 +490,7 @@ int lbfgs(
|
||||
|
||||
/* Report the progress. */
|
||||
if (cd.proc_progress) {
|
||||
if (ret = cd.proc_progress(cd.instance, x, g, fx, xnorm, gnorm, step, cd.n, k, ls)) {
|
||||
if ((ret = cd.proc_progress(cd.instance, x, g, fx, xnorm, gnorm, step, cd.n, k, ls))) {
|
||||
goto lbfgs_exit;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user