From 7bf64bc4900564c3098b7acd5a90a170d35da626 Mon Sep 17 00:00:00 2001 From: Ilia Filippov Date: Thu, 19 Dec 2013 17:57:29 +0400 Subject: [PATCH] changes in examples (windows) --- examples/aobench/aobench.vcxproj | 18 ++++++++++++ examples/common.props | 28 +++++++++---------- examples/deferred/deferred_shading.vcxproj | 18 ++++++++++++ examples/mandelbrot/mandelbrot.vcxproj | 18 ++++++++++++ .../mandelbrot_tasks/mandelbrot_tasks.vcxproj | 18 ++++++++++++ examples/noise/noise.vcxproj | 18 ++++++++++++ examples/options/options.vcxproj | 18 ++++++++++++ examples/rt/rt.vcxproj | 18 ++++++++++++ examples/sort/sort.vcxproj | 18 ++++++++++++ examples/stencil/stencil.vcxproj | 18 ++++++++++++ examples/tasksys.cpp | 9 +++++- examples/volume_rendering/volume.vcxproj | 18 ++++++++++++ 12 files changed, 202 insertions(+), 15 deletions(-) diff --git a/examples/aobench/aobench.vcxproj b/examples/aobench/aobench.vcxproj index c46ee41a..298be2cb 100644 --- a/examples/aobench/aobench.vcxproj +++ b/examples/aobench/aobench.vcxproj @@ -1,5 +1,23 @@  + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {F29204CA-19DF-4F3C-87D5-03F4EEDAAFEB} Win32Proj diff --git a/examples/common.props b/examples/common.props index 7bf37005..3769330b 100644 --- a/examples/common.props +++ b/examples/common.props @@ -146,24 +146,24 @@ ispc $(default_targets) - $(TargetDir)$(ISPC_file).obj - $(Target_out);$(TargetDir)$(ISPC_file)_sse2.obj - $(Target_out);$(TargetDir)$(ISPC_file)_sse4.obj - $(Target_out);$(TargetDir)$(ISPC_file)_avx.obj - $(Target_out);$(TargetDir)$(ISPC_file)_avx11.obj - $(Target_out);$(TargetDir)$(ISPC_file)_avx2.obj + $(ISPC_file).obj + $(Target_out);$(ISPC_file)_sse2.obj + $(Target_out);$(ISPC_file)_sse4.obj + $(Target_out);$(ISPC_file)_avx.obj + $(Target_out);$(ISPC_file)_avx11.obj + $(Target_out);$(ISPC_file)_avx2.obj Document - $(ISPC_compiler) -O2 %(Filename).ispc -o $(TargetDir)%(Filename).obj -h $(TargetDir)%(Filename)_ispc.h --arch=x86 --target=$(Target_str) - $(ISPC_compiler) -O2 %(Filename).ispc -o $(TargetDir)%(Filename).obj -h $(TargetDir)%(Filename)_ispc.h --target=$(Target_str) - $(Target_out);$(TargetDir)%(Filename)_ispc.h - $(Target_out);$(TargetDir)%(Filename)_ispc.h - $(ISPC_compiler) -O2 %(Filename).ispc -o $(TargetDir)%(Filename).obj -h $(TargetDir)%(Filename)_ispc.h --arch=x86 --target=$(Target_str) - $(ISPC_compiler) -O2 %(Filename).ispc -o $(TargetDir)%(Filename).obj -h $(TargetDir)%(Filename)_ispc.h --target=$(Target_str) - $(Target_out);$(TargetDir)%(Filename)_ispc.h - $(Target_out);$(TargetDir)%(Filename)_ispc.h + $(ISPC_compiler) -O2 %(Filename).ispc -o %(Filename).obj -h %(Filename)_ispc.h --arch=x86 --target=$(Target_str) + $(ISPC_compiler) -O2 %(Filename).ispc -o %(Filename).obj -h %(Filename)_ispc.h --target=$(Target_str) + $(Target_out) + $(Target_out) + $(ISPC_compiler) -O2 %(Filename).ispc -o %(Filename).obj -h %(Filename)_ispc.h --arch=x86 --target=$(Target_str) + $(ISPC_compiler) -O2 %(Filename).ispc -o %(Filename).obj -h %(Filename)_ispc.h --target=$(Target_str) + $(Target_out) + $(Target_out) diff --git a/examples/deferred/deferred_shading.vcxproj b/examples/deferred/deferred_shading.vcxproj index cd361b26..974e870b 100755 --- a/examples/deferred/deferred_shading.vcxproj +++ b/examples/deferred/deferred_shading.vcxproj @@ -1,5 +1,23 @@ + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {87f53c53-957e-4e91-878a-bc27828fb9eb} Win32Proj diff --git a/examples/mandelbrot/mandelbrot.vcxproj b/examples/mandelbrot/mandelbrot.vcxproj index e7703ad0..7a5f6e03 100644 --- a/examples/mandelbrot/mandelbrot.vcxproj +++ b/examples/mandelbrot/mandelbrot.vcxproj @@ -1,5 +1,23 @@  + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {6D3EF8C5-AE26-407B-9ECE-C27CB988D9C1} Win32Proj diff --git a/examples/mandelbrot_tasks/mandelbrot_tasks.vcxproj b/examples/mandelbrot_tasks/mandelbrot_tasks.vcxproj index f8b8cfcb..113fc4e8 100644 --- a/examples/mandelbrot_tasks/mandelbrot_tasks.vcxproj +++ b/examples/mandelbrot_tasks/mandelbrot_tasks.vcxproj @@ -1,5 +1,23 @@ + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {E80DA7D4-AB22-4648-A068-327307156BE6} Win32Proj diff --git a/examples/noise/noise.vcxproj b/examples/noise/noise.vcxproj index 7adc57f3..ff3953ae 100644 --- a/examples/noise/noise.vcxproj +++ b/examples/noise/noise.vcxproj @@ -1,5 +1,23 @@ + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {0E0886D8-8B5E-4EAF-9A21-91E63DAF81FD} Win32Proj diff --git a/examples/options/options.vcxproj b/examples/options/options.vcxproj index af336aa1..d48ac8bc 100644 --- a/examples/options/options.vcxproj +++ b/examples/options/options.vcxproj @@ -1,5 +1,23 @@ + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {8C7B5D29-1E76-44E6-BBB8-09830E5DEEAE} Win32Proj diff --git a/examples/rt/rt.vcxproj b/examples/rt/rt.vcxproj index ea34de56..00b6dd3a 100644 --- a/examples/rt/rt.vcxproj +++ b/examples/rt/rt.vcxproj @@ -1,5 +1,23 @@ + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {E787BC3F-2D2E-425E-A64D-4721E2FF3DC9} Win32Proj diff --git a/examples/sort/sort.vcxproj b/examples/sort/sort.vcxproj index 43f2b439..b0bdc63d 100644 --- a/examples/sort/sort.vcxproj +++ b/examples/sort/sort.vcxproj @@ -1,5 +1,23 @@  + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {6D3EF8C5-AE26-407B-9ECE-C27CB988D9C2} Win32Proj diff --git a/examples/stencil/stencil.vcxproj b/examples/stencil/stencil.vcxproj index b5f5bb22..fd8564aa 100644 --- a/examples/stencil/stencil.vcxproj +++ b/examples/stencil/stencil.vcxproj @@ -1,5 +1,23 @@ + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {2ef070a1-f62f-4e6a-944b-88d140945c3c} Win32Proj diff --git a/examples/tasksys.cpp b/examples/tasksys.cpp index cfe0b17b..77269f9f 100644 --- a/examples/tasksys.cpp +++ b/examples/tasksys.cpp @@ -175,6 +175,9 @@ typedef void (*TaskFuncType)(void *data, int threadIndex, int threadCount, int taskCount0, int taskCount1, int taskCount2); // Small structure used to hold the data for each task +#ifdef _MSC_VER +__declspec(align(16)) +#endif struct TaskInfo { TaskFuncType func; void *data; @@ -200,7 +203,11 @@ struct TaskInfo { int taskCount1() const { return taskCount3d[1]; } int taskCount2() const { return taskCount3d[2]; } TaskInfo() { assert(sizeof(TaskInfo) % 32 == 0); } -} __attribute__((aligned(32))); +} +#ifndef _MSC_VER +__attribute__((aligned(32))); +#endif +; // ispc expects these functions to have C linkage / not be mangled extern "C" { diff --git a/examples/volume_rendering/volume.vcxproj b/examples/volume_rendering/volume.vcxproj index cc738a7e..a1fea5f1 100644 --- a/examples/volume_rendering/volume.vcxproj +++ b/examples/volume_rendering/volume.vcxproj @@ -1,5 +1,23 @@ + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + {dee5733a-e93e-449d-9114-9bffcaeb4df9} Win32Proj