no message
This commit is contained in:
@@ -3,8 +3,8 @@ import Common.Visual.CommonUI;
|
||||
import Common.Visual.Menus.DataMenuBar;
|
||||
import _VisualDVM.Visual.Menus.VisualiserMenu;
|
||||
import Common.Visual.Fonts.VisualiserFonts;
|
||||
import Visual_DVM_2021.Passes.PassCode_2021;
|
||||
import Visual_DVM_2021.Passes.Pass_2021;
|
||||
import Visual_DVM_2021.Passes.PassCode;
|
||||
import Visual_DVM_2021.Passes.Pass;
|
||||
public class ComponentsMenuBar extends DataMenuBar {
|
||||
public ComponentsMenuBar() {
|
||||
super("компоненты");
|
||||
@@ -13,15 +13,15 @@ public class ComponentsMenuBar extends DataMenuBar {
|
||||
"Восстановление предыдущей версии компонента", "/icons/Resurrect.png") {
|
||||
{
|
||||
setFont(CommonUI.getTheme().Fonts.get(VisualiserFonts.Menu));
|
||||
add(Pass_2021.passes.get(PassCode_2021.ResurrectComponent).createMenuItem());
|
||||
add(Pass_2021.passes.get(PassCode_2021.ResurrectComponentFromServer).createMenuItem());
|
||||
add(Pass.passes.get(PassCode.ResurrectComponent).createMenuItem());
|
||||
add(Pass.passes.get(PassCode.ResurrectComponentFromServer).createMenuItem());
|
||||
}
|
||||
}
|
||||
);
|
||||
addPasses(PassCode_2021.InstallComponentFromFolder,
|
||||
PassCode_2021.UpdateSelectedComponents,
|
||||
PassCode_2021.PublishComponent,
|
||||
PassCode_2021.ShowComponentChangesLog);
|
||||
Pass_2021.passes.get(PassCode_2021.PublishComponent).setControlsVisible(false);
|
||||
addPasses(PassCode.InstallComponentFromFolder,
|
||||
PassCode.UpdateSelectedComponents,
|
||||
PassCode.PublishComponent,
|
||||
PassCode.ShowComponentChangesLog);
|
||||
Pass.passes.get(PassCode.PublishComponent).setControlsVisible(false);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,9 +14,9 @@ import _VisualDVM.ProjectData.Files.LanguageStyle;
|
||||
import _VisualDVM.Repository.Component.OSDComponent;
|
||||
import _VisualDVM.Repository.Component.Visualizer_2;
|
||||
import _VisualDVM.TestingSystem.Common.Test.Test;
|
||||
import Visual_DVM_2021.Passes.PassCode_2021;
|
||||
import Visual_DVM_2021.Passes.PassCode;
|
||||
import Visual_DVM_2021.Passes.PassException;
|
||||
import Visual_DVM_2021.Passes.Pass_2021;
|
||||
import Visual_DVM_2021.Passes.Pass;
|
||||
import org.apache.commons.io.FileUtils;
|
||||
|
||||
import java.io.File;
|
||||
@@ -57,80 +57,80 @@ public abstract class Sapfor extends OSDComponent {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
}
|
||||
public static PassCode_2021[] getAnalysesCodes() {
|
||||
return new PassCode_2021[]{
|
||||
PassCode_2021.SPF_ParseFilesWithOrder,
|
||||
PassCode_2021.SPF_GetFileLineInfo,
|
||||
PassCode_2021.SPF_GetArrayDistributionOnlyRegions,
|
||||
PassCode_2021.SPF_GetIncludeDependencies,
|
||||
PassCode_2021.SPF_GetGraphLoops,
|
||||
PassCode_2021.SPF_GetGraphFunctions,
|
||||
PassCode_2021.SPF_GetAllDeclaratedArrays,
|
||||
PassCode_2021.SPF_GetArrayDistributionOnlyAnalysis,
|
||||
PassCode_2021.SPF_GetArrayDistribution
|
||||
public static PassCode[] getAnalysesCodes() {
|
||||
return new PassCode[]{
|
||||
PassCode.SPF_ParseFilesWithOrder,
|
||||
PassCode.SPF_GetFileLineInfo,
|
||||
PassCode.SPF_GetArrayDistributionOnlyRegions,
|
||||
PassCode.SPF_GetIncludeDependencies,
|
||||
PassCode.SPF_GetGraphLoops,
|
||||
PassCode.SPF_GetGraphFunctions,
|
||||
PassCode.SPF_GetAllDeclaratedArrays,
|
||||
PassCode.SPF_GetArrayDistributionOnlyAnalysis,
|
||||
PassCode.SPF_GetArrayDistribution
|
||||
};
|
||||
}
|
||||
public static PassCode_2021[] getLoopsTransformationsCodes() {
|
||||
return new PassCode_2021[]{
|
||||
PassCode_2021.SPF_LoopEndDoConverterPass,
|
||||
PassCode_2021.SPF_LoopFission,
|
||||
PassCode_2021.SPF_LoopUnion,
|
||||
PassCode_2021.SPF_LoopUnrolling
|
||||
public static PassCode[] getLoopsTransformationsCodes() {
|
||||
return new PassCode[]{
|
||||
PassCode.SPF_LoopEndDoConverterPass,
|
||||
PassCode.SPF_LoopFission,
|
||||
PassCode.SPF_LoopUnion,
|
||||
PassCode.SPF_LoopUnrolling
|
||||
};
|
||||
}
|
||||
public static PassCode_2021[] getPrivatesTransformationsCodes() {
|
||||
return new PassCode_2021[]{
|
||||
PassCode_2021.SPF_PrivateShrinking,
|
||||
PassCode_2021.SPF_PrivateExpansion,
|
||||
PassCode_2021.SPF_PrivateRemoving,
|
||||
PassCode_2021.SPF_InsertPrivateFromGUI
|
||||
public static PassCode[] getPrivatesTransformationsCodes() {
|
||||
return new PassCode[]{
|
||||
PassCode.SPF_PrivateShrinking,
|
||||
PassCode.SPF_PrivateExpansion,
|
||||
PassCode.SPF_PrivateRemoving,
|
||||
PassCode.SPF_InsertPrivateFromGUI
|
||||
};
|
||||
}
|
||||
public static PassCode_2021[] getProceduresTransformationsCodes() {
|
||||
return new PassCode_2021[]{
|
||||
PassCode_2021.SPF_InlineProcedures,
|
||||
PassCode_2021.SPF_InlineProceduresH,
|
||||
PassCode_2021.SPF_DuplicateFunctionChains,
|
||||
PassCode_2021.SPF_RemoveUnusedFunctions
|
||||
public static PassCode[] getProceduresTransformationsCodes() {
|
||||
return new PassCode[]{
|
||||
PassCode.SPF_InlineProcedures,
|
||||
PassCode.SPF_InlineProceduresH,
|
||||
PassCode.SPF_DuplicateFunctionChains,
|
||||
PassCode.SPF_RemoveUnusedFunctions
|
||||
};
|
||||
}
|
||||
public static PassCode_2021[] getDVMTransformationsCodes() {
|
||||
return new PassCode_2021[]{
|
||||
PassCode_2021.SPF_RemoveDvmDirectivesToComments,
|
||||
PassCode_2021.SPF_RemoveDvmDirectives,
|
||||
PassCode_2021.SPF_RemoveOmpDirectives
|
||||
public static PassCode[] getDVMTransformationsCodes() {
|
||||
return new PassCode[]{
|
||||
PassCode.SPF_RemoveDvmDirectivesToComments,
|
||||
PassCode.SPF_RemoveDvmDirectives,
|
||||
PassCode.SPF_RemoveOmpDirectives
|
||||
};
|
||||
}
|
||||
public static PassCode_2021[] getIntervalsTransformationsCodes() {
|
||||
return new PassCode_2021[]{
|
||||
PassCode_2021.SPF_CreateIntervalsTree,
|
||||
PassCode_2021.SPF_RemoveDvmIntervals
|
||||
public static PassCode[] getIntervalsTransformationsCodes() {
|
||||
return new PassCode[]{
|
||||
PassCode.SPF_CreateIntervalsTree,
|
||||
PassCode.SPF_RemoveDvmIntervals
|
||||
};
|
||||
}
|
||||
public static PassCode_2021[] getRegionsTransformationsCodes() {
|
||||
return new PassCode_2021[]{
|
||||
PassCode_2021.SPF_ResolveParallelRegionConflicts,
|
||||
PassCode_2021.SPF_InsertDvmhRegions
|
||||
public static PassCode[] getRegionsTransformationsCodes() {
|
||||
return new PassCode[]{
|
||||
PassCode.SPF_ResolveParallelRegionConflicts,
|
||||
PassCode.SPF_InsertDvmhRegions
|
||||
};
|
||||
}
|
||||
public static PassCode_2021[] getPreparationTransformationsCodes() {
|
||||
return new PassCode_2021[]{
|
||||
PassCode_2021.SPF_RenameIncludes,
|
||||
PassCode_2021.SPF_InsertIncludesPass,
|
||||
PassCode_2021.SPF_CorrectCodeStylePass,
|
||||
PassCode_2021.SPF_ConvertStructures,
|
||||
PassCode_2021.SPF_CreateCheckpoints,
|
||||
PassCode_2021.SPF_InitDeclsWithZero,
|
||||
PassCode_2021.SPF_ExpressionSubstitution,
|
||||
PassCode_2021.EraseBadSymbols,
|
||||
PassCode_2021.SPF_RemoveComments,
|
||||
PassCode_2021.SPF_RemoveDeadCode,
|
||||
PassCode_2021.CombineFiles,
|
||||
PassCode_2021.CopyProject,
|
||||
PassCode_2021.PrepareForModulesAssembly,
|
||||
PassCode_2021.DVMConvertProject,
|
||||
PassCode_2021.SPF_ResolveCommonBlockConflicts,
|
||||
PassCode_2021.SPF_InsertImplicitNone
|
||||
public static PassCode[] getPreparationTransformationsCodes() {
|
||||
return new PassCode[]{
|
||||
PassCode.SPF_RenameIncludes,
|
||||
PassCode.SPF_InsertIncludesPass,
|
||||
PassCode.SPF_CorrectCodeStylePass,
|
||||
PassCode.SPF_ConvertStructures,
|
||||
PassCode.SPF_CreateCheckpoints,
|
||||
PassCode.SPF_InitDeclsWithZero,
|
||||
PassCode.SPF_ExpressionSubstitution,
|
||||
PassCode.EraseBadSymbols,
|
||||
PassCode.SPF_RemoveComments,
|
||||
PassCode.SPF_RemoveDeadCode,
|
||||
PassCode.CombineFiles,
|
||||
PassCode.CopyProject,
|
||||
PassCode.PrepareForModulesAssembly,
|
||||
PassCode.DVMConvertProject,
|
||||
PassCode.SPF_ResolveCommonBlockConflicts,
|
||||
PassCode.SPF_InsertImplicitNone
|
||||
};
|
||||
}
|
||||
//<editor-fold desc="компонент">
|
||||
@@ -315,7 +315,7 @@ public abstract class Sapfor extends OSDComponent {
|
||||
DBProjectFile cuf = null;
|
||||
if (Current.HasFile()) {
|
||||
cuf = Current.getFile();
|
||||
Pass_2021.passes.get(PassCode_2021.CloseCurrentFile).Do();
|
||||
Pass.passes.get(PassCode.CloseCurrentFile).Do();
|
||||
}
|
||||
if (mode) //модификация
|
||||
{
|
||||
@@ -339,23 +339,23 @@ public abstract class Sapfor extends OSDComponent {
|
||||
} else CommonUI.Info("Сохранение файлов отсутствует.");
|
||||
}
|
||||
if (cuf != null)
|
||||
Pass_2021.passes.get(PassCode_2021.OpenCurrentFile).Do(cuf);
|
||||
Pass.passes.get(PassCode.OpenCurrentFile).Do(cuf);
|
||||
}
|
||||
//</editor-fold>
|
||||
public Visual_DVM_2021.Passes.SapforAnalysis getAnalysisByPhase(String phase) {
|
||||
for (PassCode_2021 analysis_code : getAnalysesCodes()) {
|
||||
Visual_DVM_2021.Passes.SapforAnalysis analysis = (Visual_DVM_2021.Passes.SapforAnalysis) Pass_2021.passes.get(analysis_code);
|
||||
for (PassCode analysis_code : getAnalysesCodes()) {
|
||||
Visual_DVM_2021.Passes.SapforAnalysis analysis = (Visual_DVM_2021.Passes.SapforAnalysis) Pass.passes.get(analysis_code);
|
||||
if (analysis.phase().equals(phase)) return analysis;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
public void ResetAllAnalyses() {
|
||||
for (PassCode_2021 code : getAnalysesCodes())
|
||||
(Pass_2021.passes.get(code)).Reset();
|
||||
for (PassCode code : getAnalysesCodes())
|
||||
(Pass.passes.get(code)).Reset();
|
||||
//------------------------------------------------------------------------------------------>>>> пакетный режим.
|
||||
if (CommonUI.isActive()) {
|
||||
Pass_2021.passes.get(PassCode_2021.Precompilation).Reset();
|
||||
Pass_2021.passes.get(PassCode_2021.SPF_GetGCovInfo).Reset();
|
||||
Pass.passes.get(PassCode.Precompilation).Reset();
|
||||
Pass.passes.get(PassCode.SPF_GetGCovInfo).Reset();
|
||||
}
|
||||
Global.enable_text_changed = false;
|
||||
Global.transformationPermission = TransformationPermission.None;
|
||||
@@ -369,43 +369,43 @@ public abstract class Sapfor extends OSDComponent {
|
||||
return ((GlobalDatabase)CommonUtils.db).settings.get(SettingName.FREE_FORM).toBoolean() ? LanguageStyle.free : LanguageStyle.fixed;
|
||||
}
|
||||
//----------
|
||||
public static Vector<PassCode_2021> getScenariosCodes() {
|
||||
Vector<PassCode_2021> res = new Vector<>();
|
||||
res.add(PassCode_2021.SPF_InitDeclsWithZero);//+
|
||||
res.add(PassCode_2021.SPF_ConvertStructures);//+
|
||||
res.add(PassCode_2021.SPF_ExpressionSubstitution);//+
|
||||
public static Vector<PassCode> getScenariosCodes() {
|
||||
Vector<PassCode> res = new Vector<>();
|
||||
res.add(PassCode.SPF_InitDeclsWithZero);//+
|
||||
res.add(PassCode.SPF_ConvertStructures);//+
|
||||
res.add(PassCode.SPF_ExpressionSubstitution);//+
|
||||
//--
|
||||
res.add(PassCode_2021.SPF_CreateCheckpoints); //+
|
||||
res.add(PassCode_2021.SPF_CreateIntervalsTree);//+
|
||||
res.add(PassCode_2021.SPF_RemoveDvmIntervals);//+
|
||||
res.add(PassCode.SPF_CreateCheckpoints); //+
|
||||
res.add(PassCode.SPF_CreateIntervalsTree);//+
|
||||
res.add(PassCode.SPF_RemoveDvmIntervals);//+
|
||||
//--
|
||||
res.add(PassCode_2021.SPF_RemoveDvmDirectives); //+
|
||||
res.add(PassCode_2021.SPF_RemoveDvmDirectivesToComments); //+
|
||||
res.add(PassCode.SPF_RemoveDvmDirectives); //+
|
||||
res.add(PassCode.SPF_RemoveDvmDirectivesToComments); //+
|
||||
|
||||
res.add(PassCode_2021.SPF_RemoveOmpDirectives);//+
|
||||
res.add(PassCode_2021.SPF_RemoveComments);//+
|
||||
res.add(PassCode_2021.SPF_RemoveDeadCode);//+
|
||||
res.add(PassCode_2021.SPF_RenameIncludes);
|
||||
res.add(PassCode_2021.SPF_InsertIncludesPass);//+
|
||||
res.add(PassCode.SPF_RemoveOmpDirectives);//+
|
||||
res.add(PassCode.SPF_RemoveComments);//+
|
||||
res.add(PassCode.SPF_RemoveDeadCode);//+
|
||||
res.add(PassCode.SPF_RenameIncludes);
|
||||
res.add(PassCode.SPF_InsertIncludesPass);//+
|
||||
//--
|
||||
res.add(PassCode_2021.SPF_LoopEndDoConverterPass); //+
|
||||
res.add(PassCode_2021.SPF_LoopUnion);//+
|
||||
res.add(PassCode_2021.SPF_LoopFission);//+
|
||||
res.add(PassCode.SPF_LoopEndDoConverterPass); //+
|
||||
res.add(PassCode.SPF_LoopUnion);//+
|
||||
res.add(PassCode.SPF_LoopFission);//+
|
||||
//--
|
||||
res.add(PassCode_2021.SPF_PrivateShrinking);//+
|
||||
res.add(PassCode_2021.SPF_PrivateExpansion);//+
|
||||
res.add(PassCode_2021.SPF_PrivateRemoving);//+
|
||||
res.add(PassCode.SPF_PrivateShrinking);//+
|
||||
res.add(PassCode.SPF_PrivateExpansion);//+
|
||||
res.add(PassCode.SPF_PrivateRemoving);//+
|
||||
//--
|
||||
res.add(PassCode_2021.SPF_RemoveUnusedFunctions);//+
|
||||
res.add(PassCode_2021.SPF_DuplicateFunctionChains);//+
|
||||
res.add(PassCode.SPF_RemoveUnusedFunctions);//+
|
||||
res.add(PassCode.SPF_DuplicateFunctionChains);//+
|
||||
//--
|
||||
res.add(PassCode_2021.SPF_ResolveParallelRegionConflicts);//+
|
||||
res.add(PassCode_2021.SPF_ResolveCommonBlockConflicts);//+
|
||||
res.add(PassCode.SPF_ResolveParallelRegionConflicts);//+
|
||||
res.add(PassCode.SPF_ResolveCommonBlockConflicts);//+
|
||||
//-
|
||||
res.add(PassCode_2021.SPF_InsertDvmhRegions);//+
|
||||
res.add(PassCode_2021.SPF_SharedMemoryParallelization);//+
|
||||
res.add(PassCode_2021.SPF_InsertImplicitNone);//+
|
||||
res.add(PassCode_2021.CreateParallelVariants); //?
|
||||
res.add(PassCode.SPF_InsertDvmhRegions);//+
|
||||
res.add(PassCode.SPF_SharedMemoryParallelization);//+
|
||||
res.add(PassCode.SPF_InsertImplicitNone);//+
|
||||
res.add(PassCode.CreateParallelVariants); //?
|
||||
return res;
|
||||
}
|
||||
//------------------------------------------------------------------------------------------------------------------
|
||||
@@ -517,7 +517,7 @@ public abstract class Sapfor extends OSDComponent {
|
||||
Constants.parse_err_file)
|
||||
&& (new File(workspace, "dvm.proj")).exists();
|
||||
}
|
||||
public static boolean analysis(File sapfor_drv, File workspace, PassCode_2021 code, String flags, Vector<String> result_lines) throws Exception {
|
||||
public static boolean analysis(File sapfor_drv, File workspace, PassCode code, String flags, Vector<String> result_lines) throws Exception {
|
||||
return performScript("analysis",
|
||||
sapfor_drv,
|
||||
workspace,
|
||||
@@ -544,7 +544,7 @@ public abstract class Sapfor extends OSDComponent {
|
||||
if (Sapfor.parse(sapfor, workspace, flags)
|
||||
) {
|
||||
Vector<String> outputLines = new Vector<>();
|
||||
if (Sapfor.analysis(sapfor, workspace, PassCode_2021.SPF_GetMaxMinBlockDistribution, flags, outputLines)) {
|
||||
if (Sapfor.analysis(sapfor, workspace, PassCode.SPF_GetMaxMinBlockDistribution, flags, outputLines)) {
|
||||
//---
|
||||
for (String line : outputLines) {
|
||||
String prefix = "GET_MIN_MAX_BLOCK_DIST: ";
|
||||
|
||||
@@ -3,8 +3,8 @@ import Common.Utils.CommonUtils;
|
||||
import _VisualDVM.GlobalData.GlobalDatabase;
|
||||
import _VisualDVM.Global;
|
||||
import _VisualDVM.GlobalData.Settings.SettingName;
|
||||
import Visual_DVM_2021.Passes.PassCode_2021;
|
||||
import Visual_DVM_2021.Passes.Pass_2021;
|
||||
import Visual_DVM_2021.Passes.PassCode;
|
||||
import Visual_DVM_2021.Passes.Pass;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@@ -81,7 +81,7 @@ public class Visualiser extends Component {
|
||||
if (workspace.exists())
|
||||
return workspace;
|
||||
else
|
||||
Pass_2021.passes.get(PassCode_2021.UpdateSetting).Do(
|
||||
Pass.passes.get(PassCode.UpdateSetting).Do(
|
||||
SettingName.Workspace, "");
|
||||
}
|
||||
return Global.ProjectsDirectory;
|
||||
|
||||
Reference in New Issue
Block a user