-
assigned issue to
UPC++ Hello world and upcxx::rank*
Issue #33
resolved
the current Hello World from section 2.2:
#include <upcxx/upcxx.hpp>
#include <iostream>
int main(int argc, char *argv[])
{
upcxx::init(); // initialize UPC++
std::cout << "Hello World" << std::endl
<< " ranks:" << upcxx::rank_n() // how many UPC++ ranks?
<< " my rank: " << upcxx::rank_me() // which rank am I?
<< std::endl;
upcxx::finalize(); // finalize UPC++
return 0;
}
This example calls functions upcxx::rank_n()
and upcxx::rank_me()
which are currently undefined.
We need to either change these to upcxx::world().rank_n()
and upcxx::world().rank_me()
, or define additional functions to provide this as syntactic sugar.
Comments (2)
-
Account Deleted -
- changed status to resolved
Added in c237440.
- Log in to comment
I think it's an oversight to not have rank_n and rank_me as free functions implying world. I don't have the time or a computer. Reassigned to amir to make decision.