cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
tetsuo_yamashita
Participant
Participant
1,075 Views
Registered: ‎08-03-2017

Why is process speed so different from "Release build" and "Release build with estimate performance" ?

Jump to solution

Hello,

 

I have tried reVision Stack template.

I noticed that process speed is different from "Release build" and "Release build with estimate performance" ?

 

Release build

root@xilinx-zc702-2017_2:/media/card# ./fileio_bilateral.elf im0.jpg
sigma_color: 7.72211 sigma_space: 0.901059
OpenCV bilateral filter function : elapsed time 130358528
xfOpenCV bilateral filter function : elapsed time 14312978
Minimum error in intensity = 0
Maximum error in intensity = 1
Percentage of pixels above error threshold = 0.00163966 Count: 34

Release build with "estimate performance"

root@xilinx-zc702-2017_2:/media/card# ./fileio_bilateral.elf im0.jpg
sigma_color: 7.72211 sigma_space: 0.901059
OpenCV bilateral filter function : elapsed time 129989128
xfOpenCV bilateral filter function : elapsed time 1686544070
Minimum error in intensity = 0
Maximum error in intensity = 1
Percentage of pixels above error threshold = 0.00163966 Count: 34

I verified those data motion report are the same.

Why is it so different ?

0 Kudos
1 Solution

Accepted Solutions
skalicky
Explorer
Explorer
1,492 Views
Registered: ‎09-19-2017

 

Hi Yamashita-san,

When using estimate performance, SDSoC inserts a lot additional code to measure the application's performance. For example lets say your application is like:

 

int main() {
...other code... //part A foo(A); //part B ...more code... //part C return 0; }

and if you mark function foo() for acceleration and estimate performance, then SDSoC will insert instrumentation to measure the "...other code..." run time, foo() run time, and the "...more code..." run time. Then it will give you an overall report that estimates the benefit you might get by accelerating foo() in hardware. It creates this estimation by computing:

 

other = part A + part C

acc = SW-->HW transfers + acc run time + HW-->SW transfers

total = other + acc

 

So when you run the application produced by "estimate performance" it will run slower because of this instrumentation. But the point of estimate performance is not that it "compiles your application better/faster", its that it creates that report estimating how much performance you might expect IF YOU DID accelerate that function.

 

The expectation is that you run estimate performance to get the report. Then decide whether to accelerate the function and implement the design (which takes longer). Estimation is quick.

 

Sam

View solution in original post

2 Replies
skalicky
Explorer
Explorer
1,493 Views
Registered: ‎09-19-2017

 

Hi Yamashita-san,

When using estimate performance, SDSoC inserts a lot additional code to measure the application's performance. For example lets say your application is like:

 

int main() {
...other code... //part A foo(A); //part B ...more code... //part C return 0; }

and if you mark function foo() for acceleration and estimate performance, then SDSoC will insert instrumentation to measure the "...other code..." run time, foo() run time, and the "...more code..." run time. Then it will give you an overall report that estimates the benefit you might get by accelerating foo() in hardware. It creates this estimation by computing:

 

other = part A + part C

acc = SW-->HW transfers + acc run time + HW-->SW transfers

total = other + acc

 

So when you run the application produced by "estimate performance" it will run slower because of this instrumentation. But the point of estimate performance is not that it "compiles your application better/faster", its that it creates that report estimating how much performance you might expect IF YOU DID accelerate that function.

 

The expectation is that you run estimate performance to get the report. Then decide whether to accelerate the function and implement the design (which takes longer). Estimation is quick.

 

Sam

View solution in original post

tetsuo_yamashita
Participant
Participant
1,012 Views
Registered: ‎08-03-2017

Hi @skalicky,

 

I misunderstood that the project had to be build to run early for performance estimation.

Your explanation really helped.

Thank you so much!

0 Kudos