Re: [brlcad-devel] bool_eval()

2017-08-14 Thread Vasco Alexandre da Silva Costa
Ok, I ran those tests on a machine with an AMD FX 8350 CPU and an NVIDIA GTX TITAN GPU. Results attached. It's up to 2x faster on the GPU than the CPU but the speedup is less interesting in goliath.g, because of the depth complexity of the scene I think. We basically need to do a breadth-first

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Vasco Alexandre da Silva Costa
On Fri, Aug 11, 2017 at 12:40 AM, Vasco Alexandre da Silva Costa < vasco.co...@gmail.com> wrote: ... > The other issue that should be causing slowdowns is that the ANSI C code > in rt_shootray() intersects one solid at a time and calls rt_bootfinal() on > the partial results before continuing. In

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Vasco Alexandre da Silva Costa
On Fri, Aug 11, 2017 at 12:40 AM, Vasco Alexandre da Silva Costa < vasco.co...@gmail.com> wrote: > PS: If you really wanna know what I think is happening i suspect that in > complex scenes, where the bitvectors are really sparse, we would have been > better off using lists like the ANSI C code

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Vasco Alexandre da Silva Costa
On Fri, Aug 11, 2017 at 12:20 AM, Vasco Alexandre da Silva Costa < vasco.co...@gmail.com> wrote: > On Thu, Aug 10, 2017 at 11:36 PM, Marco Domingues < > marcodomingue...@gmail.com> wrote: > >> Hi, >> >> Thanks for reviewing my code and making the adjustments, Vasco! I’ve >> integrated the changes

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Marco Domingues
> On 11 Aug 2017, at 00:20, Vasco Alexandre da Silva Costa > wrote: > > On Thu, Aug 10, 2017 at 11:36 PM, Marco Domingues > wrote: > Hi, > > Thanks for reviewing my code and making the adjustments, Vasco!

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Vasco Alexandre da Silva Costa
On Thu, Aug 10, 2017 at 11:36 PM, Marco Domingues < marcodomingue...@gmail.com> wrote: > Hi, > > Thanks for reviewing my code and making the adjustments, Vasco! I’ve > integrated the changes in my patch. > > I’ve finished the port of the new bool_eval() function to OpenCL, and > although the

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Marco Domingues
Hi, Thanks for reviewing my code and making the adjustments, Vasco! I’ve integrated the changes in my patch. I’ve finished the port of the new bool_eval() function to OpenCL, and although the improved performance, it wasn’t enough to outperform the ANSI C code with the Release build. For

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Vasco Alexandre da Silva Costa
On Thu, Aug 10, 2017 at 5:15 PM, Christopher Sean Morrison wrote: > ... > > Related to these specific changes, these numbers pass a sanity check. If > you ran a profile (e.g., perf), you’d see that only a fraction of time is > spent in boolean code (10-30% of time, depending on

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Christopher Sean Morrison
> Yes, at the time I ran three different benchmarks over the non-opencl version > because I was trying to compare three different versions of the ANSI C code. > This was, the ANSI C code currently in the trunk, the code in the trunk with > the patch #473 applied (patch from Vasco that removed

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Marco Domingues
Hi, > On 10 Aug 2017, at 10:13, Christopher Sean Morrison wrote: > > Marco, > > I saw your benchmark logs and it looks like you ran the non-opencl version > three times, which is almost certainly why the performance rankings were > nearly identical. You’ll want to run

Re: [brlcad-devel] bool_eval()

2017-08-10 Thread Christopher Sean Morrison
Marco, I saw your benchmark logs and it looks like you ran the non-opencl version three times, which is almost certainly why the performance rankings were nearly identical. You’ll want to run “TIMEFRAME=60 DEVIATION=1 benchmark run” for the non-ocl path and “TIMEFRAME=60 DEVIATION=1 benchmark