1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-14 13:30:48 +03:00

Compare commits

..

1 Commits

Author SHA1 Message Date
oan
c62618cd60 0023581: [Regression] Performance of BRepMesh 6.5.4 can be up to Nx worse than 6.3.1
Added test case.
2019-03-12 16:59:31 +03:00
16 changed files with 335 additions and 270 deletions

View File

@@ -155,7 +155,7 @@ FEmTool_ProfileMatrix::FEmTool_ProfileMatrix(const TColStd_Array1OfInteger& Firs
Standard_Real * x = &X(X.Lower());
x--;
const Standard_Real * b = &B(B.Lower());
Standard_Real * b = &B(B.Lower());
b--;
const Standard_Real * SMA = &SMatrix->Value(1);
SMA --;
@@ -207,7 +207,7 @@ FEmTool_ProfileMatrix::FEmTool_ProfileMatrix(const TColStd_Array1OfInteger& Firs
Standard_Integer i, j, jj, DiagAddr, CurrAddr;
Standard_Real * m = &MX(MX.Lower());
m--;
const Standard_Real * x = &X(X.Lower());
Standard_Real * x = &X(X.Lower());
x--;
const Standard_Real * PM = &ProfileMatrix->Value(1);
PM--;

View File

@@ -1381,7 +1381,7 @@ void GeomFill_LocationGuide::Resolution (const Standard_Integer ,
//Function : InitX
//Purpose : recherche par interpolation d'une valeur initiale
//==================================================================
void GeomFill_LocationGuide::InitX(const Standard_Real Param)
void GeomFill_LocationGuide::InitX(const Standard_Real Param) const
{
Standard_Integer Ideb = 1, Ifin = myPoles2d->RowLength(), Idemi;

View File

@@ -186,7 +186,7 @@ private:
Standard_EXPORT void SetRotation (const Standard_Real PrecAngle, Standard_Real& LastAngle);
Standard_EXPORT void InitX (const Standard_Real Param);
Standard_EXPORT void InitX (const Standard_Real Param) const;
Handle(GeomFill_TrihedronWithGuide) myLaw;
Handle(GeomFill_SectionLaw) mySec;

View File

@@ -59,32 +59,6 @@ public:
return myPtr;
}
//! Move assignment.
//! This array will borrow all the data from theOther.
NCollection_LocalArray& Move (NCollection_LocalArray& theOther)
{
if (&theOther == this)
{
return *this;
}
Deallocate();
mySize = theOther.mySize;
if (theOther.myPtr == theOther.myBuffer)
{
// deep copy
myPtr = myBuffer;
memcpy (myPtr, theOther.myPtr, sizeof(theItem) * theOther.mySize);
memset (theOther.myPtr, 0, sizeof(theItem) * theOther.mySize);
}
else
{
myPtr = theOther.myPtr;
theOther.myPtr = theOther.myBuffer;
}
return *this;
}
private:
NCollection_LocalArray (const NCollection_LocalArray& );

View File

@@ -112,6 +112,7 @@ math_PSOParticlesPool.cxx
math_PSOParticlesPool.hxx
math_Recipes.cxx
math_Recipes.hxx
math_SingleTab.hxx
math_SingularMatrix.hxx
math_Status.hxx
math_SVD.cxx

View File

@@ -12,31 +12,40 @@
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
#include <math_IntegerVector.hxx>
#include <Standard_DimensionError.hxx>
#include <Standard_RangeError.hxx>
math_IntegerVector::math_IntegerVector(const Standard_Integer theFirst, const Standard_Integer theLast)
: myLocArray (theLast - theFirst + 1),
Array (myLocArray[0], theFirst, theLast)
math_IntegerVector::math_IntegerVector(const Standard_Integer theFirst, const Standard_Integer theLast) :
FirstIndex(theFirst),
LastIndex(theLast),
Array(theFirst, theLast)
{
//
Standard_RangeError_Raise_if(theFirst > theLast, " ");
}
math_IntegerVector::math_IntegerVector(const Standard_Integer theFirst,
const Standard_Integer theLast,
const Standard_Integer theInitialValue)
: myLocArray (theLast - theFirst + 1),
Array (myLocArray[0], theFirst, theLast)
const Standard_Integer theInitialValue) :
FirstIndex(theFirst),
LastIndex(theLast),
Array(theFirst, theLast)
{
Standard_RangeError_Raise_if(theFirst > theLast, " ");
Array.Init(theInitialValue);
}
math_IntegerVector::math_IntegerVector(const Standard_Integer* theTab,
math_IntegerVector::math_IntegerVector(const Standard_Address theTab,
const Standard_Integer theFirst,
const Standard_Integer theLast)
: Array (*theTab, theFirst, theLast)
const Standard_Integer theLast) :
FirstIndex(theFirst),
LastIndex(theLast),
Array(theTab, theFirst, theLast)
{
Standard_RangeError_Raise_if(theFirst > theLast, " ");
}
@@ -46,22 +55,24 @@ void math_IntegerVector::Init(const Standard_Integer theInitialValue)
Array.Init(theInitialValue);
}
math_IntegerVector::math_IntegerVector (const math_IntegerVector& theOther)
: myLocArray (theOther.Length()),
Array (myLocArray[0], theOther.Lower(), theOther.Upper())
math_IntegerVector::math_IntegerVector(const math_IntegerVector& theOther) :
FirstIndex(theOther.FirstIndex),
LastIndex(theOther.LastIndex),
Array(theOther.Array)
{
memcpy (&myLocArray[0], &theOther.Array.First(), sizeof(Standard_Integer) * theOther.Length());
}
void math_IntegerVector::SetFirst(const Standard_Integer theFirst)
{
Array.Resize (theFirst, Array.Upper() - Array.Lower() + theFirst, Standard_False);
Array.SetLower(theFirst);
LastIndex = LastIndex - FirstIndex + theFirst;
FirstIndex = theFirst;
}
Standard_Real math_IntegerVector::Norm() const
{
Standard_Real Result = 0;
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Result = Result + Array(Index) * Array(Index);
}
@@ -71,7 +82,7 @@ Standard_Real math_IntegerVector::Norm() const
Standard_Real math_IntegerVector::Norm2() const
{
Standard_Real Result = 0;
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Result = Result + Array(Index) * Array(Index);
}
@@ -82,7 +93,7 @@ Standard_Integer math_IntegerVector::Max() const
{
Standard_Integer I=0;
Standard_Real X = RealFirst();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
if(Array(Index) > X)
{
@@ -97,7 +108,7 @@ Standard_Integer math_IntegerVector::Min() const
{
Standard_Integer I=0;
Standard_Real X = RealLast();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
if(Array(Index) < X)
{
@@ -113,9 +124,9 @@ void math_IntegerVector::Invert()
Standard_Integer J;
Standard_Integer Temp;
for(Standard_Integer Index = Lower(); Index <= Lower() + Length() / 2 ; Index++)
for(Standard_Integer Index = FirstIndex; Index <= FirstIndex + Length() / 2 ; Index++)
{
J = Upper() + Lower() - Index;
J = LastIndex + FirstIndex - Index;
Temp = Array(Index);
Array(Index) = Array(J);
Array(J) = Temp;
@@ -133,7 +144,7 @@ void math_IntegerVector::Set(const Standard_Integer theI1,
const Standard_Integer theI2,
const math_IntegerVector &theV)
{
Standard_DimensionError_Raise_if((theI1 < Lower()) || (theI2 > Upper()) ||
Standard_DimensionError_Raise_if((theI1 < FirstIndex) || (theI2 > LastIndex) ||
(theI1 > theI2) || (theI2 - theI1 + 1 != theV.Length()), " ");
Standard_Integer I = theV.Lower();
@@ -146,7 +157,7 @@ void math_IntegerVector::Set(const Standard_Integer theI1,
void math_IntegerVector::Multiply(const Standard_Integer theRight)
{
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Array(Index) = Array(Index) * theRight;
}
@@ -156,8 +167,8 @@ void math_IntegerVector::Add(const math_IntegerVector& theRight)
{
Standard_DimensionError_Raise_if(Length() != theRight.Length(), " ");
Standard_Integer I = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theRight.FirstIndex;
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Array(Index) = Array(Index) + theRight.Array(I);
I++;
@@ -167,8 +178,8 @@ void math_IntegerVector::Add(const math_IntegerVector& theRight)
void math_IntegerVector::Subtract(const math_IntegerVector& theRight)
{
Standard_DimensionError_Raise_if(Length() != theRight.Length(), " ");
Standard_Integer I = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theRight.FirstIndex;
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Array(Index) = Array(Index) - theRight.Array(I);
I++;
@@ -178,8 +189,8 @@ void math_IntegerVector::Subtract(const math_IntegerVector& theRight)
math_IntegerVector math_IntegerVector::Slice(const Standard_Integer theI1,
const Standard_Integer theI2) const
{
Standard_DimensionError_Raise_if((theI1 < Lower()) || (theI1 > Upper()) ||
(theI2 < Lower()) || (theI2 > Upper()), " ");
Standard_DimensionError_Raise_if((theI1 < FirstIndex) || (theI1 > LastIndex) ||
(theI2 < FirstIndex) || (theI2 > LastIndex), " ");
if(theI2 >= theI1)
{
@@ -207,7 +218,7 @@ Standard_Integer math_IntegerVector::Multiplied (const math_IntegerVector& theRi
Standard_DimensionError_Raise_if(Length() != theRight.Length(), " ");
Standard_Integer I = theRight.Lower();
Standard_Integer I = theRight.FirstIndex;
for(Standard_Integer Index = 0; Index < Length(); Index++)
{
Result = Result + Array(Index) * theRight.Array(I);
@@ -218,9 +229,9 @@ Standard_Integer math_IntegerVector::Multiplied (const math_IntegerVector& theRi
math_IntegerVector math_IntegerVector::Multiplied (const Standard_Integer theRight)const
{
math_IntegerVector Result(Lower(), Upper());
math_IntegerVector Result(FirstIndex, LastIndex);
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Result.Array(Index) = Array(Index) * theRight;
}
@@ -229,9 +240,9 @@ math_IntegerVector math_IntegerVector::Multiplied (const Standard_Integer theRig
math_IntegerVector math_IntegerVector::TMultiplied (const Standard_Integer theRight) const
{
math_IntegerVector Result(Lower(), Upper());
math_IntegerVector Result(FirstIndex, LastIndex);
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Result.Array(Index) = Array(Index) * theRight;
}
@@ -242,10 +253,10 @@ math_IntegerVector math_IntegerVector::Added (const math_IntegerVector& theRight
{
Standard_DimensionError_Raise_if(Length() != theRight.Length(), " ");
math_IntegerVector Result(Lower(), Upper());
math_IntegerVector Result(FirstIndex, LastIndex);
Standard_Integer I = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theRight.FirstIndex;
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Result.Array(Index) = Array(Index) + theRight.Array(I);
I++;
@@ -255,9 +266,9 @@ math_IntegerVector math_IntegerVector::Added (const math_IntegerVector& theRight
math_IntegerVector math_IntegerVector::Opposite()
{
math_IntegerVector Result(Lower(), Upper());
math_IntegerVector Result(FirstIndex, LastIndex);
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Result.Array(Index) = - Array(Index);
}
@@ -268,10 +279,10 @@ math_IntegerVector math_IntegerVector::Subtracted (const math_IntegerVector& the
{
Standard_DimensionError_Raise_if(Length() != theRight.Length(), " ");
math_IntegerVector Result(Lower(), Upper());
math_IntegerVector Result(FirstIndex, LastIndex);
Standard_Integer I = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theRight.FirstIndex;
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Result.Array(Index) = Array(Index) - theRight.Array(I);
I++;
@@ -284,9 +295,9 @@ void math_IntegerVector::Add (const math_IntegerVector& theLeft, const math_Inte
Standard_DimensionError_Raise_if((Length() != theRight.Length()) ||
(theRight.Length() != theLeft.Length()), " ");
Standard_Integer I = theLeft.Lower();
Standard_Integer J = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theLeft.FirstIndex;
Standard_Integer J = theRight.FirstIndex;
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Array(Index) = theLeft.Array(I) + theRight.Array(J);
I++;
@@ -300,9 +311,9 @@ void math_IntegerVector::Subtract (const math_IntegerVector& theLeft,
Standard_DimensionError_Raise_if((Length() != theRight.Length()) ||
(theRight.Length() != theLeft.Length()), " ");
Standard_Integer I = theLeft.Lower();
Standard_Integer J = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theLeft.FirstIndex;
Standard_Integer J = theRight.FirstIndex;
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
Array(Index) = theLeft.Array(I) - theRight.Array(J);
I++;
@@ -313,7 +324,7 @@ void math_IntegerVector::Subtract (const math_IntegerVector& theLeft,
void math_IntegerVector::Multiply(const Standard_Integer theLeft, const math_IntegerVector& theRight)
{
Standard_DimensionError_Raise_if((Length() != theRight.Length()), " ");
for(Standard_Integer I = Lower(); I <= Upper(); I++)
for(Standard_Integer I = FirstIndex; I <= LastIndex; I++)
{
Array(I) = theLeft * theRight.Array(I);
}
@@ -322,15 +333,17 @@ void math_IntegerVector::Multiply(const Standard_Integer theLeft, const math_Int
math_IntegerVector& math_IntegerVector::Initialized(const math_IntegerVector& theOther)
{
Standard_DimensionError_Raise_if(Length() != theOther.Length(), " ");
memmove (&Array.ChangeFirst(), &theOther.Array.First(), sizeof(Standard_Integer) * Array.Length());
(theOther.Array).Copy(Array);
return *this;
}
void math_IntegerVector::Dump(Standard_OStream& theO) const
{
theO << "math_IntegerVector of Range = " << Length() << "\n";
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = FirstIndex; Index <= LastIndex; Index++)
{
theO << "math_IntegerVector(" << Index << ") = " << Array(Index) << "\n";
}
}

View File

@@ -15,8 +15,7 @@
#ifndef _math_IntegerVector_HeaderFile
#define _math_IntegerVector_HeaderFile
#include <NCollection_Array1.hxx>
#include <NCollection_LocalArray.hxx>
#include <math_SingleTab.hxx>
// resolve name collisions with X11 headers
#ifdef Opposite
@@ -71,7 +70,7 @@ public:
//! constructs an IntegerVector in the range [Lower..Upper]
//! which share the "c array" theTab.
Standard_EXPORT math_IntegerVector(const Standard_Integer* theTab, const Standard_Integer theFirst, const Standard_Integer theLast);
Standard_EXPORT math_IntegerVector(const Standard_Address theTab, const Standard_Integer theFirst, const Standard_Integer theLast);
//! constructs a copy for initialization.
//! An exception is raised if the lengths of the IntegerVectors
@@ -81,19 +80,19 @@ public:
//! returns the length of an IntegerVector
inline Standard_Integer Length() const
{
return Array.Length();
return LastIndex - FirstIndex +1;
}
//! returns the value of the Lower index of an IntegerVector.
inline Standard_Integer Lower() const
{
return Array.Lower();
return FirstIndex;
}
//! returns the value of the Upper index of an IntegerVector.
inline Standard_Integer Upper() const
{
return Array.Upper();
return LastIndex;
}
//! returns the value of the norm of an IntegerVector.
@@ -177,24 +176,14 @@ public:
//! An exception is raised if the IntegerVectors have not the same length.
Standard_EXPORT void Subtract(const math_IntegerVector& theLeft, const math_IntegerVector& theRight);
//! accesses the value of index theNum of an IntegerVector.
const Standard_Integer& Value (const Standard_Integer theNum) const
{
return Array(theNum);
}
//! accesses (in read or write mode) the value of index theNum of an IntegerVector.
inline Standard_Integer& Value (const Standard_Integer theNum)
inline Standard_Integer& Value(const Standard_Integer theNum) const
{
Standard_RangeError_Raise_if(theNum < FirstIndex || theNum > LastIndex, " ");
return Array(theNum);
}
const Standard_Integer& operator()(const Standard_Integer theNum) const
{
return Value(theNum);
}
Standard_Integer& operator()(const Standard_Integer theNum)
Standard_Integer& operator()(const Standard_Integer theNum) const
{
return Value(theNum);
}
@@ -256,37 +245,6 @@ public:
return theO;
}
#ifndef OCCT_NO_RVALUE_REFERENCE
//! Move constructor
math_IntegerVector (math_IntegerVector&& theOther)
{
Move (theOther);
}
//! Move assignment operator; @sa Move()
math_IntegerVector& operator= (math_IntegerVector&& theOther)
{
return Move (theOther);
}
#endif
//! Move assignment.
//! This array will borrow all the data from theOther, so that theOther should not be used anymore.
math_IntegerVector& Move (math_IntegerVector& theOther)
{
if (&theOther == this)
{
return *this;
}
myLocArray.Move (theOther.myLocArray);
NCollection_Array1<Standard_Integer> aNewArray (myLocArray[0], theOther.Array.Lower(), theOther.Array.Upper());
Array.Move (aNewArray);
NCollection_Array1<Standard_Integer> anEmptyArray;
theOther.Array.Move (anEmptyArray);
return *this;
}
protected:
//! is used internally to set the Lower value of the IntegerVector.
@@ -294,9 +252,9 @@ protected:
private:
NCollection_LocalArray<Standard_Integer, 32> myLocArray;
NCollection_Array1<Standard_Integer> Array;
Standard_Integer FirstIndex;
Standard_Integer LastIndex;
math_SingleTab<Standard_Integer> Array;
};
#endif

View File

@@ -297,7 +297,7 @@ void math_Matrix::SetRow (const Standard_Integer Row,
Standard_DimensionError_Raise_if (ColNumber() != V.Length(),
"math_Matrix::SetRow() - input vector has wrong dimensions");
Standard_Integer I = V.Lower();
Standard_Integer I = V.LowerIndex;
for(Standard_Integer Index = LowerColIndex; Index <= UpperColIndex; Index++) {
Array(Row, Index) = V.Array(I);
I++;
@@ -314,7 +314,7 @@ void math_Matrix::SetCol (const Standard_Integer Col,
Standard_DimensionError_Raise_if (RowNumber() != V.Length(),
"math_Matrix::SetCol() - input vector has wrong dimensions");
Standard_Integer I = V.Lower();
Standard_Integer I = V.LowerIndex;
for(Standard_Integer Index = LowerRowIndex; Index <= UpperRowIndex; Index++) {
Array(Index, Col) = V.Array(I);
I++;
@@ -635,7 +635,7 @@ math_Vector math_Matrix::Multiplied(const math_Vector& Right)const
for(Standard_Integer I = LowerRowIndex; I <= UpperRowIndex; I++) {
Result.Array(I) = 0.0;
Standard_Integer II = Right.Lower();
Standard_Integer II = Right.LowerIndex;
for(Standard_Integer J = LowerColIndex; J <= UpperColIndex; J++) {
Result.Array(I) = Result.Array(I) + Array(I, J) * Right.Array(II);
II++;

View File

@@ -40,7 +40,7 @@ math_SVD::math_SVD (const math_Matrix& A) :
void math_SVD::Solve (const math_Vector& B,
math_Vector& X,
const Standard_Real Eps)
const Standard_Real Eps) const
{
StdFail_NotDone_Raise_if(!Done, " ");
Standard_DimensionError_Raise_if((RowA != B.Length()) ||
@@ -58,7 +58,7 @@ void math_SVD::Solve (const math_Vector& B,
}
void math_SVD::PseudoInverse (math_Matrix& Result,
const Standard_Real Eps)
const Standard_Real Eps) const
{
Standard_Integer i, j ;

View File

@@ -61,14 +61,14 @@ public:
//! equal to the rowrange of A.
//! Exception DimensionError is raised if the range of X is not
//! equal to the colrange of A.
Standard_EXPORT void Solve (const math_Vector& B, math_Vector& X, const Standard_Real Eps = 1.0e-6);
Standard_EXPORT void Solve (const math_Vector& B, math_Vector& X, const Standard_Real Eps = 1.0e-6) const;
//! Computes the inverse Inv of matrix A such as A * Inverse = Identity.
//! Exceptions
//! StdFail_NotDone if the algorithm fails (and IsDone returns false).
//! Standard_DimensionError if the ranges of Inv are
//! compatible with the ranges of A.
Standard_EXPORT void PseudoInverse (math_Matrix& Inv, const Standard_Real Eps = 1.0e-6);
Standard_EXPORT void PseudoInverse (math_Matrix& Inv, const Standard_Real Eps = 1.0e-6) const;
//! Prints information on the current state of the object.
//! Is used to redefine the operator <<.

116
src/math/math_SingleTab.hxx Normal file
View File

@@ -0,0 +1,116 @@
// Copyright (c) 1997-1999 Matra Datavision
// Copyright (c) 1999-2014 OPEN CASCADE SAS
//
// This file is part of Open CASCADE Technology software library.
//
// This library is free software; you can redistribute it and/or modify it under
// the terms of the GNU Lesser General Public License version 2.1 as published
// by the Free Software Foundation, with special exception defined in the file
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
// distribution for complete text of the license and disclaimer of any warranty.
//
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
#ifndef _math_SingleTab_HeaderFile
#define _math_SingleTab_HeaderFile
#include <Standard_OutOfRange.hxx>
#include <Standard_Failure.hxx>
#include <string.h>
static const Standard_Integer aLengthOfBuf = 512;
template<class T> class math_SingleTab
{
public:
DEFINE_STANDARD_ALLOC
math_SingleTab(const Standard_Integer LowerIndex, const Standard_Integer UpperIndex) :
Addr(Buf),
isAllocated(UpperIndex - LowerIndex + 1 > aLengthOfBuf),
First(LowerIndex), Last(UpperIndex)
{
T* TheAddr = !isAllocated? Buf :
(T*) Standard::Allocate((Last-First+1) * sizeof(T));
Addr = (Standard_Address) (TheAddr - First);
}
math_SingleTab(const Standard_Address Tab, const Standard_Integer LowerIndex, const Standard_Integer UpperIndex) :
Addr((void*)((const T*)Tab - LowerIndex)),
isAllocated(Standard_False),
First(LowerIndex), Last(UpperIndex)
{
}
void Init(const T InitValue)
{
for(Standard_Integer i = First; i<= Last; i++)
{
((T*)Addr)[i] = InitValue;
}
}
math_SingleTab(const math_SingleTab& Other) :
isAllocated(Other.Last - Other.First + 1 > aLengthOfBuf),
First(Other.First),
Last(Other.Last)
{
T* TheAddr = !isAllocated? Buf : (T*) Standard::Allocate((Last-First+1) * sizeof(T));
Addr = (Standard_Address) (TheAddr - First);
T* TheOtherAddr = (T*) Other.Addr;
memmove((void*) TheAddr, (const void*) (TheOtherAddr + First), (size_t)(Last - First + 1) * sizeof(T));
}
inline void Copy(math_SingleTab& Other) const
{
memmove((void*) (((T*)Other.Addr) + Other.First),
(const void*) (((T*)Addr) + First),
(size_t)(Last - First + 1) * sizeof(T));
}
void SetLower(const Standard_Integer LowerIndex)
{
T* TheAddr = (T*) Addr;
Addr = (Standard_Address) (TheAddr + First - LowerIndex);
Last = Last - First + LowerIndex;
First = LowerIndex;
}
inline T& Value(const Standard_Integer Index) const
{
return ((T*)Addr)[Index];
}
T& operator()(const Standard_Integer Index) const
{
return Value(Index);
}
void Free()
{
if(isAllocated)
{
Standard_Address it = (Standard_Address)&((T*)Addr)[First];
Standard::Free(it);
Addr = 0;
}
}
~math_SingleTab()
{
Free();
}
private:
Standard_Address Addr;
T Buf[aLengthOfBuf];
Standard_Boolean isAllocated;
Standard_Integer First;
Standard_Integer Last;
};
#endif

View File

@@ -22,41 +22,48 @@
#include <Standard_RangeError.hxx>
#include <Standard_NullValue.hxx>
math_Vector::math_Vector(const Standard_Integer theLower, const Standard_Integer theUpper)
: myLocArray (theUpper - theLower + 1),
Array (myLocArray[0], theLower, theUpper)
math_Vector::math_Vector(const Standard_Integer theLower, const Standard_Integer theUpper) :
LowerIndex(theLower),
UpperIndex(theUpper),
Array(theLower,theUpper)
{
//
Standard_RangeError_Raise_if (theLower > theUpper, "math_Vector() - invalid dimensions");
}
math_Vector::math_Vector(const Standard_Integer theLower,
const Standard_Integer theUpper,
const Standard_Real theInitialValue)
: myLocArray (theUpper - theLower + 1),
Array (myLocArray[0], theLower, theUpper)
const Standard_Real theInitialValue):
LowerIndex(theLower),
UpperIndex(theUpper),
Array(theLower,theUpper)
{
Standard_RangeError_Raise_if (theLower > theUpper, "math_Vector() - invalid dimensions");
Array.Init(theInitialValue);
}
math_Vector::math_Vector(const Standard_Real* theTab,
math_Vector::math_Vector(const Standard_Address theTab,
const Standard_Integer theLower,
const Standard_Integer theUpper)
: Array (*theTab, theLower, theUpper)
const Standard_Integer theUpper) :
LowerIndex(theLower),
UpperIndex(theUpper),
Array(theTab, theLower,theUpper)
{
Standard_RangeError_Raise_if ((theLower > theUpper), "math_Vector() - invalid dimensions");
}
math_Vector::math_Vector (const gp_XY& theOther)
: myLocArray (2),
Array (myLocArray[0], 1,2)
math_Vector::math_Vector(const gp_XY& theOther):
LowerIndex(1),
UpperIndex(2),
Array(1,2)
{
Array(1) = theOther.X();
Array(2) = theOther.Y();
}
math_Vector::math_Vector (const gp_XYZ& theOther)
: myLocArray (3),
Array (myLocArray[0], 1, 3)
math_Vector::math_Vector(const gp_XYZ& theOther):
LowerIndex(1),
UpperIndex(3),
Array(1, 3)
{
Array(1) = theOther.X();
Array(2) = theOther.Y();
@@ -68,23 +75,25 @@ void math_Vector::Init(const Standard_Real theInitialValue)
Array.Init(theInitialValue);
}
math_Vector::math_Vector (const math_Vector& theOther)
: myLocArray (theOther.Length()),
Array (myLocArray[0], theOther.Lower(), theOther.Upper())
math_Vector::math_Vector(const math_Vector& theOther) :
LowerIndex(theOther.LowerIndex),
UpperIndex(theOther.UpperIndex),
Array(theOther.Array)
{
memcpy (&myLocArray[0], &theOther.Array.First(), sizeof(Standard_Real) * theOther.Length());
}
void math_Vector::SetLower(const Standard_Integer theLower)
{
Array.Resize (theLower, Array.Upper() - Array.Lower() + theLower, Standard_False);
Array.SetLower(theLower);
UpperIndex = UpperIndex - LowerIndex + theLower;
LowerIndex = theLower;
}
Standard_Real math_Vector::Norm() const
{
Standard_Real Result = 0;
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Result = Result + Array(Index) * Array(Index);
}
@@ -95,7 +104,7 @@ Standard_Real math_Vector::Norm2() const
{
Standard_Real Result = 0;
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Result = Result + Array(Index) * Array(Index);
}
@@ -107,7 +116,7 @@ Standard_Integer math_Vector::Max() const
Standard_Integer I=0;
Standard_Real X = RealFirst();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
if(Array(Index) > X)
{
@@ -123,7 +132,7 @@ Standard_Integer math_Vector::Min() const
Standard_Integer I=0;
Standard_Real X = RealLast();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
if(Array(Index) < X)
{
@@ -138,7 +147,7 @@ void math_Vector::Set(const Standard_Integer theI1,
const Standard_Integer theI2,
const math_Vector &theV)
{
Standard_RangeError_Raise_if ((theI1 < Lower()) || (theI2 > Upper())
Standard_RangeError_Raise_if ((theI1 < LowerIndex) || (theI2 > UpperIndex)
|| (theI1 > theI2) || (theI2 - theI1 + 1 != theV.Length()),
"math_Vector::Set() - invalid indices");
@@ -155,7 +164,7 @@ void math_Vector::Normalize()
Standard_Real Result = Norm();
Standard_NullValue_Raise_if ((Result <= RealEpsilon()),
"math_Vector::Normalize() - vector has zero norm");
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Array(Index) = Array(Index) / Result;
}
@@ -171,12 +180,14 @@ math_Vector math_Vector::Normalized() const
void math_Vector::Invert()
{
for(Standard_Integer Index = Lower(); Index <= (Lower() + Length()) >> 1 ; Index++)
Standard_Integer J;
Standard_Real Temp;
for(Standard_Integer Index = LowerIndex; Index <= (LowerIndex + Length()) >> 1 ; Index++)
{
Standard_Integer J = Upper() + Lower() - Index;
Standard_Real aTemp = Array(Index);
J = UpperIndex + LowerIndex - Index;
Temp = Array(Index);
Array(Index) = Array(J);
Array(J) = aTemp;
Array(J) = Temp;
}
}
@@ -189,8 +200,9 @@ math_Vector math_Vector::Inverse() const
math_Vector math_Vector::Multiplied(const Standard_Real theRight) const
{
math_Vector Result (Lower(), Upper());
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
math_Vector Result (LowerIndex, UpperIndex);
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Result.Array(Index) = Array(Index) * theRight;
}
@@ -199,8 +211,9 @@ math_Vector math_Vector::Multiplied(const Standard_Real theRight) const
math_Vector math_Vector::TMultiplied(const Standard_Real theRight) const
{
math_Vector Result (Lower(), Upper());
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
math_Vector Result (LowerIndex, UpperIndex);
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Result.Array(Index) = Array(Index) * theRight;
}
@@ -209,7 +222,7 @@ math_Vector math_Vector::TMultiplied(const Standard_Real theRight) const
void math_Vector::Multiply(const Standard_Real theRight)
{
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Array(Index) = Array(Index) * theRight;
}
@@ -220,7 +233,7 @@ void math_Vector::Divide(const Standard_Real theRight)
Standard_DivideByZero_Raise_if (Abs(theRight) <= RealEpsilon(),
"math_Vector::Divide() - devisor is zero");
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index =LowerIndex; Index <=UpperIndex; Index++)
{
Array(Index) = Array(Index) / theRight;
}
@@ -239,8 +252,8 @@ void math_Vector::Add(const math_Vector& theRight)
Standard_DimensionError_Raise_if (Length() != theRight.Length(),
"math_Vector::Add() - input vector has wrong dimensions");
Standard_Integer I = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theRight.LowerIndex;
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Array(Index) = Array(Index) + theRight.Array(I);
I++;
@@ -252,10 +265,10 @@ math_Vector math_Vector::Added(const math_Vector& theRight) const
Standard_DimensionError_Raise_if (Length() != theRight.Length(),
"math_Vector::Added() - input vector has wrong dimensions");
math_Vector Result (Lower(), Upper());
math_Vector Result(LowerIndex, UpperIndex);
Standard_Integer I = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theRight.LowerIndex;
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Result.Array(Index) = Array(Index) + theRight.Array(I);
I++;
@@ -268,8 +281,8 @@ void math_Vector::Subtract(const math_Vector& theRight)
Standard_DimensionError_Raise_if (Length() != theRight.Length(),
"math_Vector::Subtract() - input vector has wrong dimensions");
Standard_Integer I = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theRight.LowerIndex;
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Array(Index) = Array(Index) - theRight.Array(I);
I++;
@@ -281,10 +294,10 @@ math_Vector math_Vector::Subtracted (const math_Vector& theRight) const
Standard_DimensionError_Raise_if (Length() != theRight.Length(),
"math_Vector::Subtracted() - input vector has wrong dimensions");
math_Vector Result(Lower(), Upper());
math_Vector Result(LowerIndex, UpperIndex);
Standard_Integer I = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theRight.LowerIndex;
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Result.Array(Index) = Array(Index) - theRight.Array(I);
I++;
@@ -294,7 +307,7 @@ math_Vector math_Vector::Subtracted (const math_Vector& theRight) const
math_Vector math_Vector::Slice(const Standard_Integer theI1, const Standard_Integer theI2) const
{
Standard_RangeError_Raise_if ((theI1 < Lower()) || (theI1 > Upper()) || (theI2 < Lower()) || (theI2 > Upper()),
Standard_RangeError_Raise_if ((theI1 < LowerIndex) || (theI1 > UpperIndex) || (theI2 < LowerIndex) || (theI2 > UpperIndex),
"math_Vector::Slice() - invalid indices");
if(theI2 >= theI1)
@@ -322,9 +335,9 @@ void math_Vector::Add (const math_Vector& theLeft, const math_Vector& theRight)
Standard_DimensionError_Raise_if ((Length() != theRight.Length()) || (theRight.Length() != theLeft.Length()),
"math_Vector::Add() - input vectors have wrong dimensions");
Standard_Integer I = theLeft.Lower();
Standard_Integer J = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theLeft.LowerIndex;
Standard_Integer J = theRight.LowerIndex;
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Array(Index) = theLeft.Array(I) + theRight.Array(J);
I++;
@@ -337,9 +350,9 @@ void math_Vector::Subtract (const math_Vector& theLeft, const math_Vector& theRi
Standard_DimensionError_Raise_if ((Length() != theRight.Length()) || (theRight.Length() != theLeft.Length()),
"math_Vector::Subtract() - input vectors have wrong dimensions");
Standard_Integer I = theLeft.Lower();
Standard_Integer J = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theLeft.LowerIndex;
Standard_Integer J = theRight.LowerIndex;
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Array(Index) = theLeft.Array(I) - theRight.Array(J);
I++;
@@ -353,11 +366,11 @@ void math_Vector::Multiply(const math_Matrix& theLeft, const math_Vector& theRig
|| (theLeft.ColNumber() != theRight.Length()),
"math_Vector::Multiply() - input matrix and/or vector have wrong dimensions");
Standard_Integer Index = Lower();
Standard_Integer Index = LowerIndex;
for(Standard_Integer I = theLeft.LowerRowIndex; I <= theLeft.UpperRowIndex; I++)
{
Array(Index) = 0.0;
Standard_Integer K = theRight.Lower();
Standard_Integer K = theRight.LowerIndex;
for(Standard_Integer J = theLeft.LowerColIndex; J <= theLeft.UpperColIndex; J++)
{
Array(Index) = Array(Index) + theLeft.Array(I, J) * theRight.Array(K);
@@ -373,11 +386,11 @@ void math_Vector::Multiply(const math_Vector& theLeft, const math_Matrix& theRig
|| (theLeft.Length() != theRight.RowNumber()),
"math_Vector::Multiply() - input matrix and/or vector have wrong dimensions");
Standard_Integer Index = Lower();
Standard_Integer Index = LowerIndex;
for(Standard_Integer J = theRight.LowerColIndex; J <= theRight.UpperColIndex; J++)
{
Array(Index) = 0.0;
Standard_Integer K = theLeft.Lower();
Standard_Integer K = theLeft.LowerIndex;
for(Standard_Integer I = theRight.LowerRowIndex; I <= theRight.UpperRowIndex; I++)
{
Array(Index) = Array(Index) + theLeft.Array(K) * theRight.Array(I, J);
@@ -393,11 +406,11 @@ void math_Vector::TMultiply(const math_Matrix& theTLeft, const math_Vector& the
|| (theTLeft.RowNumber() != theRight.Length()),
"math_Vector::TMultiply() - input matrix and/or vector have wrong dimensions");
Standard_Integer Index = Lower();
Standard_Integer Index = LowerIndex;
for(Standard_Integer I = theTLeft.LowerColIndex; I <= theTLeft.UpperColIndex; I++)
{
Array(Index) = 0.0;
Standard_Integer K = theRight.Lower();
Standard_Integer K = theRight.LowerIndex;
for(Standard_Integer J = theTLeft.LowerRowIndex; J <= theTLeft.UpperRowIndex; J++)
{
Array(Index) = Array(Index) + theTLeft.Array(J, I) * theRight.Array(K);
@@ -413,11 +426,11 @@ void math_Vector::TMultiply(const math_Vector& theLeft, const math_Matrix& theT
|| (theLeft.Length() != theTRight.ColNumber()),
"math_Vector::TMultiply() - input matrix and/or vector have wrong dimensions");
Standard_Integer Index = Lower();
Standard_Integer Index = LowerIndex;
for(Standard_Integer J = theTRight.LowerRowIndex; J <= theTRight.UpperRowIndex; J++)
{
Array(Index) = 0.0;
Standard_Integer K = theLeft.Lower();
Standard_Integer K = theLeft.LowerIndex;
for(Standard_Integer I = theTRight.LowerColIndex;
I <= theTRight.UpperColIndex; I++)
{
@@ -435,8 +448,8 @@ Standard_Real math_Vector::Multiplied(const math_Vector& theRight) const
Standard_DimensionError_Raise_if (Length() != theRight.Length(),
"math_Vector::Multiplied() - input vector has wrong dimensions");
Standard_Integer I = theRight.Lower();
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
Standard_Integer I = theRight.LowerIndex;
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Result = Result + Array(Index) * theRight.Array(I);
I++;
@@ -446,8 +459,9 @@ Standard_Real math_Vector::Multiplied(const math_Vector& theRight) const
math_Vector math_Vector::Opposite()
{
math_Vector Result(Lower(), Upper());
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
math_Vector Result(LowerIndex, UpperIndex);
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
Result.Array(Index) = - Array(Index);
}
@@ -462,13 +476,13 @@ math_Vector math_Vector::Multiplied(const math_Matrix& theRight)const
math_Vector Result(theRight.LowerColIndex, theRight.UpperColIndex);
for(Standard_Integer J2 = theRight.LowerColIndex; J2 <= theRight.UpperColIndex; J2++)
{
Result.Array(J2) = 0.0;
Standard_Integer theI2 = theRight.LowerRowIndex;
for(Standard_Integer I = Lower(); I <= Upper(); I++)
{
Result.Array(J2) = Result.Array(J2) + Array(I) * theRight.Array(theI2, J2);
theI2++;
}
Array(J2) = 0.0;
Standard_Integer theI2 = theRight.LowerRowIndex;
for(Standard_Integer I = LowerIndex; I <= UpperIndex; I++)
{
Result.Array(J2) = Result.Array(J2) + Array(I) * theRight.Array(theI2, J2);
theI2++;
}
}
return Result;
}
@@ -477,7 +491,7 @@ void math_Vector::Multiply(const Standard_Real theLeft, const math_Vector& theRi
{
Standard_DimensionError_Raise_if ((Length() != theRight.Length()),
"math_Vector::Multiply() - input vector has wrong dimensions");
for(Standard_Integer I = Lower(); I <= Upper(); I++)
for(Standard_Integer I = LowerIndex; I <= UpperIndex; I++)
{
Array(I) = theLeft * theRight.Array(I);
}
@@ -487,14 +501,15 @@ math_Vector& math_Vector::Initialized(const math_Vector& theOther)
{
Standard_DimensionError_Raise_if (Length() != theOther.Length(),
"math_Vector::Initialized() - input vector has wrong dimensions");
memmove (&Array.ChangeFirst(), &theOther.Array.First(), sizeof(Standard_Real) * Array.Length());
(theOther.Array).Copy(Array);
return *this;
}
void math_Vector::Dump(Standard_OStream& theO) const
{
theO << "math_Vector of Length = " << Length() << "\n";
for(Standard_Integer Index = Lower(); Index <= Upper(); Index++)
for(Standard_Integer Index = LowerIndex; Index <= UpperIndex; Index++)
{
theO << "math_Vector(" << Index << ") = " << Array(Index) << "\n";
}

View File

@@ -15,8 +15,7 @@
#ifndef _math_Vector_HeaderFile
#define _math_Vector_HeaderFile
#include <NCollection_Array1.hxx>
#include <NCollection_LocalArray.hxx>
#include <math_SingleTab.hxx>
#include <gp_XY.hxx>
#include <gp_XYZ.hxx>
@@ -71,7 +70,7 @@ public:
//! Constructs a vector in the range [theLower..theUpper]
//! with the "c array" theTab.
Standard_EXPORT math_Vector(const Standard_Real* theTab, const Standard_Integer theLower, const Standard_Integer theUpper);
Standard_EXPORT math_Vector(const Standard_Address theTab, const Standard_Integer theLower, const Standard_Integer theUpper);
//! Constructor for converting gp_XY to math_Vector
Standard_EXPORT math_Vector(const gp_XY& Other);
@@ -89,19 +88,19 @@ public:
//! Returns the length of a vector
inline Standard_Integer Length() const
{
return Array.Length();
return UpperIndex - LowerIndex +1;
}
//! Returns the value of the theLower index of a vector.
inline Standard_Integer Lower() const
{
return Array.Lower();
return LowerIndex;
}
//! Returns the value of the theUpper index of a vector.
inline Standard_Integer Upper() const
{
return Array.Upper();
return UpperIndex;
}
//! Returns the value or the square of the norm of this vector.
@@ -242,24 +241,14 @@ public:
//! Subtract whenever possible.
Standard_EXPORT void Subtract(const math_Vector& theLeft,const math_Vector& theRight);
//! accesses the value of index "theNum" of a vector.
const Standard_Real& Value (const Standard_Integer theNum) const
{
return Array(theNum);
}
//! accesses (in read or write mode) the value of index "theNum" of a vector.
inline Standard_Real& Value (const Standard_Integer theNum)
inline Standard_Real& Value(const Standard_Integer theNum) const
{
Standard_RangeError_Raise_if(theNum < LowerIndex || theNum > UpperIndex, " ");
return Array(theNum);
}
const Standard_Real& operator()(const Standard_Integer theNum) const
{
return Value(theNum);
}
Standard_Real& operator()(const Standard_Integer theNum)
Standard_Real& operator()(const Standard_Integer theNum) const
{
return Value(theNum);
}
@@ -331,37 +320,6 @@ public:
friend class math_Matrix;
#ifndef OCCT_NO_RVALUE_REFERENCE
//! Move constructor
math_Vector (math_Vector&& theOther)
{
Move (theOther);
}
//! Move assignment operator; @sa Move()
math_Vector& operator= (math_Vector&& theOther)
{
return Move (theOther);
}
#endif
//! Move assignment.
//! This array will borrow all the data from theOther, so that theOther should not be used anymore.
math_Vector& Move (math_Vector& theOther)
{
if (&theOther == this)
{
return *this;
}
myLocArray.Move (theOther.myLocArray);
NCollection_Array1<Standard_Real> aNewArray (myLocArray[0], theOther.Array.Lower(), theOther.Array.Upper());
Array.Move (aNewArray);
NCollection_Array1<Standard_Real> anEmptyArray;
theOther.Array.Move (anEmptyArray);
return *this;
}
protected:
//! Is used internally to set the "theLower" value of the vector.
@@ -369,9 +327,9 @@ protected:
private:
NCollection_LocalArray<Standard_Real, 32> myLocArray;
NCollection_Array1<Standard_Real> Array;
Standard_Integer LowerIndex;
Standard_Integer UpperIndex;
math_SingleTab<Standard_Real> Array;
};
#endif

View File

@@ -0,0 +1,10 @@
puts "======="
puts "0023581: \[Regression\] Performance of BRepMesh 6.5.4 can be up to Nx worse than 6.3.1"
puts "======="
puts ""
restore [locate_data_file f1.brep] result
tclean result
incmesh result 15
checktrinfo result -tri 17682 -nod 16483

View File

@@ -0,0 +1,10 @@
puts "======="
puts "0023581: \[Regression\] Performance of BRepMesh 6.5.4 can be up to Nx worse than 6.3.1"
puts "======="
puts ""
restore [locate_data_file shaver.brep] result
tclean result
incmesh result 0.68
checktrinfo result -tri 21870 -nod 23655

View File

@@ -0,0 +1,10 @@
puts "======="
puts "0023581: \[Regression\] Performance of BRepMesh 6.5.4 can be up to Nx worse than 6.3.1"
puts "======="
puts ""
restore [locate_data_file cylinder_head.brep] result
tclean result
incmesh result 0.74
checktrinfo result -tri 39342 -nod 31984