class TheTips {
public:
double solve(vector <string> clues, vector <int> probability, int print);
};
|
You should implement this class as described in the Floyd-Warshall lecture notes, by packing the matrix into bits, and then using _mm_or_si128(). The gradescripts will have the number of nodes be up to 3797, so please have your program work with inputs of that size.
class APFlow {
public:
int N;
uint8_t *Adj;
uint8_t *Flow;
void CalcFlow();
};
|
You should also do this as described in the Floyd-Warshall lecture notes, by using the SIMD intrinsics _mm_set1_epi8(), _mm_min_epu8() and _mm_max_epu8(). The gradescript tests input sizes of up to 2400 nodes, so please have your program work up to that size.
In particular, do not use the versions of The-Tips-Main.cpp and AP-Flow-Main.cpp that are in the Floyd-Warshall lecture notes, as they are different from these versions. These versions have added a timeout after 4 seconds.
Your TA will inspect your code to make sure that it is using SIMD correctly. The gradescripts will timeout and call your programs incorrect if they take longer than 4 seconds.
Have fun! After doing this lab, you get to put "Intel SIMD Extensions" onto your resume. You're welcome.