source: mmcs/Eigen/QtAlignedMalloc @ 8daa049

matrices
Last change on this file since 8daa049 was 8daa049, checked in by rboet <rboet@…>, 9 years ago

Calculos de Ma completos, encadenamientos funcionales

  • Property mode set to 100644
File size: 637 bytes
Line 
1
2#ifndef EIGEN_QTMALLOC_MODULE_H
3#define EIGEN_QTMALLOC_MODULE_H
4
5#include "Core"
6
7#if (!EIGEN_MALLOC_ALREADY_ALIGNED)
8
9#include "src/Core/util/DisableStupidWarnings.h"
10
11void *qMalloc(size_t size)
12{
13  return Eigen::internal::aligned_malloc(size);
14}
15
16void qFree(void *ptr)
17{
18  Eigen::internal::aligned_free(ptr);
19}
20
21void *qRealloc(void *ptr, size_t size)
22{
23  void* newPtr = Eigen::internal::aligned_malloc(size);
24  memcpy(newPtr, ptr, size);
25  Eigen::internal::aligned_free(ptr);
26  return newPtr;
27}
28
29#include "src/Core/util/ReenableStupidWarnings.h"
30
31#endif
32
33#endif // EIGEN_QTMALLOC_MODULE_H
34/* vim: set filetype=cpp et sw=2 ts=2 ai: */
Note: See TracBrowser for help on using the repository browser.