Nokia Interview Test + exception constructor
This commit is contained in:
239
NokiaInterviewTest.cpp
Normal file
239
NokiaInterviewTest.cpp
Normal file
@@ -0,0 +1,239 @@
|
|||||||
|
/* Check cf5-opt.vim defs.
|
||||||
|
VIM: let g:lcppflags="-std=c++11 -O2 -pthread"
|
||||||
|
VIM: let g:wcppflags="/O2 /EHsc /DWIN32"
|
||||||
|
VIM: let g:argv=""
|
||||||
|
*/
|
||||||
|
#include <iostream>
|
||||||
|
#include <exception>
|
||||||
|
#include <vector>
|
||||||
|
#include <algorithm>
|
||||||
|
#include <string>
|
||||||
|
|
||||||
|
int testinput[] = {
|
||||||
|
1,0,0,0,1,0,0,0,0
|
||||||
|
};
|
||||||
|
|
||||||
|
// find bug.
|
||||||
|
int solution3(std::vector<int>& A) {
|
||||||
|
int n = A.size();
|
||||||
|
int i = n - 1;
|
||||||
|
int result = -1;
|
||||||
|
int k = 0;
|
||||||
|
int maximal = 0;
|
||||||
|
while (i > 0)
|
||||||
|
{
|
||||||
|
if (A[i] == 1)
|
||||||
|
{
|
||||||
|
k = k + 1;
|
||||||
|
if (k >= maximal)
|
||||||
|
{
|
||||||
|
maximal = k;
|
||||||
|
result = i;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
k = 0;
|
||||||
|
}
|
||||||
|
i = i - 1;
|
||||||
|
}
|
||||||
|
if (A[i] == 1 && k + 1 > maximal) // <- bug is here. there should be k+1 >= maximal
|
||||||
|
result = 0;
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
const char * a1 = "abc";
|
||||||
|
const char * a2 = "Abc";
|
||||||
|
|
||||||
|
int solution4(const std::string & s1, const std::string & s2)
|
||||||
|
{
|
||||||
|
std::string::const_iterator s1it = s1.begin();
|
||||||
|
std::string::const_iterator s1et = s1.end();
|
||||||
|
std::string::const_iterator s2it = s2.begin();
|
||||||
|
std::string::const_iterator s2et = s2.end();
|
||||||
|
for ( ; s1it!=s1et && s2it!=s2et; ++s1it, ++s2it )
|
||||||
|
{
|
||||||
|
char c1 = toupper(*s1it);
|
||||||
|
char c2 = toupper(*s2it);
|
||||||
|
if ( c1 < c2 )
|
||||||
|
return -1;
|
||||||
|
else if ( c2 < c1 )
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ( s1it==s1et && s2it==s2et )
|
||||||
|
return 0;
|
||||||
|
else if ( s1it==s1et )
|
||||||
|
return -1;
|
||||||
|
else
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
int solution2(int blx1, int bly1, int trx1, int try1, int blx2, int bly2, int trx2, int try2)
|
||||||
|
{
|
||||||
|
if ( blx1 > trx1 )
|
||||||
|
std::swap( blx1, trx1 );
|
||||||
|
if ( bly1 > try1 )
|
||||||
|
std::swap( bly1, try1 );
|
||||||
|
if ( blx2 > trx2 )
|
||||||
|
std::swap( blx2, trx2 );
|
||||||
|
if ( bly2 > try2 )
|
||||||
|
std::swap( bly2, try2 );
|
||||||
|
|
||||||
|
if ( trx1 < blx2
|
||||||
|
|| trx2 < blx1
|
||||||
|
|| try1 < bly2
|
||||||
|
|| try2 < bly1 )
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
long long x[4] = { blx1,trx1,blx2,trx2 };
|
||||||
|
std::sort( &x[0], &x[4]);
|
||||||
|
|
||||||
|
long long y[4] = { bly1,try1,bly2,try2 };
|
||||||
|
std::sort( &y[0], &y[4]);
|
||||||
|
|
||||||
|
unsigned long long a = (unsigned long long)(x[2]-x[1])*(unsigned long long)(y[2]-y[1]);
|
||||||
|
return ( a <= 2147483647 ) ? (int)a : -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
int solution1( std::vector<int> & a )
|
||||||
|
{
|
||||||
|
typedef std::vector<int> v_t;
|
||||||
|
|
||||||
|
std::sort(a.begin(),a.end());
|
||||||
|
|
||||||
|
long long s = 0;
|
||||||
|
|
||||||
|
v_t::const_iterator it=a.begin();
|
||||||
|
v_t::const_iterator et=a.end();
|
||||||
|
v_t::const_iterator jt;
|
||||||
|
for ( jt = it; it != et && *it == *jt; ++it );
|
||||||
|
long long ic = it - jt;
|
||||||
|
s += ic*(ic-1)/2;
|
||||||
|
|
||||||
|
for ( ; it != et; )
|
||||||
|
{
|
||||||
|
for ( jt = it; it != et && *it == *jt; ++it );
|
||||||
|
long long pc = ic;
|
||||||
|
ic = it - jt;
|
||||||
|
s += ic*(ic-1)/2;
|
||||||
|
s += ic*pc;
|
||||||
|
}
|
||||||
|
|
||||||
|
const long long lim = 100000000;
|
||||||
|
return ( s <= lim ) ? s : -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// you can also use includes, for example:
|
||||||
|
int solution_demo1( std::vector<int> & a )
|
||||||
|
{
|
||||||
|
if ( !a.size() )
|
||||||
|
return -1;
|
||||||
|
|
||||||
|
typedef std::vector<int>::const_iterator iterator;
|
||||||
|
typedef std::vector<long long> ub_t;
|
||||||
|
|
||||||
|
int s = 0;
|
||||||
|
ub_t ub;
|
||||||
|
for ( iterator it=a.begin(), ib=a.begin(), ie=a.end();
|
||||||
|
it!=ie; ++it )
|
||||||
|
{
|
||||||
|
int c = it-ib;
|
||||||
|
long long l = c-*it;
|
||||||
|
long long r = c+*it;
|
||||||
|
|
||||||
|
ub_t::iterator jt = std::lower_bound( ub.begin(), ub.end(), l);
|
||||||
|
s += ub.end()-jt;
|
||||||
|
if ( s > 10000000 )
|
||||||
|
return -1;
|
||||||
|
|
||||||
|
jt = std::upper_bound( ub.begin(), ub.end(), r);
|
||||||
|
ub.insert(jt, r);
|
||||||
|
}
|
||||||
|
return s;
|
||||||
|
}
|
||||||
|
|
||||||
|
// you can also use includes, for example:
|
||||||
|
int solution_demo2( const std::vector<int> & a )
|
||||||
|
{
|
||||||
|
typedef std::vector<int>::const_iterator iterator;
|
||||||
|
//
|
||||||
|
// There is no solution if array 'a' has no elements. However,
|
||||||
|
// per task condition 'a' is non-empty. So, I don't consider that
|
||||||
|
// case.
|
||||||
|
//
|
||||||
|
std::vector<bool> m( a.size(), false );
|
||||||
|
//
|
||||||
|
// This is the index.
|
||||||
|
//
|
||||||
|
int cvrp = 0;
|
||||||
|
//
|
||||||
|
// Iterate over array and find the index that inserts
|
||||||
|
// element into m. That will be wanted index.
|
||||||
|
//
|
||||||
|
for ( iterator it=a.begin(), ib=a.begin(), ie=a.end();
|
||||||
|
it!=ie; ++it )
|
||||||
|
{
|
||||||
|
if ( !m[*it] )
|
||||||
|
{
|
||||||
|
m[*it]=true;
|
||||||
|
cvrp = it - ib;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//
|
||||||
|
// Make it index.
|
||||||
|
//
|
||||||
|
return cvrp;
|
||||||
|
}
|
||||||
|
|
||||||
|
int main ( void )
|
||||||
|
{try{
|
||||||
|
|
||||||
|
|
||||||
|
// std::cout << solution( 0,0,2,2, 1,1,3,3 ) << std::endl;
|
||||||
|
// std::cout << solution( -2147483648,-2147483648,2147483647,2147483647, -2147483640,-2147483640,2147483640,2147483640 ) << std::endl;
|
||||||
|
|
||||||
|
|
||||||
|
// std::cout << solution( std::string(a1), std::string(a2) ) << std::endl;
|
||||||
|
|
||||||
|
#if 1
|
||||||
|
int cnt = sizeof(testinput)/sizeof(testinput[0]);
|
||||||
|
std::vector<int> a;
|
||||||
|
//std::cout << solution( a ) << std::endl;
|
||||||
|
|
||||||
|
a.reserve(cnt);
|
||||||
|
for ( int i = 0; i < cnt; ++i )
|
||||||
|
a.push_back(testinput[i]);
|
||||||
|
std::cout << solution3( a ) << std::endl;
|
||||||
|
|
||||||
|
/*
|
||||||
|
{
|
||||||
|
std::vector<int> b(100000,1);
|
||||||
|
std::cout << solution( b ) << std::endl;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
std::vector<int> b(10000,1);
|
||||||
|
std::cout << solution( b ) << std::endl;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
std::vector<int> b(1000,1);
|
||||||
|
std::cout << solution( b ) << std::endl;
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
catch ( const std::exception& e )
|
||||||
|
{
|
||||||
|
std::cerr << std::endl
|
||||||
|
<< "std::exception(\"" << e.what() << "\")." << std::endl;
|
||||||
|
return 2;
|
||||||
|
}
|
||||||
|
catch ( ... )
|
||||||
|
{
|
||||||
|
std::cerr << std::endl
|
||||||
|
<< "unknown exception." << std::endl;
|
||||||
|
return 1;
|
||||||
|
}}
|
||||||
|
|
||||||
18
cf5-opt.vim
18
cf5-opt.vim
@@ -55,6 +55,24 @@ function! s:SetUpLibrariesWindows()
|
|||||||
let g:Ltbb=" /LIBPATH:\"".g:tbblib."\" tbb.lib"
|
let g:Ltbb=" /LIBPATH:\"".g:tbblib."\" tbb.lib"
|
||||||
let g:tbbmalloc=" tbbmalloc.lib"
|
let g:tbbmalloc=" tbbmalloc.lib"
|
||||||
let g:tbbmproxy=" tbbmalloc_proxy.lib"
|
let g:tbbmproxy=" tbbmalloc_proxy.lib"
|
||||||
|
"
|
||||||
|
" Win SDK
|
||||||
|
"
|
||||||
|
let g:wsdkdir="C:\\Program Files (x86)\\Microsoft SDKs\\Windows\\v7.0A"
|
||||||
|
let g:wsdkinc=g:wsdkdir."\\Include"
|
||||||
|
let g:wsdklib=g:wsdkdir."\\Lib\\x64"
|
||||||
|
let g:wsdkbin=g:wsdkdir."\\Bin"
|
||||||
|
let g:Iwsdk=" /I\"".g:wsdkinc."\""
|
||||||
|
let g:Lwsdk=" /LIBPATH:\"".g:wsdklib."\""
|
||||||
|
"
|
||||||
|
" OpenGL
|
||||||
|
"
|
||||||
|
let g:wsdkdir="C:\\Program Files (x86)\\Microsoft SDKs\\Windows\\v7.0A"
|
||||||
|
let g:glinc=g:wsdkinc
|
||||||
|
let g:gllib=g:wsdklib
|
||||||
|
let g:glbin=""
|
||||||
|
let g:Igl=" /I\"".g:glinc."\""
|
||||||
|
let g:Lgl=" /LIBPATH:\"".g:gllib."\" OpenGL32.Lib GLU32.lib"
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! SetUpLibraries()
|
function! SetUpLibraries()
|
||||||
|
|||||||
54
exception_constructor.cpp
Normal file
54
exception_constructor.cpp
Normal file
@@ -0,0 +1,54 @@
|
|||||||
|
/* Check cf5-opt.vim defs.
|
||||||
|
VIM: let g:lcppflags="-std=c++11 -O2 -pthread"
|
||||||
|
VIM: let g:wcppflags="/O2 /EHsc /DWIN32"
|
||||||
|
VIM-: let g:cf5output=0
|
||||||
|
*/
|
||||||
|
#include <iostream>
|
||||||
|
#include <exception>
|
||||||
|
#include <stdexcept>
|
||||||
|
|
||||||
|
struct A
|
||||||
|
{
|
||||||
|
A()
|
||||||
|
{
|
||||||
|
std::cout << "A::A()" << std::endl;
|
||||||
|
}
|
||||||
|
~A()
|
||||||
|
{
|
||||||
|
std::cout << "A::~A()" << std::endl;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
struct B : public A
|
||||||
|
{
|
||||||
|
B()
|
||||||
|
{
|
||||||
|
std::cout << "B::B()" << std::endl;
|
||||||
|
}
|
||||||
|
~B()
|
||||||
|
{
|
||||||
|
throw std::runtime_error("test");
|
||||||
|
std::cout << "B::~B()" << std::endl;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
int main ( void )
|
||||||
|
{try{
|
||||||
|
|
||||||
|
B o;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
catch ( const std::exception& e )
|
||||||
|
{
|
||||||
|
std::cerr << std::endl
|
||||||
|
<< "std::exception(\"" << e.what() << "\")." << std::endl;
|
||||||
|
return 2;
|
||||||
|
}
|
||||||
|
catch ( ... )
|
||||||
|
{
|
||||||
|
std::cerr << std::endl
|
||||||
|
<< "unknown exception." << std::endl;
|
||||||
|
return 1;
|
||||||
|
}}
|
||||||
|
|
||||||
BIN
memory_test_vahagnk-e6530.xlsx
Normal file
BIN
memory_test_vahagnk-e6530.xlsx
Normal file
Binary file not shown.
37
pod_constructor_optimization_for_array.cpp
Normal file
37
pod_constructor_optimization_for_array.cpp
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
#include <iostream>
|
||||||
|
#include <exception>
|
||||||
|
|
||||||
|
struct A
|
||||||
|
{
|
||||||
|
int a;
|
||||||
|
int b;
|
||||||
|
|
||||||
|
A()
|
||||||
|
{
|
||||||
|
std::cout << "A::A()" << std::endl;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
int main ( void )
|
||||||
|
{try{
|
||||||
|
|
||||||
|
A a[4];
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
catch ( const std::exception& e )
|
||||||
|
{
|
||||||
|
std::cerr << std::endl
|
||||||
|
<< "std::exception(\"" << e.what() << "\")." << std::endl;
|
||||||
|
return 2;
|
||||||
|
}
|
||||||
|
catch ( ... )
|
||||||
|
{
|
||||||
|
std::cerr << std::endl
|
||||||
|
<< "unknown exception." << std::endl;
|
||||||
|
return 1;
|
||||||
|
}}
|
||||||
|
|
||||||
@@ -1,132 +0,0 @@
|
|||||||
#include <iostream>
|
|
||||||
#include <exception>
|
|
||||||
#include <string>
|
|
||||||
#include <algorithm>
|
|
||||||
|
|
||||||
#include <tbb/parallel_for.h>
|
|
||||||
#include <tbb/blocked_range.h>
|
|
||||||
|
|
||||||
static const size_t N = 23;
|
|
||||||
|
|
||||||
class SubStringFinder
|
|
||||||
{
|
|
||||||
const std::string str;
|
|
||||||
size_t *max_array;
|
|
||||||
size_t *pos_array;
|
|
||||||
|
|
||||||
public:
|
|
||||||
void operator() ( const tbb::blocked_range<size_t>& r ) const
|
|
||||||
{
|
|
||||||
std::cout << "gs:" << r.grainsize() << " b:" << r.begin() << " e:" << r.end() << std::endl;
|
|
||||||
std::cout.flush();
|
|
||||||
for ( size_t i = r.begin(); i != r.end(); ++i )
|
|
||||||
{
|
|
||||||
size_t max_size = 0, max_pos = 0;
|
|
||||||
for (size_t j = 0; j < str.size(); ++j)
|
|
||||||
if (j != i)
|
|
||||||
{
|
|
||||||
size_t limit = str.size()-std::max(i,j);
|
|
||||||
for (size_t k = 0; k < limit; ++k)
|
|
||||||
{
|
|
||||||
if (str[i + k] != str[j + k])
|
|
||||||
break;
|
|
||||||
if (k > max_size)
|
|
||||||
{
|
|
||||||
max_size = k;
|
|
||||||
max_pos = j;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
max_array[i] = max_size;
|
|
||||||
pos_array[i] = max_pos;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
SubStringFinder(std::string &s, size_t *m, size_t *p)
|
|
||||||
: str(s), max_array(m), pos_array(p)
|
|
||||||
{ }
|
|
||||||
};
|
|
||||||
|
|
||||||
int test()
|
|
||||||
{
|
|
||||||
std::string str[N] = { std::string("a"), std::string("b") };
|
|
||||||
|
|
||||||
for (size_t i = 2; i < N; ++i)
|
|
||||||
str[i] = str[i-1]+str[i-2];
|
|
||||||
std::string &to_scan = str[N-1];
|
|
||||||
size_t num_elem = to_scan.size();
|
|
||||||
|
|
||||||
size_t *max = new size_t[num_elem];
|
|
||||||
size_t *pos = new size_t[num_elem];
|
|
||||||
|
|
||||||
tbb::parallel_for( tbb::blocked_range<size_t>(0, num_elem ),
|
|
||||||
SubStringFinder( to_scan, max, pos ) );
|
|
||||||
|
|
||||||
for (size_t i = 0; i < num_elem; ++i)
|
|
||||||
std::cout << " " << max[i] << "(" << pos[i] << ")" << std::endl;
|
|
||||||
delete[] pos;
|
|
||||||
delete[] max;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
class copy_tracker
|
|
||||||
{
|
|
||||||
int v;
|
|
||||||
public:
|
|
||||||
copy_tracker()
|
|
||||||
: v(0)
|
|
||||||
{
|
|
||||||
std::cout << "copy_tracker::copy_tracker()" << std::endl;
|
|
||||||
}
|
|
||||||
|
|
||||||
copy_tracker( copy_tracker& c )
|
|
||||||
: v( c.v )
|
|
||||||
{
|
|
||||||
std::cout << "copy_tracker::copy_tracker( copy_tracker& c )" << std::endl;
|
|
||||||
}
|
|
||||||
|
|
||||||
void echo()
|
|
||||||
{
|
|
||||||
std::cout << v << std::endl;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
copy_tracker copy_tracker_by_value()
|
|
||||||
{
|
|
||||||
return copy_tracker();
|
|
||||||
}
|
|
||||||
|
|
||||||
copy_tracker copy_tracker_by_value2()
|
|
||||||
{
|
|
||||||
return copy_tracker_by_value();
|
|
||||||
}
|
|
||||||
|
|
||||||
void test_copy_tracker()
|
|
||||||
{
|
|
||||||
volatile copy_tracker o = copy_tracker_by_value2();
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
int test_flowgraph()
|
|
||||||
{
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
int main ( void )
|
|
||||||
{try{
|
|
||||||
|
|
||||||
test();
|
|
||||||
|
|
||||||
test_copy_tracker();
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
catch ( const std::exception& e )
|
|
||||||
{
|
|
||||||
std::cerr << std::endl
|
|
||||||
<< "std::exception(\"" << e.what() << "\")." << std::endl;
|
|
||||||
}
|
|
||||||
catch ( ... )
|
|
||||||
{
|
|
||||||
std::cerr << std::endl
|
|
||||||
<< "unknown exception." << std::endl;
|
|
||||||
}}
|
|
||||||
@@ -1,37 +0,0 @@
|
|||||||
cd "%~dp0"
|
|
||||||
|
|
||||||
call "C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\vcvarsall.bat" amd64
|
|
||||||
|
|
||||||
set SRCDIR=%CD%\src
|
|
||||||
|
|
||||||
set BOOST=C:\Users\Vahagnk\src\boost_1_53_0
|
|
||||||
set BOOST_INCLUDE=%BOOST%
|
|
||||||
set BOOST_LIB64=%BOOST%\stage\win64_vc12\lib
|
|
||||||
|
|
||||||
set GTEST=C:\Users\Vahagnk\src\gtest-1.6.0
|
|
||||||
set GTEST_INCLUDE=%GTEST%\include
|
|
||||||
set GTEST_LIB64=%GTEST%\build_x64_vc12
|
|
||||||
|
|
||||||
set ZLIB=C:\Users\Vahagnk\src\zlib-1.2.7
|
|
||||||
set ZLIB_INCLUDE=%ZLIB%
|
|
||||||
set ZLIB_LIB64=%ZLIB%\build_x64_vc12
|
|
||||||
|
|
||||||
set LIBPNG=C:\Users\Vahagnk\src\libpng-1.5.10
|
|
||||||
set LIBPNG_INCLUDE=%LIBPNG%
|
|
||||||
set LIBPNG_LIB64=%LIBPNG%\build_x64_vc10
|
|
||||||
|
|
||||||
set TBB=C:\Users\Vahagnk\src\tbb41_20121003oss
|
|
||||||
set TBB_INCLUDE=%TBB%\include
|
|
||||||
set TBB_LIB64=%TBB%\lib\intel64\vc11
|
|
||||||
set TBB_BIN64=%TBB%\bin\intel64\vc11
|
|
||||||
|
|
||||||
set SRCDIR="%~dp0\src"
|
|
||||||
|
|
||||||
set CL=/I%BOOST_INLCUDE% /I%TBB_INLCUDE% /I%GTEST_INCLUDE% /I%LIBPNG_INCLUDE% /I%ZLIB_INCLUDE% /I%QT_INCLUDE% /I%SRCDIR% /D_CRT_SECURE_NO_WARNINGS /DTEST_VERSION=\"vahagn_experimental\"
|
|
||||||
set LINK=/INCREMENTAL:NO
|
|
||||||
|
|
||||||
set PATH=%TBB_BIN64%;%PATH%
|
|
||||||
|
|
||||||
start devenv.exe %~n0.sln
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1,20 +0,0 @@
|
|||||||
|
|
||||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
|
||||||
# Visual Studio 2012
|
|
||||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "tbb_test", "tbb_test.vcxproj", "{5771BE40-BCC1-4DBB-9E0B-9B0FEF85927E}"
|
|
||||||
EndProject
|
|
||||||
Global
|
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
|
||||||
Debug|x64 = Debug|x64
|
|
||||||
Release|x64 = Release|x64
|
|
||||||
EndGlobalSection
|
|
||||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
|
||||||
{5771BE40-BCC1-4DBB-9E0B-9B0FEF85927E}.Debug|x64.ActiveCfg = Debug|x64
|
|
||||||
{5771BE40-BCC1-4DBB-9E0B-9B0FEF85927E}.Debug|x64.Build.0 = Debug|x64
|
|
||||||
{5771BE40-BCC1-4DBB-9E0B-9B0FEF85927E}.Release|x64.ActiveCfg = Release|x64
|
|
||||||
{5771BE40-BCC1-4DBB-9E0B-9B0FEF85927E}.Release|x64.Build.0 = Release|x64
|
|
||||||
EndGlobalSection
|
|
||||||
GlobalSection(SolutionProperties) = preSolution
|
|
||||||
HideSolutionNode = FALSE
|
|
||||||
EndGlobalSection
|
|
||||||
EndGlobal
|
|
||||||
@@ -1,159 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
||||||
<ItemGroup Label="ProjectConfigurations">
|
|
||||||
<ProjectConfiguration Include="Debug|Win32">
|
|
||||||
<Configuration>Debug</Configuration>
|
|
||||||
<Platform>Win32</Platform>
|
|
||||||
</ProjectConfiguration>
|
|
||||||
<ProjectConfiguration Include="Debug|x64">
|
|
||||||
<Configuration>Debug</Configuration>
|
|
||||||
<Platform>x64</Platform>
|
|
||||||
</ProjectConfiguration>
|
|
||||||
<ProjectConfiguration Include="Release|Win32">
|
|
||||||
<Configuration>Release</Configuration>
|
|
||||||
<Platform>Win32</Platform>
|
|
||||||
</ProjectConfiguration>
|
|
||||||
<ProjectConfiguration Include="Release|x64">
|
|
||||||
<Configuration>Release</Configuration>
|
|
||||||
<Platform>x64</Platform>
|
|
||||||
</ProjectConfiguration>
|
|
||||||
</ItemGroup>
|
|
||||||
<PropertyGroup Label="Globals">
|
|
||||||
<ProjectGuid>{5771BE40-BCC1-4DBB-9E0B-9B0FEF85927E}</ProjectGuid>
|
|
||||||
<Keyword>Win32Proj</Keyword>
|
|
||||||
<RootNamespace>tbb_test</RootNamespace>
|
|
||||||
</PropertyGroup>
|
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
|
||||||
<ConfigurationType>Application</ConfigurationType>
|
|
||||||
<UseDebugLibraries>true</UseDebugLibraries>
|
|
||||||
<CharacterSet>Unicode</CharacterSet>
|
|
||||||
<PlatformToolset>v110</PlatformToolset>
|
|
||||||
</PropertyGroup>
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
|
||||||
<ConfigurationType>Application</ConfigurationType>
|
|
||||||
<UseDebugLibraries>true</UseDebugLibraries>
|
|
||||||
<CharacterSet>Unicode</CharacterSet>
|
|
||||||
<PlatformToolset>v110</PlatformToolset>
|
|
||||||
</PropertyGroup>
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
|
||||||
<ConfigurationType>Application</ConfigurationType>
|
|
||||||
<UseDebugLibraries>false</UseDebugLibraries>
|
|
||||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
|
||||||
<CharacterSet>Unicode</CharacterSet>
|
|
||||||
<PlatformToolset>v110</PlatformToolset>
|
|
||||||
</PropertyGroup>
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
|
||||||
<ConfigurationType>Application</ConfigurationType>
|
|
||||||
<UseDebugLibraries>false</UseDebugLibraries>
|
|
||||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
|
||||||
<CharacterSet>Unicode</CharacterSet>
|
|
||||||
<PlatformToolset>v110</PlatformToolset>
|
|
||||||
</PropertyGroup>
|
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
|
||||||
<ImportGroup Label="ExtensionSettings">
|
|
||||||
</ImportGroup>
|
|
||||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
|
||||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
||||||
</ImportGroup>
|
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
|
||||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
||||||
</ImportGroup>
|
|
||||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
|
||||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
||||||
</ImportGroup>
|
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
|
||||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
||||||
</ImportGroup>
|
|
||||||
<PropertyGroup Label="UserMacros" />
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
|
||||||
<LinkIncremental>false</LinkIncremental>
|
|
||||||
</PropertyGroup>
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
|
||||||
<LinkIncremental>false</LinkIncremental>
|
|
||||||
</PropertyGroup>
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
|
||||||
<LinkIncremental>false</LinkIncremental>
|
|
||||||
</PropertyGroup>
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
|
||||||
<LinkIncremental>false</LinkIncremental>
|
|
||||||
</PropertyGroup>
|
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
|
||||||
<ClCompile>
|
|
||||||
<PrecompiledHeader>
|
|
||||||
</PrecompiledHeader>
|
|
||||||
<WarningLevel>Level3</WarningLevel>
|
|
||||||
<Optimization>Disabled</Optimization>
|
|
||||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<AdditionalIncludeDirectories>$(TBB_INCLUDE)</AdditionalIncludeDirectories>
|
|
||||||
</ClCompile>
|
|
||||||
<Link>
|
|
||||||
<SubSystem>Console</SubSystem>
|
|
||||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
|
||||||
<AdditionalLibraryDirectories>$(TBB_LIB64)</AdditionalLibraryDirectories>
|
|
||||||
<AdditionalDependencies>tbb_debug.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
||||||
</Link>
|
|
||||||
</ItemDefinitionGroup>
|
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
|
||||||
<ClCompile>
|
|
||||||
<PrecompiledHeader>
|
|
||||||
</PrecompiledHeader>
|
|
||||||
<WarningLevel>Level3</WarningLevel>
|
|
||||||
<Optimization>Disabled</Optimization>
|
|
||||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<AdditionalIncludeDirectories>$(TBB_INCLUDE)</AdditionalIncludeDirectories>
|
|
||||||
</ClCompile>
|
|
||||||
<Link>
|
|
||||||
<SubSystem>Console</SubSystem>
|
|
||||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
|
||||||
<AdditionalLibraryDirectories>$(TBB_LIB64)</AdditionalLibraryDirectories>
|
|
||||||
<AdditionalDependencies>tbb_debug.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
||||||
</Link>
|
|
||||||
</ItemDefinitionGroup>
|
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
|
||||||
<ClCompile>
|
|
||||||
<WarningLevel>Level3</WarningLevel>
|
|
||||||
<PrecompiledHeader>
|
|
||||||
</PrecompiledHeader>
|
|
||||||
<Optimization>MaxSpeed</Optimization>
|
|
||||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
|
||||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
|
||||||
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<AdditionalIncludeDirectories>$(TBB_INCLUDE)</AdditionalIncludeDirectories>
|
|
||||||
</ClCompile>
|
|
||||||
<Link>
|
|
||||||
<SubSystem>Console</SubSystem>
|
|
||||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
|
||||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
|
||||||
<OptimizeReferences>true</OptimizeReferences>
|
|
||||||
<AdditionalLibraryDirectories>$(TBB_LIB64)</AdditionalLibraryDirectories>
|
|
||||||
<AdditionalDependencies>tbb.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
||||||
</Link>
|
|
||||||
</ItemDefinitionGroup>
|
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
|
||||||
<ClCompile>
|
|
||||||
<WarningLevel>Level3</WarningLevel>
|
|
||||||
<PrecompiledHeader>
|
|
||||||
</PrecompiledHeader>
|
|
||||||
<Optimization>MaxSpeed</Optimization>
|
|
||||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
|
||||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
|
||||||
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<AdditionalIncludeDirectories>$(TBB_INCLUDE)</AdditionalIncludeDirectories>
|
|
||||||
</ClCompile>
|
|
||||||
<Link>
|
|
||||||
<SubSystem>Console</SubSystem>
|
|
||||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
|
||||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
|
||||||
<OptimizeReferences>true</OptimizeReferences>
|
|
||||||
<AdditionalLibraryDirectories>$(TBB_LIB64)</AdditionalLibraryDirectories>
|
|
||||||
<AdditionalDependencies>tbb.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
||||||
</Link>
|
|
||||||
</ItemDefinitionGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<ClCompile Include="main.cpp" />
|
|
||||||
</ItemGroup>
|
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
|
||||||
<ImportGroup Label="ExtensionTargets">
|
|
||||||
</ImportGroup>
|
|
||||||
</Project>
|
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
||||||
<ItemGroup>
|
|
||||||
<Filter Include="Source Files">
|
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
|
||||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Header Files">
|
|
||||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
|
||||||
<Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Resource Files">
|
|
||||||
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
|
|
||||||
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
|
|
||||||
</Filter>
|
|
||||||
</ItemGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<ClCompile Include="main.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
</ItemGroup>
|
|
||||||
</Project>
|
|
||||||
Reference in New Issue
Block a user