Merge pull request #1559 from vsytch/win10_aligned_alloc
Fixes for hipMemcpy_simple on Windows
Dieser Commit ist enthalten in:
@@ -120,8 +120,8 @@ void simpleTest2(size_t numElements, bool usePinnedHost) {
|
||||
HIPCHECK(hipHostFree(A_h1));
|
||||
HIPCHECK(hipHostFree(A_h2));
|
||||
} else {
|
||||
free(A_h1);
|
||||
free(A_h2);
|
||||
aligned_free(A_h1);
|
||||
aligned_free(A_h2);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -99,10 +99,13 @@ THE SOFTWARE.
|
||||
|
||||
#ifdef _WIN64
|
||||
#include <tchar.h>
|
||||
#define aligned_alloc _aligned_malloc
|
||||
#define aligned_alloc(x,y) _aligned_malloc(y,x)
|
||||
#define aligned_free(x) _aligned_free(x)
|
||||
#define popen(x,y) _popen(x,y)
|
||||
#define pclose(x) _pclose(x)
|
||||
#define setenv(x,y,z) _putenv_s(x,y)
|
||||
#else
|
||||
#define aligned_free(x) free(x)
|
||||
#endif
|
||||
|
||||
// standard command-line variables:
|
||||
|
||||
In neuem Issue referenzieren
Einen Benutzer sperren