OpenMPToolsInterface / LLVM-openmp

This is a stale repository and only there for the commit history. All development moved over to the llvm-project repository! Was: LLVM OpenMP runtime with experimental changes for OMPT (Preview of TR7 features in *_tr branches)
Other
16 stars 13 forks source link

Support OMPT callbacks for multiple roots #17

Closed omalyshe closed 7 years ago

omalyshe commented 7 years ago

For initial app thread I left thread_begin and task_create callbacks in ompt_post_init() which is called from __kmp_do_serial_initialize() after the root was registered (kmp_register_root(TRUE)). For foreign roots I put thread_begin and task_create to kmp_register_root() when it is called with FALSE, that is not for the initial app thread.

Manual test with two c++ threads seems to pass. Automatic unit test to be added later.

omalyshe commented 7 years ago

P.S. Several lines have trailing spaces removed.

jprotze commented 7 years ago

LGTM