6fb3418e |
1 | puts "========" |
2 | puts "OCC25413" |
3 | puts "========" |
4 | puts "" |
5 | ############################################################# |
6 | # Line-Shape intersection algorithm became 400 times slower |
7 | ############################################################# |
8 | |
9 | pload QAcommands |
10 | |
11 | restore [locate_data_file bug25413.brep] w |
12 | |
13 | dchrono perf_h reset |
14 | dchrono perf_h start |
15 | OCC25413 w |
16 | dchrono perf_h stop |
17 | |
18 | set chrono_info [dchrono perf_h show] |
19 | |
20 | regexp {CPU user time: ([-0-9.+eE]+) seconds} $chrono_info full CPU_time |
21 | puts "Elapsed time is: $CPU_time" |
22 | |
23 | set currentOS $tcl_platform(os) |
24 | if {[string compare $currentOS "Windows NT"] == 0} { |
25 | if {[regexp {Debug mode} [dversion]]} { |
26 | # initial CPU_time for WINDOWS in DEBUG mode is 90 sec |
27 | puts "Checking WINDOWS performance in debug mode..." |
28 | if {$CPU_time > 90.} { |
29 | puts "ERROR: OCC25413 is reproduced." |
30 | puts " Low performance: $CPU_time (but should be less than 90 sec)" |
31 | } else { |
32 | puts "Done!" |
33 | } |
34 | } else { |
35 | puts "Checking WINDOWS performance in optimize mode..." |
36 | # initial CPU_time for WINDOWS in OPTIMIZE mode is 30 sec |
37 | if {$CPU_time > 30.} { |
38 | puts "ERROR: OCC25413 is reproduced." |
39 | puts " Low performance: $CPU_time (but should be less than 30 sec)" |
40 | } else { |
41 | puts "Done!" |
42 | } |
43 | } |
44 | } |
45 | if {[string compare $currentOS "Linux"] == 0} { |
46 | if {[regexp {Debug mode} [dversion]]} { |
47 | # initial CPU_time for LINUX in DEBUG mode is 90 sec |
48 | puts "Checking LINUX performance in debug mode..." |
49 | if {$CPU_time > 90.} { |
50 | puts "ERROR: OCC25413 is reproduced." |
51 | puts " Low performance: $CPU_time (but should be less than 90 sec)" |
52 | } else { |
53 | puts "Done!" |
54 | } |
55 | } else { |
56 | puts "Checking LINUX performance in optimize mode..." |
57 | # initial CPU_time for LINUX in OPTIMIZE mode is 30 sec |
58 | if {$CPU_time > 30.} { |
59 | puts "ERROR: OCC25413 is reproduced." |
60 | puts " Low performance: $CPU_time (but should be less than 30 sec)" |
61 | } else { |
62 | puts "Done!" |
63 | } |
64 | } |
65 | } |