Files
SAPFOR/Sapfor/_src/DirectiveProcessing/directive_omp_parser.h
2025-03-25 20:39:29 +03:00

26 lines
695 B
C++

#pragma once
#include <string>
#include <set>
#include <map>
#include <vector>
#include "../Utils/errors.h"
#define SPF_USER_DIR 777
#define SPF_USER_DIR_COPY 999
#define SPF_OMP_DIR 888
struct OmpDir
{
std::set<std::string> privVars;
std::set<std::string> threadPrivVars;
std::map<std::string, std::set<std::string>> redVars;
std::set<std::string> keys;
SgStatement* start = NULL;
SgStatement* end = NULL;
};
void removeOmpDir(SgStatement* st);
std::vector<OmpDir> parseOmpInStatement(SgStatement* st, const std::set<std::string>& globalPriv, bool forDo = false);
void parseOmpDirectives(SgFile* file, std::vector<Messages>& currMessages);