[過去ログ] Boost総合スレ part9 (981レス)
上下前次1-新
抽出解除 レス栞
このスレッドは過去ログ倉庫に格納されています。
次スレ検索 歴削→次スレ 栞削→次スレ 過去ログメニュー
361: 356 [] 2011/03/01(火) 10:40:42.97 AAS
プロジェクトパス\project\boost_1_45_0/boost/mpl/eval_if.hpp:
In instantiation of 'boost::mpl::eval_if<mpl_::bool_<false
boost::range_const_iterator<filter<int, int, filter<int, int, __gnu_cxx::__normal_iterator<const int*, std::vector<int>
pass_thru<int always_true<int> >::const_iterator, pass_thru<int main()::<lambda(const int&)> >
boost::range_mutable_iterator<filter<int, int, filter<int, int, __gnu_cxx::__normal_iterator<const int*, std::vector<int>
pass_thru<int always_true<int> >::const_iterator, pass_thru<int main()::<lambda(const int&)> > > >':
プロジェクトパス\project\boost_1_45_0/boost/foreach.hpp:355:13:
instantiated from 'boost::foreach_detail_::foreach_iterator<filter<int, int, filter<int, int, __gnu_cxx::__normal_iterator<const int*, std::vector<int>
pass_thru<int always_true<int> >::const_iterator, pass_thru<int main()::<lambda(const int&)> mpl_::bool_<false> >'
プロジェクトパス\project\linq.cpp:150:2:
instantiated from here
プロジェクトパス\project\boost_1_45_0/boost/mpl/eval_if.hpp:38:31:
error: no type named 'type' in 'struct boost::mpl::eval_if<mpl_::bool_<false
boost::range_const_iterator<filter<int, int, filter<int, int, __gnu_cxx::__normal_iterator<const int*, std::vector<int>
pass_thru<int always_true<int> >::const_iterator, pass_thru<int main()::<lambda(const int&)> >
boost::range_mutable_iterator<filter<int, int, filter<int, int, __gnu_cxx::__normal_iterator<const int*, std::vector<int>
pass_thru<int always_true<int> >::const_iterator, pass_thru<int main()::<lambda(const int&)> > > >::f_'
592: デフォルトの名無しさん [sage] 2011/09/05(月) 08:59:00.97 AAS
>>591591(1): デフォルトの名無しさん [sage] 2011/09/05(月) 04:45:04.36 AAS
boost:threadに関する質問です
スレッドを作って内部で勝手に処理させるクラスを作っています
class test {
boost::thread thr;
void start(){
thr = boost::thread(func);
}
void stop();
}
のようにして生成したスレッドのコピーをメンバ変数に保存してい置くのはまずいでしょうか
一応boost::thread(func)がスコープを外れて破棄されても動作するようですがどうなのでしょうか
別にまずくはない。
boost::threadのデストラクタはdetach()を呼び出す。つまり、threadオブジェクトと
スレッドの寿命は同期していないし、スレッドが終わるまで待ってくれたりもしない。
同期させたければthreadオブジェクトを破棄する前にスレッド関数を抜けるように
フラグやcondition_variable等で指示しておき、(thread::join()等で)スレッドが終了した事を確認してから、
threadを破棄する必要がある。
768: デフォルトの名無しさん [sage] 2011/11/27(日) 02:26:15.97 AAS
boostのヘッダー1個、boostを使うソース1個でも十分遅いからな。
801(1): デフォルトの名無しさん [sage] 2012/01/06(金) 12:54:36.97 AAS
ublasってopencvより遅い気がするのだけど気のせい?
ublasの方が速い場合ってエクスプレッショナルテンプレートが効く場合だけ?
gccのコンパイルオプションで同じぐらいの速度にならないものだろうか
981: デフォルトの名無しさん [sage] 2012/07/14(土) 01:11:45.97 AAS
ソースでzipがだいたい100Mか。
Unix用のbz2で50Mとは。圧縮度けっこう違うんだな。知らなかったすごい。
上下前次1-新書関写板覧索設栞歴
スレ情報 赤レス抽出 画像レス抽出 歴の未読スレ AAサムネイル
ぬこの手 ぬこTOP 0.045s