dvm updated, fixed and improved dead_code pass

This commit is contained in:
ALEXks
2024-03-22 12:00:01 +03:00
parent 0f39f6474d
commit d27b9d1ed3
7 changed files with 64 additions and 80 deletions

View File

@@ -26,7 +26,6 @@ extern "C" void exit(int status);
#include "extcxx_low.h"
extern "C" int number_of_ll_node;
extern "C" PTR_SYMB last_file_symbol;
extern "C" PTR_SYMB FileLastSymbol(...);
#undef USER
@@ -1647,7 +1646,7 @@ SgFile &SgProject::file(int i)
#ifdef __SPF
SgStatement::setCurrProcessFile(pt->filename());
SgStatement::setCurrProcessLine(0);
last_file_symbol = FileLastSymbol(pt->filename());
last_file_symbol = file->cur_symb;
#endif
return *pt;
}
@@ -1775,13 +1774,13 @@ int SgFile::switchToFile(const std::string &name)
SgFile *file = &(CurrentProject->file(it->second.second));
current_file_id = it->second.second;
current_file = file;
SgStatement::setCurrProcessFile(file->filename());
SgStatement::setCurrProcessLine(0);
last_file_symbol = current_file->filept->cur_symb;
}
}
last_file_symbol = FileLastSymbol(name.c_str());
return it->second.second;
}