Find Jobs
Hire Freelancers

C++: Simple Code Parallelization, one thread per core.

$30-5000 USD

完了済み
投稿日: 約14年前

$30-5000 USD

完了時にお支払い
I have a function: int MyFunc(void *Data, const int &DataNum) in C++. I'd like to run the function many times, with DataNum ranging from 0...N-1. I'd like to run one function on each core, presumably on its own thread. When one function finishes, I'd like the next one to start. Typically, I have a multi-core processor with, say M cores, where M is typically about 4. Typically, I have N pieces of data, where N typically ranges from 2 to 12. (Sometimes I have more cores than data!) I'm looking for a class with a static function. Something like this: class SpawnFunctionOnProcessorCores() { public: static std::vector<int> SpawnAndWait( int (*Command)(void *, const int &i), void *Data, const int &MinNum, const int &MaxNum, const DWORD &TimeToWaitInMilliSeconds); } I'll be using Visual Studio 2008 on Windows. The return is the vector of results from the functions. Also, please give me a simple test program to show the function is working. ## Deliverables You can do this program pretty much any way you want. My understanding is that there are some open-source multi-core commands support by Visual Studio. If you use them, great. If not, no problem. Also, I have a class called SpawnThread, which currently spawns a bunch of threads at once. Presumably, all you need to do is figure out the number of processors on the computer, and add a thread affinity. (You might also need to know when a thread ends, so that you can spawn the next one.) If it will be helpful to you, I can share the class with you. But, I suspect you want to write your own thing.
プロジェクト ID: 3271785

プロジェクトについて

7個の提案
リモートプロジェクト
アクティブ 14年前

お金を稼ぎたいですか?

Freelancerで入札する利点

予算と期間を設定してください
仕事で報酬を得る
提案をご説明ください
登録して仕事に入札するのは無料です
アワード者:
ユーザーアバター
See private message.
$42.50 USD 14日以内
5.0 (4 レビュー)
3.1
3.1
この仕事に7人のフリーランサーが、平均$61 USDで入札しています
ユーザーアバター
See private message.
$85 USD 14日以内
4.4 (75 レビュー)
5.8
5.8
ユーザーアバター
See private message.
$63.75 USD 14日以内
3.9 (3 レビュー)
5.8
5.8
ユーザーアバター
See private message.
$85 USD 14日以内
5.0 (28 レビュー)
4.0
4.0
ユーザーアバター
See private message.
$42.50 USD 14日以内
0.0 (0 レビュー)
0.0
0.0
ユーザーアバター
See private message.
$80.75 USD 14日以内
0.0 (0 レビュー)
0.0
0.0
ユーザーアバター
See private message.
$25.50 USD 14日以内
0.0 (0 レビュー)
0.0
0.0

クライアントについて

UNITED STATESのフラグ
Boston, United States
5.0
33
メンバー登録日:3月 23, 2006

クライアント確認

ありがとうございます!無料クレジットを受け取るリンクをメールしました。
メールを送信中に問題が発生しました。もう一度お試しください。
登録ユーザー 投稿された仕事の合計
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
プレビューを読み込み中
位置情報へのアクセスが許可されました。
あなたのログインセッションの有効期限がきれ、ログアウトされました。もう一度ログインしてください。