File: bug2793

package info (click to toggle)
oce 0.18.3-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 301,548 kB
  • sloc: cpp: 1,190,609; ansic: 67,225; sh: 11,630; tcl: 7,954; cs: 5,221; python: 2,867; java: 1,522; makefile: 342; xml: 292; perl: 37
file content (62 lines) | stat: -rw-r--r-- 1,659 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
puts "=========="
puts "OCC2793"
puts "=========="
puts ""
########################################################################
# BinOcaf: low performance saving documents with large attributes
########################################################################

NewDocument D MDTV-Standard

# Loaded shapes for attributes
restore [locate_data_file Radhaus.brep] shape1
restore [locate_data_file shading_wrongshape_009.brep] shape2
restore [locate_data_file FORM-11.brep] shape3
restore [locate_data_file OCC22759-weldt6.brep] shape4
restore [locate_data_file BPLSEITRE.brep] shape5
restore [locate_data_file OCC22302.brep] shape6
restore [locate_data_file ROVER.brep] shape7
restore [locate_data_file bug24083_polyline.brep] shape8

# Create a label
set lab1 [Label D 0:2]
set lab2 [Label D 0:3]
set lab3 [Label D 0:4]
set lab4 [Label D 0:5]
set lab5 [Label D 0:6]
set lab6 [Label D 0:7]
set lab7 [Label D 0:8]
set lab8 [Label D 0:9]

# Load shapes on labels
NewShape D ${lab1} shape1
NewShape D ${lab2} shape2
NewShape D ${lab3} shape3
NewShape D ${lab4} shape4
NewShape D ${lab5} shape5
NewShape D ${lab6} shape6
NewShape D ${lab7} shape7
NewShape D ${lab8} shape8

# Save document
file delete -force ${imagedir}/2793.cbf
dchrono h reset
dchrono h start
SaveAs D ${imagedir}/2793.cbf
dchrono h stop
Close D

# Check
set info [dchrono h show]
regexp {CPU user time: ([-0-9.+eE]+) seconds} $info full cpu_time

set max_time 100
if { [regexp {Debug mode} [dversion]] } {
   set max_time 200
}

if { $cpu_time > ${max_time} } {
    puts "Error: performance saving document D is too low"
} else {
    puts "OK: performance saving document D is high"
}