diff options
Diffstat (limited to 'nlsolve.c')
-rw-r--r-- | nlsolve.c | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -34,12 +34,13 @@ #include <clBLAS.h> #endif +#include <threadpool.h> + #include "basis.h" #include "common.h" #include "log.h" #include "pssolve.h" #include "nlsolve.h" -#include "threadpool.h" #define NB_COEFFS(td) (td->nb_coeffs[0] * td->nb_coeffs[1]) #define NB_COLLOC_POINTS(td) (td->nb_colloc_points[0] * td->nb_colloc_points[1]) @@ -87,8 +88,8 @@ struct NLSolvePriv { double *delta; double *rhs; - ThreadPoolContext *tp; - ThreadPoolContext *tp_internal; + TPContext *tp; + TPContext *tp_internal; uint64_t solve_count; uint64_t solve_time; @@ -455,7 +456,7 @@ int tdi_nlsolve_context_init(NLSolveContext *ctx) if (ctx->tp) { s->tp = ctx->tp; } else { - ret = tdi_threadpool_init(&s->tp_internal, 1); + ret = tp_init(&s->tp_internal, 1); if (ret < 0) return ret; s->tp = s->tp_internal; @@ -545,7 +546,7 @@ void tdi_nlsolve_context_free(NLSolveContext **pctx) tdi_pssolve_context_free(&ctx->priv->ps_ctx); - tdi_threadpool_free(&ctx->priv->tp_internal); + tp_free(&ctx->priv->tp_internal); } free(ctx->priv); |