Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| c3a669d497 | |||
| 9b76409781 | |||
| ed3d133dcd |
7
.idea/workspace.xml
generated
7
.idea/workspace.xml
generated
@@ -7,8 +7,7 @@
|
|||||||
</component>
|
</component>
|
||||||
<component name="ChangeListManager">
|
<component name="ChangeListManager">
|
||||||
<list default="true" id="e42177c3-2328-4b27-8a01-35779b2beb99" name="Default Changelist" comment="">
|
<list default="true" id="e42177c3-2328-4b27-8a01-35779b2beb99" name="Default Changelist" comment="">
|
||||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/src/_VisualDVM/Passes/All/SPF_InsertIncludesPass.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/Passes/All/SPF_InsertIncludesPass.java" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/src/_VisualDVM/Passes/PassCode.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/Passes/PassCode.java" afterDir="false" />
|
|
||||||
</list>
|
</list>
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||||
@@ -88,7 +87,7 @@
|
|||||||
<property name="UI_DESIGNER_EDITOR_MODE.UIDesignerToolWindowManager.SHOW" value="true" />
|
<property name="UI_DESIGNER_EDITOR_MODE.UIDesignerToolWindowManager.SHOW" value="true" />
|
||||||
<property name="UI_DESIGNER_EDITOR_MODE.UIDesignerToolWindowManager.WIDTH" value="509" />
|
<property name="UI_DESIGNER_EDITOR_MODE.UIDesignerToolWindowManager.WIDTH" value="509" />
|
||||||
<property name="extract.method.default.visibility" value="public" />
|
<property name="extract.method.default.visibility" value="public" />
|
||||||
<property name="last_opened_file_path" value="$PROJECT_DIR$/src/icons/Transformations" />
|
<property name="last_opened_file_path" value="$PROJECT_DIR$/src" />
|
||||||
<property name="project.structure.last.edited" value="Artifacts" />
|
<property name="project.structure.last.edited" value="Artifacts" />
|
||||||
<property name="project.structure.proportion" value="0.15" />
|
<property name="project.structure.proportion" value="0.15" />
|
||||||
<property name="project.structure.side.proportion" value="0.27322906" />
|
<property name="project.structure.side.proportion" value="0.27322906" />
|
||||||
@@ -101,10 +100,10 @@
|
|||||||
<recent name="controls.Trees" />
|
<recent name="controls.Trees" />
|
||||||
</key>
|
</key>
|
||||||
<key name="CopyFile.RECENT_KEYS">
|
<key name="CopyFile.RECENT_KEYS">
|
||||||
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\src\icons\Transformations" />
|
|
||||||
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\src" />
|
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\src" />
|
||||||
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\src\_dif_utils" />
|
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\src\_dif_utils" />
|
||||||
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\libs" />
|
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\libs" />
|
||||||
|
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\src\icons\Transformations" />
|
||||||
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\src\_VisualDVM\TestingSystem\DVM\DVMTasks\UI" />
|
<recent name="C:\Users\misha\Documents\visual_sapfor_2023\src\_VisualDVM\TestingSystem\DVM\DVMTasks\UI" />
|
||||||
</key>
|
</key>
|
||||||
<key name="MoveMembersDialog.RECENTS_KEY">
|
<key name="MoveMembersDialog.RECENTS_KEY">
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"ServerUserPassword": "mprit_2011",
|
"ServerUserPassword": "mprit_2011",
|
||||||
"OfferRegistrationOnStart": true,
|
"OfferRegistrationOnStart": true,
|
||||||
"Workspace": "E:\\Tests",
|
"Workspace": "E:\\Tests",
|
||||||
"ProjectsSearchDirectory": "E:\\Tests",
|
"ProjectsSearchDirectory": "E:\\Tests\\Downloads\\bugreport_1749652835\\tmp_influxsys\\v3",
|
||||||
"DocumentsDirectory": "C:\\Users\\misha\\Documents\\_testing_system",
|
"DocumentsDirectory": "C:\\Users\\misha\\Documents\\_testing_system",
|
||||||
"VisualiserPath": "C:\\Users\\misha\\Downloads",
|
"VisualiserPath": "C:\\Users\\misha\\Downloads",
|
||||||
"Sapfor_FPath": "E:\\_sapfor_x64\\Components\\Sapfor_F",
|
"Sapfor_FPath": "E:\\_sapfor_x64\\Components\\Sapfor_F",
|
||||||
@@ -25,7 +25,6 @@
|
|||||||
"ComponentsWindowHeight": 250,
|
"ComponentsWindowHeight": 250,
|
||||||
"Kernels": 8,
|
"Kernels": 8,
|
||||||
"LocalMakePathWindows": "C:\\MinGW\\msys\\1.0\\bin\\make.exe",
|
"LocalMakePathWindows": "C:\\MinGW\\msys\\1.0\\bin\\make.exe",
|
||||||
"PrecompilationFlags": " ",
|
|
||||||
"CheckTestingIntervalSeconds": 10,
|
"CheckTestingIntervalSeconds": 10,
|
||||||
"AutoCheckTesting": true,
|
"AutoCheckTesting": true,
|
||||||
"EmailOnTestingProgress": true,
|
"EmailOnTestingProgress": true,
|
||||||
|
|||||||
@@ -5,16 +5,16 @@ public class IntegerPairJson {
|
|||||||
public int key;
|
public int key;
|
||||||
@Expose
|
@Expose
|
||||||
public int value;
|
public int value;
|
||||||
public IntegerPairJson(int key_in, int value_in) {
|
|
||||||
key = key_in;
|
|
||||||
value = value_in;
|
|
||||||
}
|
|
||||||
public IntegerPairJson() {
|
|
||||||
}
|
|
||||||
public int getKey() {
|
public int getKey() {
|
||||||
return key;
|
return key;
|
||||||
}
|
}
|
||||||
public int getValue() {
|
public int getValue() {
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
public IntegerPairJson(int key_in, int value_in) {
|
||||||
|
key = key_in;
|
||||||
|
value = value_in;
|
||||||
|
}
|
||||||
|
public IntegerPairJson() {
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package Common.Visual;
|
package Common.Visual;
|
||||||
import Common.MainModule_;
|
import Common.MainModule_;
|
||||||
|
import Common.Utils.Utils_;
|
||||||
|
|
||||||
import javax.swing.*;
|
import javax.swing.*;
|
||||||
import javax.swing.event.ChangeListener;
|
import javax.swing.event.ChangeListener;
|
||||||
|
|||||||
@@ -1,10 +0,0 @@
|
|||||||
package _VisualDVM.ComponentsServer.Component.Json;
|
|
||||||
import com.google.gson.annotations.Expose;
|
|
||||||
public class VersionInfo_json {
|
|
||||||
@Expose
|
|
||||||
public int version;
|
|
||||||
@Expose
|
|
||||||
public String build_date;
|
|
||||||
@Expose
|
|
||||||
public String build_time;
|
|
||||||
}
|
|
||||||
@@ -4,8 +4,8 @@ import Common.Passes.PassException;
|
|||||||
import Common.Utils.Pair;
|
import Common.Utils.Pair;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
import Common.Visual.UI;
|
import Common.Visual.UI;
|
||||||
import _VisualDVM.ComponentsServer.Component.Json.VersionInfo_json;
|
|
||||||
import _VisualDVM.ComponentsServer.Component.OSDComponent;
|
import _VisualDVM.ComponentsServer.Component.OSDComponent;
|
||||||
|
import _VisualDVM.ComponentsServer.Component.Visualizer_2;
|
||||||
import _VisualDVM.Constants;
|
import _VisualDVM.Constants;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
import _VisualDVM.Passes.PassCode;
|
import _VisualDVM.Passes.PassCode;
|
||||||
@@ -13,15 +13,16 @@ import _VisualDVM.Passes.Sapfor.SapforAnalysis;
|
|||||||
import _VisualDVM.ProjectData.Files.DBProjectFile;
|
import _VisualDVM.ProjectData.Files.DBProjectFile;
|
||||||
import _VisualDVM.ProjectData.Files.UI.Editor.SPFEditor;
|
import _VisualDVM.ProjectData.Files.UI.Editor.SPFEditor;
|
||||||
import _VisualDVM.ProjectData.Project.db_project_info;
|
import _VisualDVM.ProjectData.Project.db_project_info;
|
||||||
import _VisualDVM.ProjectData.SapforData.ModifiedFile_json;
|
|
||||||
import _VisualDVM.ProjectData.SapforData.SapforResult_json;
|
|
||||||
import _VisualDVM.TestingSystem.Common.Test.Test;
|
import _VisualDVM.TestingSystem.Common.Test.Test;
|
||||||
import _VisualDVM.Utils;
|
import _VisualDVM.Utils;
|
||||||
import org.apache.commons.io.FileUtils;
|
import org.apache.commons.io.FileUtils;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.nio.charset.Charset;
|
import java.nio.charset.Charset;
|
||||||
import java.util.*;
|
import java.util.Collections;
|
||||||
|
import java.util.LinkedHashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Vector;
|
||||||
public abstract class Sapfor extends OSDComponent {
|
public abstract class Sapfor extends OSDComponent {
|
||||||
public static final int empty_code = -100;
|
public static final int empty_code = -100;
|
||||||
public static final int canceled_code = -99;
|
public static final int canceled_code = -99;
|
||||||
@@ -32,6 +33,8 @@ public abstract class Sapfor extends OSDComponent {
|
|||||||
public Vector<String> Intrinsics = new Vector<>();
|
public Vector<String> Intrinsics = new Vector<>();
|
||||||
public LinkedHashMap<String, String> ModifiedFiles = new LinkedHashMap<>();
|
public LinkedHashMap<String, String> ModifiedFiles = new LinkedHashMap<>();
|
||||||
public LinkedHashMap<String, String> OldFiles = new LinkedHashMap<>();
|
public LinkedHashMap<String, String> OldFiles = new LinkedHashMap<>();
|
||||||
|
int size;
|
||||||
|
int[] sizes;
|
||||||
String PID = "";
|
String PID = "";
|
||||||
private int errorCode;
|
private int errorCode;
|
||||||
private String result;
|
private String result;
|
||||||
@@ -71,8 +74,7 @@ public abstract class Sapfor extends OSDComponent {
|
|||||||
PassCode.SPF_PrivateShrinking,
|
PassCode.SPF_PrivateShrinking,
|
||||||
PassCode.SPF_PrivateExpansion,
|
PassCode.SPF_PrivateExpansion,
|
||||||
PassCode.SPF_PrivateRemoving,
|
PassCode.SPF_PrivateRemoving,
|
||||||
PassCode.SPF_InsertPrivateFromGUI,
|
PassCode.SPF_InsertPrivateFromGUI
|
||||||
PassCode.SPF_InsertPrivateArrayDirectives
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
public static PassCode[] getProceduresTransformationsCodes() {
|
public static PassCode[] getProceduresTransformationsCodes() {
|
||||||
@@ -418,9 +420,7 @@ public abstract class Sapfor extends OSDComponent {
|
|||||||
public void GetVersionInfo() {
|
public void GetVersionInfo() {
|
||||||
try {
|
try {
|
||||||
RunAnalysis("SPF_GetVersionAndBuildDate", -1, "", "");
|
RunAnalysis("SPF_GetVersionAndBuildDate", -1, "", "");
|
||||||
VersionInfo_json versionInfo_json = Utils_.gson.fromJson(getResult(),VersionInfo_json.class);
|
Visualizer_2.UnpackVersionInfo(this, getResult());
|
||||||
version = versionInfo_json.version;
|
|
||||||
date_text = versionInfo_json.build_date+" "+ versionInfo_json.build_time;
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
Utils_.MainLog.PrintException(e);
|
Utils_.MainLog.PrintException(e);
|
||||||
UI.Error("Не удалось получить версию компонента " + Utils_.DQuotes(getComponentType().getDescription()));
|
UI.Error("Не удалось получить версию компонента " + Utils_.DQuotes(getComponentType().getDescription()));
|
||||||
@@ -502,21 +502,6 @@ public abstract class Sapfor extends OSDComponent {
|
|||||||
this.predictorStats = predictorStats;
|
this.predictorStats = predictorStats;
|
||||||
}
|
}
|
||||||
public void decodeString(String runResult) throws Exception {
|
public void decodeString(String runResult) throws Exception {
|
||||||
SapforResult_json resultJson = Utils_.gson.fromJson(runResult, SapforResult_json.class);
|
|
||||||
//---
|
|
||||||
setErrorCode(resultJson.errorCode);
|
|
||||||
setOutput(resultJson.output);
|
|
||||||
setResult(resultJson.result);
|
|
||||||
setOutputMessage(resultJson.outputMessage);
|
|
||||||
setPredictorStats(resultJson.predictorStats);
|
|
||||||
//--
|
|
||||||
if (resultJson.files!=null && !resultJson.files.isEmpty()){
|
|
||||||
for (ModifiedFile_json file: resultJson.files){
|
|
||||||
ModifiedFiles.put(Utils_.toW(file.name), file.text);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//--
|
|
||||||
/*
|
|
||||||
int codeIdx = runResult.indexOf(' ');
|
int codeIdx = runResult.indexOf(' ');
|
||||||
if (codeIdx == -1) throw new PassException("Wrong input parameter");
|
if (codeIdx == -1) throw new PassException("Wrong input parameter");
|
||||||
setErrorCode(Integer.parseInt(runResult.substring(0, codeIdx)));
|
setErrorCode(Integer.parseInt(runResult.substring(0, codeIdx)));
|
||||||
@@ -560,12 +545,13 @@ public abstract class Sapfor extends OSDComponent {
|
|||||||
}
|
}
|
||||||
codeIdx += count;
|
codeIdx += count;
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
//-
|
//-
|
||||||
public void Command(String request_in) throws Exception {
|
public void Command(String request_in) throws Exception {
|
||||||
setErrorCode(empty_code);
|
setErrorCode(empty_code);
|
||||||
outputMessage = output = result = predictorStats = "";
|
outputMessage = output = result = predictorStats = "";
|
||||||
|
size = 0;
|
||||||
|
sizes = null;
|
||||||
ModifiedFiles.clear();
|
ModifiedFiles.clear();
|
||||||
//модификации.-------------------------------------------------------------->>>>
|
//модификации.-------------------------------------------------------------->>>>
|
||||||
decodeString(Global.visualizer_2.Command(request_in).replace((char) 1, '\n'));
|
decodeString(Global.visualizer_2.Command(request_in).replace((char) 1, '\n'));
|
||||||
|
|||||||
@@ -12,7 +12,6 @@ import java.io.PrintWriter;
|
|||||||
import java.net.InetAddress;
|
import java.net.InetAddress;
|
||||||
import java.net.Socket;
|
import java.net.Socket;
|
||||||
import java.nio.file.Paths;
|
import java.nio.file.Paths;
|
||||||
import java.util.Date;
|
|
||||||
public class Visualizer_2 extends OSDComponent {
|
public class Visualizer_2 extends OSDComponent {
|
||||||
public String PID = "";
|
public String PID = "";
|
||||||
//</editor-fold>
|
//</editor-fold>
|
||||||
@@ -28,15 +27,11 @@ public class Visualizer_2 extends OSDComponent {
|
|||||||
port = port_in;
|
port = port_in;
|
||||||
}
|
}
|
||||||
public static void UnpackVersionInfo(Component component, String packed) {
|
public static void UnpackVersionInfo(Component component, String packed) {
|
||||||
|
|
||||||
String[] data = packed.split("\\|");
|
String[] data = packed.split("\\|");
|
||||||
//лишний пробел.
|
//лишний пробел.
|
||||||
String text = data[0].substring(0, data[0].length() - 1);
|
String text = data[0].substring(0, data[0].length() - 1);
|
||||||
component.date_text = data[1] + data[2] + data[3];
|
component.date_text = data[1] + data[2] + data[3];
|
||||||
component.version = Long.parseLong(text);
|
component.version = Long.parseLong(text);
|
||||||
|
|
||||||
// component.version = 6666;
|
|
||||||
// component.date_text = new Date().toString();
|
|
||||||
}
|
}
|
||||||
//<editor-fold desc="компонент">
|
//<editor-fold desc="компонент">
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ import Common.Utils.Vector_;
|
|||||||
|
|
||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
public class Constants {
|
public class Constants {
|
||||||
public static final int version = 1260;
|
public static final int version = 1253;
|
||||||
public static final int planner_version = 24;
|
public static final int planner_version = 24;
|
||||||
public static final int testingMaxKernels = 64;
|
public static final int testingMaxKernels = 64;
|
||||||
//--
|
//--
|
||||||
|
|||||||
@@ -65,8 +65,6 @@ public class NormalProperties extends VisualDVMProperties {
|
|||||||
public int Kernels = Utils.getHalfKernels();
|
public int Kernels = Utils.getHalfKernels();
|
||||||
@Expose
|
@Expose
|
||||||
public String LocalMakePathWindows = "C:\\MinGW\\msys\\1.0\\bin\\make.exe";
|
public String LocalMakePathWindows = "C:\\MinGW\\msys\\1.0\\bin\\make.exe";
|
||||||
@Expose
|
|
||||||
public String PrecompilationFlags = "";
|
|
||||||
//--тестирование
|
//--тестирование
|
||||||
@Expose
|
@Expose
|
||||||
public int CheckTestingIntervalSeconds = 10; //интервал автопроверки тестирования
|
public int CheckTestingIntervalSeconds = 10; //интервал автопроверки тестирования
|
||||||
@@ -125,8 +123,6 @@ public class NormalProperties extends VisualDVMProperties {
|
|||||||
@Override
|
@Override
|
||||||
public String getFieldDescription(String fieldName) {
|
public String getFieldDescription(String fieldName) {
|
||||||
switch (fieldName) {
|
switch (fieldName) {
|
||||||
case "PrecompilationFlags":
|
|
||||||
return "Опции предварительной компиляции";
|
|
||||||
case "ErasePackageWorkspace":
|
case "ErasePackageWorkspace":
|
||||||
return "Очистка рабочего пространства пакета на целевой машине";
|
return "Очистка рабочего пространства пакета на целевой машине";
|
||||||
case "CompleteCompilationOptions":
|
case "CompleteCompilationOptions":
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package _VisualDVM.Passes.All;
|
package _VisualDVM.Passes.All;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
|
import Common.Visual.UI;
|
||||||
import Common.Visual.Windows.Dialog.Text.ComboTextDialog;
|
import Common.Visual.Windows.Dialog.Text.ComboTextDialog;
|
||||||
import _VisualDVM.ComponentsServer.Component.Sapfor.Sapfor;
|
import _VisualDVM.ComponentsServer.Component.Sapfor.Sapfor;
|
||||||
import _VisualDVM.ComponentsServer.Component.Sapfor.TransformationPermission;
|
import _VisualDVM.ComponentsServer.Component.Sapfor.TransformationPermission;
|
||||||
@@ -54,8 +55,9 @@ public class CombineFiles extends Transformation {
|
|||||||
Vector<String> result_lines = new Vector<>();
|
Vector<String> result_lines = new Vector<>();
|
||||||
Vector<String> all_includes = new Vector<>();
|
Vector<String> all_includes = new Vector<>();
|
||||||
//-----------------------------
|
//-----------------------------
|
||||||
|
|
||||||
result_lines.add("!-Found " + target.allIncludes.size() + " headers");
|
result_lines.add("!-Found " + target.allIncludes.size() + " headers");
|
||||||
System.out.println("found " + target.allIncludes.size() + " headers");
|
System.out.println("found "+target.allIncludes.size()+" headers");
|
||||||
for (String name : target.allIncludes) {
|
for (String name : target.allIncludes) {
|
||||||
all_includes.add(" include " + Utils_.Quotes(Utils_.toU(name))); //---
|
all_includes.add(" include " + Utils_.Quotes(Utils_.toU(name))); //---
|
||||||
result_lines.add("! include " + Utils_.Quotes(Utils_.toU(name)));
|
result_lines.add("! include " + Utils_.Quotes(Utils_.toU(name)));
|
||||||
@@ -86,6 +88,7 @@ public class CombineFiles extends Transformation {
|
|||||||
result_lines.addAll(FileUtils.readLines(target.db.files.Data.get(name).file));
|
result_lines.addAll(FileUtils.readLines(target.db.files.Data.get(name).file));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FileUtils.writeLines(result, result_lines, false);
|
FileUtils.writeLines(result, result_lines, false);
|
||||||
//-------------------------------
|
//-------------------------------
|
||||||
//теперь скопировать остальные файлы
|
//теперь скопировать остальные файлы
|
||||||
|
|||||||
@@ -121,7 +121,7 @@ public class Precompilation extends Pass<db_project_info> {
|
|||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
protected String getFortranFlags() {
|
protected String getFortranFlags() {
|
||||||
return Global.normalProperties.PrecompilationFlags;
|
return "";
|
||||||
}
|
}
|
||||||
protected void prepareForParse() throws Exception {
|
protected void prepareForParse() throws Exception {
|
||||||
target.CleanAnalyses();
|
target.CleanAnalyses();
|
||||||
@@ -212,11 +212,7 @@ public class Precompilation extends Pass<db_project_info> {
|
|||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected boolean validate() {
|
protected boolean validate() {
|
||||||
return outputLines.stream().noneMatch(
|
return outputLines.stream().noneMatch(line -> line.toLowerCase().startsWith("error"));
|
||||||
line -> (line.toLowerCase().startsWith("error")
|
|
||||||
|| line.toLowerCase().startsWith("gfortran.exe: error:")
|
|
||||||
|| line.toLowerCase().startsWith("gfortran: error:")
|
|
||||||
));
|
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected void performDone() throws Exception {
|
protected void performDone() throws Exception {
|
||||||
|
|||||||
@@ -1,11 +1,16 @@
|
|||||||
package _VisualDVM.Passes.All;
|
package _VisualDVM.Passes.All;
|
||||||
|
import Common.Utils.Index;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
|
import Common.Visual.UI;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
import _VisualDVM.Passes.Sapfor.SapforAnalysis;
|
import _VisualDVM.Passes.Sapfor.SapforAnalysis;
|
||||||
import _VisualDVM.ProjectData.Files.DBProjectFile;
|
import _VisualDVM.ProjectData.Files.DBProjectFile;
|
||||||
import _VisualDVM.ProjectData.SapforData.Arrays.ArrayDecl;
|
import _VisualDVM.ProjectData.SapforData.Arrays.ArrayDecl;
|
||||||
import _VisualDVM.ProjectData.SapforData.Arrays.ArraysJson;
|
import _VisualDVM.ProjectData.SapforData.Arrays.ArraysJson;
|
||||||
import _VisualDVM.ProjectData.SapforData.Arrays.ProjectArray;
|
import _VisualDVM.ProjectData.SapforData.Arrays.ProjectArray;
|
||||||
|
|
||||||
|
import javax.rmi.CORBA.Util;
|
||||||
|
import java.math.BigInteger;
|
||||||
public class SPF_GetAllDeclaratedArrays extends SapforAnalysis {
|
public class SPF_GetAllDeclaratedArrays extends SapforAnalysis {
|
||||||
@Override
|
@Override
|
||||||
public String phase() {
|
public String phase() {
|
||||||
@@ -27,11 +32,11 @@ public class SPF_GetAllDeclaratedArrays extends SapforAnalysis {
|
|||||||
@Override
|
@Override
|
||||||
public void unpack(String packed) throws Exception {
|
public void unpack(String packed) throws Exception {
|
||||||
ArraysJson arraysJson = Utils_.gson.fromJson(packed, ArraysJson.class);
|
ArraysJson arraysJson = Utils_.gson.fromJson(packed, ArraysJson.class);
|
||||||
for (ProjectArray array : arraysJson.allArrays) {
|
for (ProjectArray array: arraysJson.allArrays){
|
||||||
array.Init();
|
array.Init();
|
||||||
target.declaratedArrays.put(array.id, array);
|
target.declaratedArrays.put(array.id, array);
|
||||||
//--
|
//--
|
||||||
for (ArrayDecl decl : array.declPlaces) {
|
for (ArrayDecl decl: array.declPlaces){
|
||||||
DBProjectFile projectFile = target.db.files.get(decl.file);
|
DBProjectFile projectFile = target.db.files.get(decl.file);
|
||||||
projectFile.array_decls.add(decl);
|
projectFile.array_decls.add(decl);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
package _VisualDVM.Passes.All;
|
package _VisualDVM.Passes.All;
|
||||||
|
import Common.Utils.Index;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
import Common.Utils.Vector_;
|
import Common.Utils.Vector_;
|
||||||
import Common.Visual.Controls.PassControl;
|
import Common.Visual.Controls.PassControl;
|
||||||
|
import Common.Visual.UI;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
import _VisualDVM.Passes.Sapfor.SapforAnalysis;
|
import _VisualDVM.Passes.Sapfor.SapforAnalysis;
|
||||||
import _VisualDVM.ProjectData.SapforData.Regions.ParallelRegion;
|
import _VisualDVM.ProjectData.SapforData.Regions.ParallelRegion;
|
||||||
@@ -25,7 +27,7 @@ public class SPF_GetArrayDistributionOnlyAnalysis extends SapforAnalysis {
|
|||||||
@Override
|
@Override
|
||||||
protected void unpack(String packed) throws Exception {
|
protected void unpack(String packed) throws Exception {
|
||||||
RegionsJson regionsJson = Utils_.gson.fromJson(packed, RegionsJson.class);
|
RegionsJson regionsJson = Utils_.gson.fromJson(packed, RegionsJson.class);
|
||||||
for (ParallelRegion parallelRegion : regionsJson.allRegions) {
|
for (ParallelRegion parallelRegion: regionsJson.allRegions){
|
||||||
parallelRegion.Init();
|
parallelRegion.Init();
|
||||||
target.parallelRegions.put(parallelRegion.regionId, parallelRegion);
|
target.parallelRegions.put(parallelRegion.regionId, parallelRegion);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
package _VisualDVM.Passes.All;
|
package _VisualDVM.Passes.All;
|
||||||
|
import Common.Utils.Index;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
import _VisualDVM.Passes.Sapfor.SapforAnalysis;
|
import _VisualDVM.Passes.Sapfor.SapforAnalysis;
|
||||||
@@ -12,7 +13,7 @@ public class SPF_GetArrayDistributionOnlyRegions extends SapforAnalysis {
|
|||||||
@Override
|
@Override
|
||||||
protected void unpack(String packed) throws Exception {
|
protected void unpack(String packed) throws Exception {
|
||||||
RegionsJson regionsJson = Utils_.gson.fromJson(packed, RegionsJson.class);
|
RegionsJson regionsJson = Utils_.gson.fromJson(packed, RegionsJson.class);
|
||||||
for (ParallelRegion parallelRegion : regionsJson.allRegions) {
|
for (ParallelRegion parallelRegion: regionsJson.allRegions){
|
||||||
parallelRegion.Init();
|
parallelRegion.Init();
|
||||||
target.parallelRegions.put(parallelRegion.regionId, parallelRegion);
|
target.parallelRegions.put(parallelRegion.regionId, parallelRegion);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,13 +22,13 @@ public class SPF_GetArrayLinks extends SilentSapforPass {
|
|||||||
id_2|number_2|link_id1|link_id2|link_id3
|
id_2|number_2|link_id1|link_id2|link_id3
|
||||||
*/
|
*/
|
||||||
//эту инфу суем в список объявленных массивов, чтобы не плодить лишних таблиц.
|
//эту инфу суем в список объявленных массивов, чтобы не плодить лишних таблиц.
|
||||||
System.out.println("packed=" + Utils_.Brackets(packed));
|
System.out.println("packed="+ Utils_.Brackets(packed));
|
||||||
ProjectArray current_array = null;
|
ProjectArray current_array = null;
|
||||||
ArrayLinksJson links = Utils_.gson.fromJson(packed, ArrayLinksJson.class);
|
ArrayLinksJson links = Utils_.gson.fromJson(packed, ArrayLinksJson.class);
|
||||||
for (ArrayLinkJson link : links.allLinks) {
|
for (ArrayLinkJson link: links.allLinks){
|
||||||
current_array = target.declaratedArrays.get(link.id);
|
current_array = target.declaratedArrays.get(link.id);
|
||||||
current_array.links.clear();
|
current_array.links.clear();
|
||||||
for (long link_id : link.links) {
|
for (long link_id: link.links){
|
||||||
current_array.links.put(link_id, target.declaratedArrays.get(link_id));
|
current_array.links.put(link_id, target.declaratedArrays.get(link_id));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -55,16 +55,17 @@ public class SPF_GetGCovInfo extends SilentSapforPass {
|
|||||||
}
|
}
|
||||||
protected void unpack(String packed) throws Exception {
|
protected void unpack(String packed) throws Exception {
|
||||||
GCOVJson allJson = Utils_.gson.fromJson(packed, GCOVJson.class);
|
GCOVJson allJson = Utils_.gson.fromJson(packed, GCOVJson.class);
|
||||||
for (FileGCOVJson fileJson : allJson.allGCov) {
|
for (FileGCOVJson fileJson: allJson.allGCov){
|
||||||
fileJson.file = Utils_.toW(fileJson.file);
|
fileJson.file = Utils_.toW(fileJson.file);
|
||||||
//--
|
//--
|
||||||
DBProjectFile projectFile = target.db.files.get(fileJson.file);
|
DBProjectFile projectFile = target.db.files.get(fileJson.file);
|
||||||
for (LineGCOVJson lineJson : fileJson.lines) {
|
for (LineGCOVJson lineJson: fileJson.lines){
|
||||||
if (lineJson.line > 0) {
|
if (lineJson.line > 0) {
|
||||||
int v_line = lineJson.line - 1;
|
int v_line = lineJson.line - 1;
|
||||||
long v_execution = (lineJson.execution >= 0) ? lineJson.execution : 0;
|
long v_execution = (lineJson.execution >= 0) ? lineJson.execution : 0;
|
||||||
if (!projectFile.gcov_info.line_info.containsKey(v_line)) {
|
if (!projectFile.gcov_info.line_info.containsKey(v_line)) {
|
||||||
projectFile.gcov_info.add_line(v_line, v_execution);
|
projectFile.gcov_info.add_line(v_line, v_execution);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -44,9 +44,9 @@ public class SPF_GetIncludeDependencies extends SapforAnalysis {
|
|||||||
FileInfo fileInfo = new FileInfo(fileIncludesJson.file);
|
FileInfo fileInfo = new FileInfo(fileIncludesJson.file);
|
||||||
//---
|
//---
|
||||||
DBProjectFile file = target.db.files.get(fileIncludesJson.file);
|
DBProjectFile file = target.db.files.get(fileIncludesJson.file);
|
||||||
System.out.println("addicted file = " + Utils_.Brackets(fileIncludesJson.file));
|
System.out.println("addicted file = "+Utils_.Brackets(fileIncludesJson.file));
|
||||||
System.out.println("found dependencies :" + fileIncludesJson.includes.size());
|
System.out.println("found dependencies :"+fileIncludesJson.includes.size());
|
||||||
/// UI.Info("+");
|
/// UI.Info("+");
|
||||||
for (Include include : fileIncludesJson.includes) {
|
for (Include include : fileIncludesJson.includes) {
|
||||||
//--
|
//--
|
||||||
System.out.println(include.dependencyFileName);
|
System.out.println(include.dependencyFileName);
|
||||||
@@ -56,7 +56,7 @@ public class SPF_GetIncludeDependencies extends SapforAnalysis {
|
|||||||
fileInfo.dependencies.add(include);
|
fileInfo.dependencies.add(include);
|
||||||
if (!target.allIncludes.contains(include.dependencyFileName))
|
if (!target.allIncludes.contains(include.dependencyFileName))
|
||||||
target.allIncludes.add(include.dependencyFileName);
|
target.allIncludes.add(include.dependencyFileName);
|
||||||
if (target.db.files.containsKey(include.dependencyFileName)) {
|
if (target.db.files.containsKey(include.dependencyFileName)){
|
||||||
//- определение типов языков инклудов по файлу куда они цепляютс.
|
//- определение типов языков инклудов по файлу куда они цепляютс.
|
||||||
if (!file.dependencies.contains(include.dependencyFileName)) {
|
if (!file.dependencies.contains(include.dependencyFileName)) {
|
||||||
file.dependencies.add(include.dependencyFileName);
|
file.dependencies.add(include.dependencyFileName);
|
||||||
@@ -70,8 +70,9 @@ public class SPF_GetIncludeDependencies extends SapforAnalysis {
|
|||||||
if (Global.mainModule.HasFile() && Global.mainModule.getFile().name.equals(include_file.name))
|
if (Global.mainModule.HasFile() && Global.mainModule.getFile().name.equals(include_file.name))
|
||||||
update_current = true;
|
update_current = true;
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
System.out.println(Utils_.Brackets(include.dependencyFileName) + " не существует!");
|
}else {
|
||||||
|
System.out.println(Utils_.Brackets(include.dependencyFileName)+" не существует!");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//----
|
//----
|
||||||
@@ -89,7 +90,7 @@ public class SPF_GetIncludeDependencies extends SapforAnalysis {
|
|||||||
}
|
}
|
||||||
target.numAddicted += target.addictedFiles.size();
|
target.numAddicted += target.addictedFiles.size();
|
||||||
target.UpdateAddictedCount();
|
target.UpdateAddictedCount();
|
||||||
// UI.Info("unpack includes done");
|
// UI.Info("unpack includes done");
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected void showDone() throws Exception {
|
protected void showDone() throws Exception {
|
||||||
|
|||||||
@@ -6,6 +6,8 @@ import _VisualDVM.Passes.PassCode;
|
|||||||
import _VisualDVM.Passes.Sapfor.SapforTransformation;
|
import _VisualDVM.Passes.Sapfor.SapforTransformation;
|
||||||
import _VisualDVM.ProjectData.SapforData.Includes.Analysis.FileInfo;
|
import _VisualDVM.ProjectData.SapforData.Includes.Analysis.FileInfo;
|
||||||
import _VisualDVM.ProjectData.SapforData.Includes.Analysis.Include;
|
import _VisualDVM.ProjectData.SapforData.Includes.Analysis.Include;
|
||||||
|
import _VisualDVM.ProjectData.SapforData.Includes.Transformation.IncludeToInsertJson;
|
||||||
|
import _VisualDVM.ProjectData.SapforData.Includes.Transformation.IncludesToInsertJson;
|
||||||
|
|
||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
@@ -21,52 +23,26 @@ public class SPF_InsertIncludesPass extends SapforTransformation {
|
|||||||
Log.Writeln_("Не найдено файлов, имеющих зависимости по включению.");
|
Log.Writeln_("Не найдено файлов, имеющих зависимости по включению.");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
Vector<String> Result = new Vector<>();
|
IncludesToInsertJson includes = new IncludesToInsertJson();
|
||||||
for (FileInfo fileInfo : target.addictedFiles.values()) {
|
for (FileInfo fileInfo : target.addictedFiles.values()) {
|
||||||
Vector<Include> selected_children = fileInfo.dependencies.stream().filter(Selectable::isSelected).collect(Collectors.toCollection(Vector::new));
|
Vector<Include> selected_children = fileInfo.dependencies.stream().filter(Selectable::isSelected).collect(Collectors.toCollection(Vector::new));
|
||||||
if (!selected_children.isEmpty()) {
|
if (!selected_children.isEmpty())
|
||||||
Result.add(fileInfo.file);
|
for (Include di : selected_children)
|
||||||
Result.add(String.valueOf(selected_children.size()));
|
includes.allIncludes.add(new IncludeToInsertJson(di.dependencyFileName,fileInfo.file, di.line));
|
||||||
for (Include di : selected_children) {
|
|
||||||
Result.add(String.valueOf(di.line));
|
|
||||||
Result.add(di.dependencyFileName);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if (Result.isEmpty()) {
|
if (includes.allIncludes.isEmpty()) {
|
||||||
Log.Writeln_("Не отмечено ни одного заголовка для подстановки");
|
Log.Writeln_("Не отмечено ни одного заголовка для подстановки");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
Options = Utils_.toU(String.join("|", Result));
|
Options = Utils_.gson.toJson(includes);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
/*
|
|
||||||
if (super.canStart(args)) {
|
|
||||||
if (target.numAddicted <= 0) {
|
|
||||||
Log.Writeln_("Не найдено файлов, имеющих зависимости по включению.");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
IncludesToInsertJson includes = new IncludesToInsertJson();
|
|
||||||
for (FileInfo fileInfo : target.addictedFiles.values()) {
|
|
||||||
Vector<Include> selected_children = fileInfo.dependencies.stream().filter(Selectable::isSelected).collect(Collectors.toCollection(Vector::new));
|
|
||||||
if (!selected_children.isEmpty())
|
|
||||||
for (Include di : selected_children)
|
|
||||||
includes.allIncludes.add(new IncludeToInsertJson(di.dependencyFileName,fileInfo.file, di.line));
|
|
||||||
}
|
|
||||||
if (includes.allIncludes.isEmpty()) {
|
|
||||||
Log.Writeln_("Не отмечено ни одного заголовка для подстановки");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
Options = Utils_.gson.toJson(includes);
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
protected void FocusBeforeStart() {
|
protected void FocusBeforeStart() {
|
||||||
Global.mainModule.getUI().getMainWindow().getProjectWindow().FocusDependencies();
|
Global.mainModule.getUI().getMainWindow().getProjectWindow().FocusDependencies();
|
||||||
}
|
}
|
||||||
|
//test 2
|
||||||
|
//test 3
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +0,0 @@
|
|||||||
package _VisualDVM.Passes.All;
|
|
||||||
import _VisualDVM.Passes.Sapfor.SapforTransformation;
|
|
||||||
public class SPF_InsertPrivateArrayDirectives extends SapforTransformation {
|
|
||||||
}
|
|
||||||
@@ -58,7 +58,7 @@ public class SPF_ParseFilesWithOrder extends SapforAnalysis {
|
|||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected void unpackMessages() throws Exception {
|
protected void unpackMessages() throws Exception {
|
||||||
System.out.println("packed=" + sapfor.getOutputMessage());
|
System.out.println("packed="+sapfor.getOutputMessage());
|
||||||
for (DBProjectFile f : target.db.files.Data.values())
|
for (DBProjectFile f : target.db.files.Data.values())
|
||||||
if (f.isActive()) f.state = FileState.OK;
|
if (f.isActive()) f.state = FileState.OK;
|
||||||
super.unpackMessages();
|
super.unpackMessages();
|
||||||
@@ -67,7 +67,7 @@ public class SPF_ParseFilesWithOrder extends SapforAnalysis {
|
|||||||
badCount = 0;
|
badCount = 0;
|
||||||
for (DBProjectFile f : target.db.files.Data.values()) {
|
for (DBProjectFile f : target.db.files.Data.values()) {
|
||||||
if (f.isActive()) {
|
if (f.isActive()) {
|
||||||
System.out.println("file=" + f.name + ":" + f.state);
|
System.out.println("file="+f.name+":"+f.state);
|
||||||
switch (f.state) {
|
switch (f.state) {
|
||||||
case OK:
|
case OK:
|
||||||
case HasNotes:
|
case HasNotes:
|
||||||
@@ -105,7 +105,7 @@ public class SPF_ParseFilesWithOrder extends SapforAnalysis {
|
|||||||
@Override
|
@Override
|
||||||
protected void unpack(String packed) throws Exception {
|
protected void unpack(String packed) throws Exception {
|
||||||
FilesOrderJson filesOrderJson = Utils_.gson.fromJson(packed, FilesOrderJson.class);
|
FilesOrderJson filesOrderJson = Utils_.gson.fromJson(packed, FilesOrderJson.class);
|
||||||
for (String fileName_ : filesOrderJson.allFiles)
|
for (String fileName_ :filesOrderJson.allFiles)
|
||||||
target.files_order.add(Utils_.toW(fileName_));
|
target.files_order.add(Utils_.toW(fileName_));
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -3,7 +3,6 @@ import Common.MainModule_;
|
|||||||
import Common.Passes.Pass;
|
import Common.Passes.Pass;
|
||||||
import Common.Visual.Windows.Dialog.SliderNumberForm;
|
import Common.Visual.Windows.Dialog.SliderNumberForm;
|
||||||
import Common.Visual.Windows.Dialog.SpinnerNumberForm;
|
import Common.Visual.Windows.Dialog.SpinnerNumberForm;
|
||||||
import Common.Visual.Windows.Dialog.Text.TextFieldDialog;
|
|
||||||
import Common.Visual.Windows.Dialog.VDirectoryChooser;
|
import Common.Visual.Windows.Dialog.VDirectoryChooser;
|
||||||
import Common.Visual.Windows.Dialog.VFileChooser;
|
import Common.Visual.Windows.Dialog.VFileChooser;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
@@ -45,14 +44,6 @@ public class UpdateProperty extends Pass<Object> {
|
|||||||
if (file != null)
|
if (file != null)
|
||||||
newValue = file.getAbsolutePath();
|
newValue = file.getAbsolutePath();
|
||||||
break;
|
break;
|
||||||
case "PrecompilationFlags":
|
|
||||||
TextFieldDialog textFieldDialog = new TextFieldDialog();
|
|
||||||
if (textFieldDialog.ShowDialog(description, oldValue)) {
|
|
||||||
newValue = textFieldDialog.Result;
|
|
||||||
if (newValue.toString().isEmpty())
|
|
||||||
newValue = " ";
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case "BugReportsAgeLimit":
|
case "BugReportsAgeLimit":
|
||||||
if (sliderNumberForm.ShowDialog(description, oldValue, 1, 12))
|
if (sliderNumberForm.ShowDialog(description, oldValue, 1, 12))
|
||||||
newValue = sliderNumberForm.Result;
|
newValue = sliderNumberForm.Result;
|
||||||
|
|||||||
@@ -301,7 +301,6 @@ public enum PassCode implements PassCode_ {
|
|||||||
//->
|
//->
|
||||||
TestPass,
|
TestPass,
|
||||||
SPF_InsertPrivateFromGUI,
|
SPF_InsertPrivateFromGUI,
|
||||||
SPF_InsertPrivateArrayDirectives,
|
|
||||||
SPF_RemoveSpfDirectives,
|
SPF_RemoveSpfDirectives,
|
||||||
SPF_RemoveDeadCode,
|
SPF_RemoveDeadCode,
|
||||||
ReplaceTestProject,
|
ReplaceTestProject,
|
||||||
@@ -367,8 +366,6 @@ public enum PassCode implements PassCode_ {
|
|||||||
@Override
|
@Override
|
||||||
public String getDescription() {
|
public String getDescription() {
|
||||||
switch (this) {
|
switch (this) {
|
||||||
case SPF_InsertPrivateArrayDirectives:
|
|
||||||
return "Анализ и вставка директив приватизации массивов";
|
|
||||||
case CompareSapforPackageToEthalon:
|
case CompareSapforPackageToEthalon:
|
||||||
return "Сравнить пакет тестирования SAPFOR с эталоном";
|
return "Сравнить пакет тестирования SAPFOR с эталоном";
|
||||||
case SPF_RemoveSpfDirectives:
|
case SPF_RemoveSpfDirectives:
|
||||||
|
|||||||
@@ -257,8 +257,9 @@ public class DBProjectFile extends ProjectFile {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public void AddNewMessage(Message message) throws Exception {
|
|
||||||
switch (message.type) {
|
public void AddNewMessage(Message message) throws Exception{
|
||||||
|
switch (message.type){
|
||||||
case 0:
|
case 0:
|
||||||
MessageWarning warning = new MessageWarning(name, message.line, message.value, message.group);
|
MessageWarning warning = new MessageWarning(name, message.line, message.value, message.group);
|
||||||
father.db.Insert(warning);
|
father.db.Insert(warning);
|
||||||
@@ -281,6 +282,8 @@ public class DBProjectFile extends ProjectFile {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public DefaultMutableTreeNode show_loop_graph_r(FileObjectWithMessages element) {
|
public DefaultMutableTreeNode show_loop_graph_r(FileObjectWithMessages element) {
|
||||||
DefaultMutableTreeNode res = new DefaultMutableTreeNode(element);
|
DefaultMutableTreeNode res = new DefaultMutableTreeNode(element);
|
||||||
if (element instanceof Loop) {
|
if (element instanceof Loop) {
|
||||||
|
|||||||
@@ -26,6 +26,18 @@ public class Message extends iDBObject {
|
|||||||
//--
|
//--
|
||||||
@Description("DEFAULT ''")
|
@Description("DEFAULT ''")
|
||||||
public String file = "";
|
public String file = "";
|
||||||
|
public String getGroup_s() {
|
||||||
|
switch (group) {
|
||||||
|
case 0:
|
||||||
|
return "#m0000";
|
||||||
|
case Constants.parser_group: //сообщения от парсера.
|
||||||
|
return "#parser";
|
||||||
|
case Constants.compiler_group:
|
||||||
|
return "#compiler";
|
||||||
|
default:
|
||||||
|
return "#"+group;
|
||||||
|
}
|
||||||
|
}
|
||||||
//--
|
//--
|
||||||
public Message() {
|
public Message() {
|
||||||
}
|
}
|
||||||
@@ -33,7 +45,7 @@ public class Message extends iDBObject {
|
|||||||
) throws Exception {
|
) throws Exception {
|
||||||
file = file_in;
|
file = file_in;
|
||||||
line = line_in;
|
line = line_in;
|
||||||
group = group_in;
|
group=group_in;
|
||||||
if ((group == Constants.parser_group) ||
|
if ((group == Constants.parser_group) ||
|
||||||
(group == Constants.compiler_group) ||
|
(group == Constants.compiler_group) ||
|
||||||
(Global.mode != Mode.Normal)) {
|
(Global.mode != Mode.Normal)) {
|
||||||
@@ -443,16 +455,4 @@ public class Message extends iDBObject {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public String getGroup_s() {
|
|
||||||
switch (group) {
|
|
||||||
case 0:
|
|
||||||
return "#m0000";
|
|
||||||
case Constants.parser_group: //сообщения от парсера.
|
|
||||||
return "#parser";
|
|
||||||
case Constants.compiler_group:
|
|
||||||
return "#compiler";
|
|
||||||
default:
|
|
||||||
return "#" + group;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -39,6 +39,14 @@ public class AlignRule {
|
|||||||
alignRuleWith.add(new AlignRuleWidthJson(dimNum, a, b));
|
alignRuleWith.add(new AlignRuleWidthJson(dimNum, a, b));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
public void Init(){
|
||||||
|
//--
|
||||||
|
alignArray_address = new BigInteger(packedAlignArrayAddress);
|
||||||
|
alignWith_address = new BigInteger(packedAlignWithAddress);
|
||||||
|
//--
|
||||||
|
packedAlignArrayAddress = null;
|
||||||
|
packedAlignWithAddress = null;
|
||||||
|
}
|
||||||
private static Pair<String, String> convertDigitToPositive(int digit) {
|
private static Pair<String, String> convertDigitToPositive(int digit) {
|
||||||
String buf = "";
|
String buf = "";
|
||||||
String sign = " + ";
|
String sign = " + ";
|
||||||
@@ -50,14 +58,6 @@ public class AlignRule {
|
|||||||
buf += String.valueOf(digit);
|
buf += String.valueOf(digit);
|
||||||
return new Pair<>(sign, buf);
|
return new Pair<>(sign, buf);
|
||||||
}
|
}
|
||||||
public void Init() {
|
|
||||||
//--
|
|
||||||
alignArray_address = new BigInteger(packedAlignArrayAddress);
|
|
||||||
alignWith_address = new BigInteger(packedAlignWithAddress);
|
|
||||||
//--
|
|
||||||
packedAlignArrayAddress = null;
|
|
||||||
packedAlignWithAddress = null;
|
|
||||||
}
|
|
||||||
public ProjectArray getAlignArray() {
|
public ProjectArray getAlignArray() {
|
||||||
return parent_region.arraysMap.get(alignArray_address);
|
return parent_region.arraysMap.get(alignArray_address);
|
||||||
}
|
}
|
||||||
@@ -115,7 +115,7 @@ public class AlignRule {
|
|||||||
retVal += getAlignArray().TypeString() + " ";
|
retVal += getAlignArray().TypeString() + " ";
|
||||||
arrayString += getAlignArray().shortName + "(";
|
arrayString += getAlignArray().shortName + "(";
|
||||||
for (int i = 0; i < alignRule.size(); ++i) {
|
for (int i = 0; i < alignRule.size(); ++i) {
|
||||||
arrayString += genStringExpr(ProjectArray.alignNames[i], alignRule.get(i).getKey(), alignRule.get(i).getValue());
|
arrayString += genStringExpr(ProjectArray.alignNames[i], alignRule.get(i).getKey(),alignRule.get(i).getValue() );
|
||||||
if (i != alignRule.size() - 1)
|
if (i != alignRule.size() - 1)
|
||||||
arrayString += ",";
|
arrayString += ",";
|
||||||
}
|
}
|
||||||
@@ -142,7 +142,7 @@ public class AlignRule {
|
|||||||
for (int i = 0; i < alignRuleWith.size(); ++i) {
|
for (int i = 0; i < alignRuleWith.size(); ++i) {
|
||||||
if (alignRuleWith.get(i).getDimNum() != -1) {
|
if (alignRuleWith.get(i).getDimNum() != -1) {
|
||||||
alignEachDim.set(alignRuleWith.get(i).getDimNum(),
|
alignEachDim.set(alignRuleWith.get(i).getDimNum(),
|
||||||
genStringExpr(ProjectArray.alignNames[i], alignRuleWith.get(i).getA(), alignRuleWith.get(i).getB()));
|
genStringExpr(ProjectArray.alignNames[i], alignRuleWith.get(i).getA(),alignRuleWith.get(i).getB() ));
|
||||||
//коэццициенты находятся здесь!!------------------------------------------------------------------->>
|
//коэццициенты находятся здесь!!------------------------------------------------------------------->>
|
||||||
getAlignArray().ac_current.put(i,
|
getAlignArray().ac_current.put(i,
|
||||||
new Dimension(i,
|
new Dimension(i,
|
||||||
|
|||||||
@@ -7,21 +7,22 @@ public class AlignRuleWidthJson {
|
|||||||
public int a;
|
public int a;
|
||||||
@Expose
|
@Expose
|
||||||
public int b;
|
public int b;
|
||||||
public AlignRuleWidthJson() {
|
//dim -> a * dim_t + b
|
||||||
|
public int getDimNum(){
|
||||||
|
return dimNum;
|
||||||
}
|
}
|
||||||
public AlignRuleWidthJson(int i_in, int a_in, int b_in) {
|
public int getA(){
|
||||||
|
return a;
|
||||||
|
}
|
||||||
|
public int getB(){
|
||||||
|
return b;
|
||||||
|
}
|
||||||
|
public AlignRuleWidthJson(){
|
||||||
|
|
||||||
|
}
|
||||||
|
public AlignRuleWidthJson(int i_in, int a_in, int b_in){
|
||||||
dimNum = i_in;
|
dimNum = i_in;
|
||||||
a = a_in;
|
a = a_in;
|
||||||
b = b_in;
|
b = b_in;
|
||||||
}
|
}
|
||||||
//dim -> a * dim_t + b
|
|
||||||
public int getDimNum() {
|
|
||||||
return dimNum;
|
|
||||||
}
|
|
||||||
public int getA() {
|
|
||||||
return a;
|
|
||||||
}
|
|
||||||
public int getB() {
|
|
||||||
return b;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,5 +5,5 @@ import java.util.List;
|
|||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
public class ArraysJson {
|
public class ArraysJson {
|
||||||
@Expose
|
@Expose
|
||||||
public List<ProjectArray> allArrays = new Vector<>();
|
public List<ProjectArray> allArrays=new Vector<>();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,12 +1,15 @@
|
|||||||
package _VisualDVM.ProjectData.SapforData.Arrays;
|
package _VisualDVM.ProjectData.SapforData.Arrays;
|
||||||
import Common.Database.Objects.DBObject;
|
import Common.Database.Objects.DBObject;
|
||||||
|
import Common.Utils.Index;
|
||||||
import Common.Utils.IntegerPairJson;
|
import Common.Utils.IntegerPairJson;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
import _VisualDVM.Passes.PassCode;
|
import _VisualDVM.Passes.PassCode;
|
||||||
import _VisualDVM.ProjectData.DBArray.DBArray;
|
import _VisualDVM.ProjectData.DBArray.DBArray;
|
||||||
|
import _VisualDVM.ProjectData.Files.DBProjectFile;
|
||||||
import _VisualDVM.ProjectData.SapforData.Arrays.Templates.TemplateDimension;
|
import _VisualDVM.ProjectData.SapforData.Arrays.Templates.TemplateDimension;
|
||||||
import _VisualDVM.ProjectData.SapforData.Arrays.Templates.TemplateDimensionState;
|
import _VisualDVM.ProjectData.SapforData.Arrays.Templates.TemplateDimensionState;
|
||||||
|
import _VisualDVM.ProjectData.SapforData.Arrays.Templates.TemplateLink;
|
||||||
import _VisualDVM.ProjectData.SapforData.Regions.ParallelRegion;
|
import _VisualDVM.ProjectData.SapforData.Regions.ParallelRegion;
|
||||||
import _VisualDVM.ProjectData.SapforData.Regions.UI.ArrayAlignmentBar;
|
import _VisualDVM.ProjectData.SapforData.Regions.UI.ArrayAlignmentBar;
|
||||||
import com.google.gson.annotations.Expose;
|
import com.google.gson.annotations.Expose;
|
||||||
@@ -18,9 +21,6 @@ import java.util.List;
|
|||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
public class ProjectArray extends DBObject {
|
public class ProjectArray extends DBObject {
|
||||||
//--
|
|
||||||
//----------------------------------------------------------------------
|
|
||||||
public static final String[] alignNames = {"i", "j", "k", "l", "m", "n", "q", "r", "s", "t", "u", "w", "x", "y", "z"};
|
|
||||||
@Expose
|
@Expose
|
||||||
public long id;
|
public long id;
|
||||||
@Expose
|
@Expose
|
||||||
@@ -34,6 +34,10 @@ public class ProjectArray extends DBObject {
|
|||||||
@Expose
|
@Expose
|
||||||
public int typeSize;
|
public int typeSize;
|
||||||
@Expose
|
@Expose
|
||||||
|
int state;
|
||||||
|
@Expose
|
||||||
|
int location;
|
||||||
|
@Expose
|
||||||
public String locName;
|
public String locName;
|
||||||
@Expose
|
@Expose
|
||||||
public int isTemplFlag;
|
public int isTemplFlag;
|
||||||
@@ -41,6 +45,17 @@ public class ProjectArray extends DBObject {
|
|||||||
public int isLoopArrayFlag;
|
public int isLoopArrayFlag;
|
||||||
@Expose
|
@Expose
|
||||||
public Vector<ArrayDecl> declPlaces = new Vector<>();
|
public Vector<ArrayDecl> declPlaces = new Vector<>();
|
||||||
|
@Expose
|
||||||
|
List<Integer> deprecateToDist = new Vector<>();
|
||||||
|
@Expose
|
||||||
|
List<Integer> mappedDims = new Vector<>();
|
||||||
|
@Expose
|
||||||
|
Vector<IntegerPairJson> sizes = new Vector<>();
|
||||||
|
@Expose
|
||||||
|
Vector<String> regions = new Vector<>();
|
||||||
|
//--
|
||||||
|
//----------------------------------------------------------------------
|
||||||
|
public static final String[] alignNames = {"i", "j", "k", "l", "m", "n", "q", "r", "s", "t", "u", "w", "x", "y", "z"};
|
||||||
public String UniqKey;
|
public String UniqKey;
|
||||||
public BigInteger address;
|
public BigInteger address;
|
||||||
//только для шаблонов. для ФИЛЬТРА управления распределением измерений.
|
//только для шаблонов. для ФИЛЬТРА управления распределением измерений.
|
||||||
@@ -58,33 +73,6 @@ public class ProjectArray extends DBObject {
|
|||||||
public LinkedHashMap<Integer, Dimension> ac_new;
|
public LinkedHashMap<Integer, Dimension> ac_new;
|
||||||
//https://stackoverflow.com/questions/4941372/how-to-insert-image-into-jtable-cell
|
//https://stackoverflow.com/questions/4941372/how-to-insert-image-into-jtable-cell
|
||||||
public ArrayAlignmentBar bar = null;
|
public ArrayAlignmentBar bar = null;
|
||||||
@Expose
|
|
||||||
int state;
|
|
||||||
@Expose
|
|
||||||
int location;
|
|
||||||
@Expose
|
|
||||||
List<Integer> deprecateToDist = new Vector<>();
|
|
||||||
@Expose
|
|
||||||
List<Integer> mappedDims = new Vector<>();
|
|
||||||
@Expose
|
|
||||||
Vector<IntegerPairJson> sizes = new Vector<>();
|
|
||||||
@Expose
|
|
||||||
Vector<String> regions = new Vector<>();
|
|
||||||
public static String fill_binary(int d, String binary) {
|
|
||||||
int delta = Math.abs(binary.length() - d);
|
|
||||||
String res = binary;
|
|
||||||
for (int i = 0; i < delta; ++i) {
|
|
||||||
res = ("0" + res);
|
|
||||||
}
|
|
||||||
return res;
|
|
||||||
}
|
|
||||||
//длина должна быть равной, ищем есть ли совпадающие позиции с единицами
|
|
||||||
public static boolean mask(String banned, String variant) {
|
|
||||||
for (int i = 0; i < variant.length(); ++i)
|
|
||||||
if ((variant.toCharArray()[i] == '1') && (banned.toCharArray()[i] == '1')) //попался, масконосец!
|
|
||||||
return true;
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
//------
|
//------
|
||||||
public void print() {
|
public void print() {
|
||||||
Vector<String> res = new Vector<>();
|
Vector<String> res = new Vector<>();
|
||||||
@@ -131,6 +119,21 @@ public class ProjectArray extends DBObject {
|
|||||||
ac_new = new LinkedHashMap<>();
|
ac_new = new LinkedHashMap<>();
|
||||||
//--FileForm
|
//--FileForm
|
||||||
}
|
}
|
||||||
|
public static String fill_binary(int d, String binary) {
|
||||||
|
int delta = Math.abs(binary.length() - d);
|
||||||
|
String res = binary;
|
||||||
|
for (int i = 0; i < delta; ++i) {
|
||||||
|
res = ("0" + res);
|
||||||
|
}
|
||||||
|
return res;
|
||||||
|
}
|
||||||
|
//длина должна быть равной, ищем есть ли совпадающие позиции с единицами
|
||||||
|
public static boolean mask(String banned, String variant) {
|
||||||
|
for (int i = 0; i < variant.length(); ++i)
|
||||||
|
if ((variant.toCharArray()[i] == '1') && (banned.toCharArray()[i] == '1')) //попался, масконосец!
|
||||||
|
return true;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
public String printLinks() {
|
public String printLinks() {
|
||||||
Vector<String> res = links.keySet().stream().map(Object::toString).collect(Collectors.toCollection(Vector::new));
|
Vector<String> res = links.keySet().stream().map(Object::toString).collect(Collectors.toCollection(Vector::new));
|
||||||
return String.join(" ", res);
|
return String.join(" ", res);
|
||||||
|
|||||||
@@ -5,5 +5,5 @@ import java.util.List;
|
|||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
public class GCOVJson {
|
public class GCOVJson {
|
||||||
@Expose
|
@Expose
|
||||||
public List<FileGCOVJson> allGCov = new Vector<>();
|
public List<FileGCOVJson> allGCov= new Vector<>();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
package _VisualDVM.ProjectData.SapforData.Includes.Analysis;
|
package _VisualDVM.ProjectData.SapforData.Includes.Analysis;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
import _VisualDVM.ProjectData.SapforData.FileObject;
|
import _VisualDVM.ProjectData.SapforData.FileObject;
|
||||||
|
import _VisualDVM.ProjectData.SapforData.Includes.Analysis.Include;
|
||||||
import com.google.gson.annotations.Expose;
|
import com.google.gson.annotations.Expose;
|
||||||
|
|
||||||
import javax.swing.*;
|
import javax.swing.*;
|
||||||
|
|||||||
@@ -1,8 +0,0 @@
|
|||||||
package _VisualDVM.ProjectData.SapforData;
|
|
||||||
import com.google.gson.annotations.Expose;
|
|
||||||
public class ModifiedFile_json {
|
|
||||||
@Expose
|
|
||||||
public String name;
|
|
||||||
@Expose
|
|
||||||
public String text;
|
|
||||||
}
|
|
||||||
@@ -1,8 +1,10 @@
|
|||||||
package _VisualDVM.ProjectData.SapforData.Regions;
|
package _VisualDVM.ProjectData.SapforData.Regions;
|
||||||
import Common.Database.Objects.DBObject;
|
import Common.Database.Objects.DBObject;
|
||||||
|
import Common.Utils.Index;
|
||||||
import Common.Utils.IntegerPairJson;
|
import Common.Utils.IntegerPairJson;
|
||||||
import Common.Utils.Pair;
|
import Common.Utils.Pair;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
|
import Common.Visual.UI;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
import _VisualDVM.ProjectData.Files.DBProjectFile;
|
import _VisualDVM.ProjectData.Files.DBProjectFile;
|
||||||
import _VisualDVM.ProjectData.SapforData.Arrays.AlignRule;
|
import _VisualDVM.ProjectData.SapforData.Arrays.AlignRule;
|
||||||
@@ -28,21 +30,6 @@ public class ParallelRegion extends DBObject {
|
|||||||
public Vector<AlignRule> alignRules;
|
public Vector<AlignRule> alignRules;
|
||||||
//----
|
//----
|
||||||
public Vector<String> rules;
|
public Vector<String> rules;
|
||||||
//--
|
|
||||||
public BigInteger regionId;
|
|
||||||
//name in program
|
|
||||||
// file -> <start, end> lines
|
|
||||||
public LinkedHashMap<String, List<IntegerPairJson>> lines; //+
|
|
||||||
//ключ - адрес. меняем
|
|
||||||
public LinkedHashMap<BigInteger, ProjectArray> arraysMap; //+
|
|
||||||
//for directive creating
|
|
||||||
public int maxdim = 0;
|
|
||||||
public Vector<String> fragments; //+
|
|
||||||
public int lines_count = 0;
|
|
||||||
public int loops_count = 0;
|
|
||||||
public int arrays_count = 0;
|
|
||||||
public int fd_count = 0;
|
|
||||||
public int fc_count = 0;
|
|
||||||
public void genRules(LinkedHashMap<BigInteger, ProjectArray> Arrays) {
|
public void genRules(LinkedHashMap<BigInteger, ProjectArray> Arrays) {
|
||||||
rules.clear();
|
rules.clear();
|
||||||
int maxLen = 0;
|
int maxLen = 0;
|
||||||
@@ -61,11 +48,26 @@ public class ParallelRegion extends DBObject {
|
|||||||
for (String r : v)
|
for (String r : v)
|
||||||
rules.add(r);
|
rules.add(r);
|
||||||
}
|
}
|
||||||
|
//--
|
||||||
|
public BigInteger regionId;
|
||||||
|
//name in program
|
||||||
|
// file -> <start, end> lines
|
||||||
|
public LinkedHashMap<String, List<IntegerPairJson>> lines; //+
|
||||||
|
//ключ - адрес. меняем
|
||||||
|
public LinkedHashMap<BigInteger, ProjectArray> arraysMap; //+
|
||||||
|
//for directive creating
|
||||||
|
public int maxdim = 0;
|
||||||
|
public Vector<String> fragments; //+
|
||||||
|
public int lines_count = 0;
|
||||||
|
public int loops_count = 0;
|
||||||
|
public int arrays_count = 0;
|
||||||
|
public int fd_count = 0;
|
||||||
|
public int fc_count = 0;
|
||||||
public void Init() {
|
public void Init() {
|
||||||
arraysMap = new LinkedHashMap<>();
|
arraysMap = new LinkedHashMap<>();
|
||||||
lines = new LinkedHashMap<>();
|
lines = new LinkedHashMap<>();
|
||||||
fragments = new Vector<>();
|
fragments = new Vector<>();
|
||||||
rules = new Vector<>();
|
rules=new Vector<>();
|
||||||
//--
|
//--
|
||||||
if (packedRegionId != null)
|
if (packedRegionId != null)
|
||||||
regionId = new BigInteger(packedRegionId);
|
regionId = new BigInteger(packedRegionId);
|
||||||
@@ -73,20 +75,19 @@ public class ParallelRegion extends DBObject {
|
|||||||
for (ProjectArray array : packedArrays) {
|
for (ProjectArray array : packedArrays) {
|
||||||
array.Init();//имена и адреса.
|
array.Init();//имена и адреса.
|
||||||
arraysMap.put(array.address, array);
|
arraysMap.put(array.address, array);
|
||||||
if (array.isTemplFlag == 1) {
|
if (array.isTemplFlag==1){
|
||||||
maxdim = Math.max(maxdim, array.dimSize);
|
maxdim = Math.max(maxdim, array.dimSize);
|
||||||
Global.mainModule.getProject().templates.add(array);
|
Global.mainModule.getProject().templates.add(array);
|
||||||
array.regIDs.add(regionId);
|
array.regIDs.add(regionId);
|
||||||
} else if (array.isLoopArrayFlag != 1) arrays_count++;
|
} else if (array.isLoopArrayFlag != 1) arrays_count++;
|
||||||
}
|
}
|
||||||
//---
|
//---
|
||||||
for (AlignRule rule : alignRules) {
|
for (AlignRule rule: alignRules) {
|
||||||
rule.Init();
|
rule.Init();
|
||||||
rule.parent_region = this;
|
rule.parent_region = this;
|
||||||
}
|
}
|
||||||
//---
|
//---
|
||||||
for (FileRegionLinesJson fr : regionsLines) {
|
for (FileRegionLinesJson fr : regionsLines) {
|
||||||
fr.file = Utils_.toW(fr.file);
|
|
||||||
lines.put(fr.file, fr.lines);
|
lines.put(fr.file, fr.lines);
|
||||||
for (IntegerPairJson l : fr.lines) {
|
for (IntegerPairJson l : fr.lines) {
|
||||||
fragments.add(fr.file + ": " + l.getKey() + "-" + l.getKey());
|
fragments.add(fr.file + ": " + l.getKey() + "-" + l.getKey());
|
||||||
@@ -102,7 +103,6 @@ public class ParallelRegion extends DBObject {
|
|||||||
for (IntegerPairJson L : lines.get(FKey)) {
|
for (IntegerPairJson L : lines.get(FKey)) {
|
||||||
lines_count += (L.getValue() - L.getKey());
|
lines_count += (L.getValue() - L.getKey());
|
||||||
DBProjectFile f = Global.mainModule.getProject().db.files.Data.get(FKey);
|
DBProjectFile f = Global.mainModule.getProject().db.files.Data.get(FKey);
|
||||||
|
|
||||||
loops_count += f.FragmentLoopCount(L.getKey(), L.getValue());
|
loops_count += f.FragmentLoopCount(L.getKey(), L.getValue());
|
||||||
fc_count += f.FragmentFunctionCallsCount(L.getKey(), L.getValue());
|
fc_count += f.FragmentFunctionCallsCount(L.getKey(), L.getValue());
|
||||||
fd_count += f.FragmentFunctionDeclsCount(L.getKey(), L.getValue());
|
fd_count += f.FragmentFunctionDeclsCount(L.getKey(), L.getValue());
|
||||||
|
|||||||
@@ -1,28 +0,0 @@
|
|||||||
package _VisualDVM.ProjectData.SapforData;
|
|
||||||
import com.google.gson.annotations.Expose;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
public class SapforResult_json {
|
|
||||||
@Expose
|
|
||||||
public int errorCode;
|
|
||||||
@Expose
|
|
||||||
public String result; //запаковка результата конкретного прохода в json
|
|
||||||
@Expose
|
|
||||||
public String output; //журнал
|
|
||||||
@Expose
|
|
||||||
public String outputMessage; //запаковка сообщений в json
|
|
||||||
@Expose
|
|
||||||
public String predictorStats; //запаковка оценок вариантов в json если есть для их построения и оценки.
|
|
||||||
@Expose
|
|
||||||
public List<ModifiedFile_json> files; //запаковка имен файлов в json если есть для модификации
|
|
||||||
//--
|
|
||||||
public void Print(){
|
|
||||||
System.out.println("------------------------------");
|
|
||||||
System.out.println("codeIdx="+ errorCode );
|
|
||||||
System.out.println("result="+result);
|
|
||||||
System.out.println("output="+output);
|
|
||||||
System.out.println("outputMessage="+outputMessage);
|
|
||||||
System.out.println("predictorStats="+predictorStats);
|
|
||||||
System.out.println("-------------------------------");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -673,7 +673,7 @@ public class TestsDatabase extends SQLiteDatabase {
|
|||||||
Vector<DVMCompilationOptionsSet> optionsSets = getVectorByFK(dvmSettings_in, DVMCompilationOptionsSet.class);
|
Vector<DVMCompilationOptionsSet> optionsSets = getVectorByFK(dvmSettings_in, DVMCompilationOptionsSet.class);
|
||||||
Vector<DVMEnvironmentsSet> environmentsSets = getVectorByFK(dvmSettings_in, DVMEnvironmentsSet.class);
|
Vector<DVMEnvironmentsSet> environmentsSets = getVectorByFK(dvmSettings_in, DVMEnvironmentsSet.class);
|
||||||
//----
|
//----
|
||||||
if (optionsSets.isEmpty() && environmentsSets.isEmpty()) {
|
if (optionsSets.isEmpty() && environmentsSets.isEmpty()){
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
int size_ = Math.min(optionsSets.size(), environmentsSets.size());
|
int size_ = Math.min(optionsSets.size(), environmentsSets.size());
|
||||||
@@ -687,14 +687,14 @@ public class TestsDatabase extends SQLiteDatabase {
|
|||||||
environmentsLine));
|
environmentsLine));
|
||||||
}
|
}
|
||||||
//дополнения
|
//дополнения
|
||||||
if (optionsSets.size() < environmentsSets.size()) {
|
if (optionsSets.size()<environmentsSets.size()){
|
||||||
for (int i = optionsSets.size(); i < environmentsSets.size(); ++i) {
|
for (int i = optionsSets.size(); i < environmentsSets.size(); ++i) {
|
||||||
res.add(new Pair<>(
|
res.add(new Pair<>(
|
||||||
"",
|
"",
|
||||||
printEnvironmentsLine(getVectorByFK(environmentsSets.get(i), DVMEnvironment.class))
|
printEnvironmentsLine(getVectorByFK(environmentsSets.get(i), DVMEnvironment.class))
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
} else {
|
}else {
|
||||||
if (optionsSets.size() > environmentsSets.size()) {
|
if (optionsSets.size() > environmentsSets.size()) {
|
||||||
for (int i = environmentsSets.size(); i < optionsSets.size(); ++i) {
|
for (int i = environmentsSets.size(); i < optionsSets.size(); ++i) {
|
||||||
res.add(new Pair<>(
|
res.add(new Pair<>(
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
package _VisualDVM.TestingSystem.SAPFOR.Json;
|
package _VisualDVM.TestingSystem.SAPFOR.Json;
|
||||||
|
import Common.CommonConstants;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
import _VisualDVM.ComponentsServer.Component.Sapfor.Sapfor;
|
import _VisualDVM.ComponentsServer.Component.Sapfor.Sapfor;
|
||||||
import _VisualDVM.Constants;
|
import _VisualDVM.Constants;
|
||||||
@@ -6,11 +7,13 @@ import _VisualDVM.ProjectData.Files.DBProjectFile;
|
|||||||
import _VisualDVM.ProjectData.Files.FileType;
|
import _VisualDVM.ProjectData.Files.FileType;
|
||||||
import _VisualDVM.ProjectData.Files.ProjectFile;
|
import _VisualDVM.ProjectData.Files.ProjectFile;
|
||||||
import _VisualDVM.ProjectData.LanguageName;
|
import _VisualDVM.ProjectData.LanguageName;
|
||||||
|
import _VisualDVM.ProjectData.Messages.Errors.MessageError;
|
||||||
import _VisualDVM.ProjectData.Messages.FileMessagesJson;
|
import _VisualDVM.ProjectData.Messages.FileMessagesJson;
|
||||||
import _VisualDVM.ProjectData.Messages.Message;
|
import _VisualDVM.ProjectData.Messages.Message;
|
||||||
import _VisualDVM.ProjectData.Messages.MessagesJson;
|
import _VisualDVM.ProjectData.Messages.MessagesJson;
|
||||||
import _VisualDVM.ProjectData.Project.db_project_info;
|
import _VisualDVM.ProjectData.Project.db_project_info;
|
||||||
import _VisualDVM.TestingSystem.SAPFOR.SapforTask.SapforTask;
|
import _VisualDVM.TestingSystem.SAPFOR.SapforTask.SapforTask;
|
||||||
|
import _VisualDVM.Utils;
|
||||||
import com.google.gson.annotations.Expose;
|
import com.google.gson.annotations.Expose;
|
||||||
import org.apache.commons.io.FileUtils;
|
import org.apache.commons.io.FileUtils;
|
||||||
|
|
||||||
@@ -20,6 +23,8 @@ import java.nio.charset.Charset;
|
|||||||
import java.nio.file.Paths;
|
import java.nio.file.Paths;
|
||||||
import java.util.LinkedHashMap;
|
import java.util.LinkedHashMap;
|
||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
|
|
||||||
|
import static java.lang.Character.isDigit;
|
||||||
public class SapforVersion_json implements Serializable {
|
public class SapforVersion_json implements Serializable {
|
||||||
@Expose
|
@Expose
|
||||||
public String version = "";
|
public String version = "";
|
||||||
@@ -150,8 +155,41 @@ public class SapforVersion_json implements Serializable {
|
|||||||
} catch (Exception ex) {
|
} catch (Exception ex) {
|
||||||
ex.printStackTrace();
|
ex.printStackTrace();
|
||||||
}
|
}
|
||||||
if (!text1.equalsIgnoreCase(text2))
|
if (!Utils.compareFortranTexts(text1, text2)) {
|
||||||
return false;
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
public boolean isMatchServer(SapforVersion_json version_json) {
|
||||||
|
if (!description.equals(version_json.description)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (files.size() != version_json.files.size()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
for (String name1 : files.keySet()) {
|
||||||
|
if (!version_json.files.containsKey(name1)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
for (String name1 : files.keySet()) {
|
||||||
|
ProjectFile file1 = files.get(name1);
|
||||||
|
ProjectFile file2 = version_json.files.get(name1);
|
||||||
|
//---
|
||||||
|
String text1 = "";
|
||||||
|
String text2 = "";
|
||||||
|
try {
|
||||||
|
text1 = FileUtils.readFileToString(file1.file, Charset.defaultCharset());
|
||||||
|
} catch (Exception ex) {
|
||||||
|
ex.printStackTrace();
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
text2 = FileUtils.readFileToString(file2.file, Charset.defaultCharset());
|
||||||
|
} catch (Exception ex) {
|
||||||
|
ex.printStackTrace();
|
||||||
|
}
|
||||||
|
return text1.equalsIgnoreCase(text2);
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -191,25 +229,26 @@ public class SapforVersion_json implements Serializable {
|
|||||||
if (err.exists())
|
if (err.exists())
|
||||||
project.Log += "\n" + FileUtils.readFileToString(err);
|
project.Log += "\n" + FileUtils.readFileToString(err);
|
||||||
//--
|
//--
|
||||||
if (messages_dump.exists()) {
|
if (messages_dump.exists()){
|
||||||
try {
|
try {
|
||||||
String packed = FileUtils.readFileToString(messages_dump);
|
String packed = FileUtils.readFileToString(messages_dump);
|
||||||
messagesJson = Utils_.gson.fromJson(packed, MessagesJson.class);
|
messagesJson = Utils_.gson.fromJson(packed, MessagesJson.class);
|
||||||
} catch (Exception ex) {
|
}
|
||||||
|
catch (Exception ex){
|
||||||
ex.printStackTrace();
|
ex.printStackTrace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
project.Open();
|
project.Open();
|
||||||
project.Update(); //Журнал
|
project.Update(); //Журнал
|
||||||
//а так же, убрать dep и txt
|
//а так же, убрать dep и txt
|
||||||
if (messagesJson != null) {
|
if (messagesJson!=null){
|
||||||
project.db.BeginTransaction();
|
project.db.BeginTransaction();
|
||||||
//-
|
//-
|
||||||
for (FileMessagesJson fileMessagesJson : messagesJson.allMessages) {
|
for (FileMessagesJson fileMessagesJson: messagesJson.allMessages){
|
||||||
fileMessagesJson.file = Utils_.toW(fileMessagesJson.file);
|
fileMessagesJson.file = Utils_.toW(fileMessagesJson.file);
|
||||||
//--
|
//--
|
||||||
DBProjectFile file = project.db.files.Data.get(fileMessagesJson.file);
|
DBProjectFile file = project.db.files.Data.get(fileMessagesJson.file);
|
||||||
for (Message message : fileMessagesJson.messages) {
|
for (Message message: fileMessagesJson.messages) {
|
||||||
file.CreateAndAddNewMessage(1, message.value, message.line, message.group);
|
file.CreateAndAddNewMessage(1, message.value, message.line, message.group);
|
||||||
}
|
}
|
||||||
//update file
|
//update file
|
||||||
|
|||||||
@@ -178,6 +178,46 @@ public class SapforTask extends DBObject {
|
|||||||
task2.comparisonState = ComparisonState.Match;
|
task2.comparisonState = ComparisonState.Match;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
public void checkMatchServer(SapforTask task2) {
|
||||||
|
if (!state.equals(task2.state)) {
|
||||||
|
comparisonState = ComparisonState.NotMatch;
|
||||||
|
task2.comparisonState = ComparisonState.NotMatch;
|
||||||
|
}
|
||||||
|
if ((versions.size() != task2.versions.size()) || (variants.size() != task2.variants.size())) {
|
||||||
|
comparisonState = ComparisonState.NotMatch;
|
||||||
|
task2.comparisonState = ComparisonState.NotMatch;
|
||||||
|
}
|
||||||
|
LinkedHashMap<String, SapforVersion_json> versions1 = getSortedVersions();
|
||||||
|
LinkedHashMap<String, SapforVersion_json> versions2 = task2.getSortedVersions();
|
||||||
|
//---
|
||||||
|
for (String name1 : versions1.keySet()) {
|
||||||
|
if (versions2.containsKey(name1)) {
|
||||||
|
SapforVersion_json version1 = versions1.get(name1);
|
||||||
|
SapforVersion_json version2 = versions2.get(name1);
|
||||||
|
//---
|
||||||
|
if (!version1.isMatchServer(version2)) {
|
||||||
|
comparisonState = ComparisonState.NotMatch;
|
||||||
|
task2.comparisonState = ComparisonState.NotMatch;
|
||||||
|
version1.comparisonState = VersionComparisonState.NotMatch;
|
||||||
|
version2.comparisonState = VersionComparisonState.NotMatch;
|
||||||
|
//-
|
||||||
|
} else {
|
||||||
|
version1.comparisonState = VersionComparisonState.Match;
|
||||||
|
version2.comparisonState = VersionComparisonState.Match;
|
||||||
|
//-
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
comparisonState = ComparisonState.NotMatch;
|
||||||
|
task2.comparisonState = ComparisonState.NotMatch;
|
||||||
|
//--
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//--
|
||||||
|
if (comparisonState.equals(ComparisonState.Unknown)) {
|
||||||
|
comparisonState = ComparisonState.Match;
|
||||||
|
task2.comparisonState = ComparisonState.Match;
|
||||||
|
}
|
||||||
|
}
|
||||||
public Date getStartDate() {
|
public Date getStartDate() {
|
||||||
return new Date(StartDate);
|
return new Date(StartDate);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -187,7 +187,7 @@ public class SapforTestingPlanner extends TestingPlanner<SapforPackage> {
|
|||||||
//--
|
//--
|
||||||
for (SapforTask task1 : ethalon.package_json.tasks) {
|
for (SapforTask task1 : ethalon.package_json.tasks) {
|
||||||
SapforTask task2 = testingPackage.package_json.getTaskByKey(task1.getUniqueKey());
|
SapforTask task2 = testingPackage.package_json.getTaskByKey(task1.getUniqueKey());
|
||||||
task1.checkMatch(task2); //тексты сравниваются просто посимвольно.
|
task1.checkMatchServer(task2); //тексты сравниваются просто посимвольно.
|
||||||
if (task1.comparisonState.equals(ComparisonState.NotMatch)) {
|
if (task1.comparisonState.equals(ComparisonState.NotMatch)) {
|
||||||
testingPackage.mismatchesCount++;
|
testingPackage.mismatchesCount++;
|
||||||
}
|
}
|
||||||
@@ -195,7 +195,7 @@ public class SapforTestingPlanner extends TestingPlanner<SapforPackage> {
|
|||||||
Print("сравнение завершено");
|
Print("сравнение завершено");
|
||||||
log.Writeln_("Различий с эталоном: " + testingPackage.mismatchesCount);
|
log.Writeln_("Различий с эталоном: " + testingPackage.mismatchesCount);
|
||||||
if (testingPackage.mismatchesCount > 0) {
|
if (testingPackage.mismatchesCount > 0) {
|
||||||
// testingPackage.doneTasksCount -= testingPackage.mismatchesCount;
|
// testingPackage.doneTasksCount -= testingPackage.mismatchesCount;
|
||||||
testingPackage.state = TasksPackageState.DoneWithErrors;
|
testingPackage.state = TasksPackageState.DoneWithErrors;
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
|
|||||||
@@ -597,7 +597,6 @@ public class Utils {
|
|||||||
ex.printStackTrace();
|
ex.printStackTrace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/*
|
|
||||||
public static Pair<Vector<String>, Vector<String>> getFortranLines(String text) {
|
public static Pair<Vector<String>, Vector<String>> getFortranLines(String text) {
|
||||||
Vector<String> lines = new Vector<>();
|
Vector<String> lines = new Vector<>();
|
||||||
Vector<String> visible_lines = new Vector<>();
|
Vector<String> visible_lines = new Vector<>();
|
||||||
@@ -675,8 +674,6 @@ public class Utils {
|
|||||||
}
|
}
|
||||||
return new Pair<>(lines, visible_lines);
|
return new Pair<>(lines, visible_lines);
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
/* Pair
|
|
||||||
public static boolean CompareLines(String line1_raw, String line2_raw) {
|
public static boolean CompareLines(String line1_raw, String line2_raw) {
|
||||||
String line1 = line1_raw;
|
String line1 = line1_raw;
|
||||||
String line2 = line2_raw;
|
String line2 = line2_raw;
|
||||||
@@ -696,7 +693,19 @@ public class Utils {
|
|||||||
if (CompareLines(list.get(i), line)) last_index = i;
|
if (CompareLines(list.get(i), line)) last_index = i;
|
||||||
return (last_index >= max_index);
|
return (last_index >= max_index);
|
||||||
}
|
}
|
||||||
*/
|
public static boolean compareFortranTexts(String text1, String text2) {
|
||||||
|
Pair<Vector<String>, Vector<String>> p1 = getFortranLines(text1);
|
||||||
|
Pair<Vector<String>, Vector<String>> p2 = getFortranLines(text2);
|
||||||
|
Vector<String> lines1 = p1.getKey();
|
||||||
|
Vector<String> lines2 = p2.getKey();
|
||||||
|
if (lines1.size() != lines2.size())
|
||||||
|
return false;
|
||||||
|
for (int i = 0; i < lines1.size(); ++i) {
|
||||||
|
if (!CompareLines(lines1.get(i), lines2.get(i)))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
//--
|
//--
|
||||||
private static void get_newest_file_date_r(File dir, Vector<Long> dates) {
|
private static void get_newest_file_date_r(File dir, Vector<Long> dates) {
|
||||||
Vector<File> files = new Vector(Arrays.asList(dir.listFiles(new FileFilter() {
|
Vector<File> files = new Vector(Arrays.asList(dir.listFiles(new FileFilter() {
|
||||||
|
|||||||
@@ -18,13 +18,11 @@ public class VisualiserSettingsMenu extends VisualiserMenu {
|
|||||||
add(new PropertiesSubmenu("Компиляция на локальной машине", null,
|
add(new PropertiesSubmenu("Компиляция на локальной машине", null,
|
||||||
Global.normalProperties,
|
Global.normalProperties,
|
||||||
"LocalMakePathWindows",
|
"LocalMakePathWindows",
|
||||||
"PrecompilationFlags",
|
|
||||||
"Kernels"
|
"Kernels"
|
||||||
));
|
));
|
||||||
} else {
|
} else {
|
||||||
add(new PropertiesSubmenu("Компиляция на локальной машине", null,
|
add(new PropertiesSubmenu("Компиляция на локальной машине", null,
|
||||||
Global.normalProperties,
|
Global.normalProperties,
|
||||||
"PrecompilationFlags",
|
|
||||||
"Kernels"
|
"Kernels"
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,9 +19,7 @@ public class RendererTestingPackageStatus extends RendererCell<TestingPackage> {
|
|||||||
String text_ = state.getDescription();
|
String text_ = state.getDescription();
|
||||||
switch (state) {
|
switch (state) {
|
||||||
case DoneWithErrors:
|
case DoneWithErrors:
|
||||||
if (value.tasksCount>value.doneTasksCount) {
|
text_ += " " + Utils_.Brackets((value.tasksCount - value.doneTasksCount) + "/" + value.tasksCount);
|
||||||
text_ += " " + Utils_.Brackets((value.tasksCount - value.doneTasksCount) + "/" + value.tasksCount);
|
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -18,7 +18,6 @@ import javax.swing.*;
|
|||||||
import javax.swing.text.Highlighter;
|
import javax.swing.text.Highlighter;
|
||||||
import java.awt.event.ActionEvent;
|
import java.awt.event.ActionEvent;
|
||||||
import java.awt.event.ActionListener;
|
import java.awt.event.ActionListener;
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
public abstract class ComparisonForm<T> {
|
public abstract class ComparisonForm<T> {
|
||||||
@@ -26,6 +25,7 @@ public abstract class ComparisonForm<T> {
|
|||||||
final char cseparator = '\u200B';
|
final char cseparator = '\u200B';
|
||||||
public Class<T> t; //класс объектов.
|
public Class<T> t; //класс объектов.
|
||||||
//-->>
|
//-->>
|
||||||
|
public Vector<String> lines = new Vector<>(); //строки с учетом/неучетом пробелов. для сравнения
|
||||||
public Vector<String> visible_lines = new Vector<>(); //строки с нетронутыми пробелами. для отображения
|
public Vector<String> visible_lines = new Vector<>(); //строки с нетронутыми пробелами. для отображения
|
||||||
protected JToolBar tools;
|
protected JToolBar tools;
|
||||||
protected JLabel lObjectName;
|
protected JLabel lObjectName;
|
||||||
@@ -159,8 +159,12 @@ public abstract class ComparisonForm<T> {
|
|||||||
showObject();
|
showObject();
|
||||||
}
|
}
|
||||||
private void getLines() {
|
private void getLines() {
|
||||||
|
lines.clear();
|
||||||
visible_lines.clear();
|
visible_lines.clear();
|
||||||
visible_lines = new Vector<String>(Arrays.asList(getText().split("\n")));
|
//--
|
||||||
|
Pair<Vector<String>, Vector<String>> p = Utils.getFortranLines(getText());
|
||||||
|
lines = p.getKey();
|
||||||
|
visible_lines = p.getValue();
|
||||||
}
|
}
|
||||||
protected void ClearText() {
|
protected void ClearText() {
|
||||||
events_on = false;
|
events_on = false;
|
||||||
@@ -185,7 +189,7 @@ public abstract class ComparisonForm<T> {
|
|||||||
DiffRowGenerator generator = DiffRowGenerator.create()
|
DiffRowGenerator generator = DiffRowGenerator.create()
|
||||||
.showInlineDiffs(true)
|
.showInlineDiffs(true)
|
||||||
.inlineDiffByWord(true)
|
.inlineDiffByWord(true)
|
||||||
// .ignoreWhiteSpaces(false)
|
.ignoreWhiteSpaces(true)
|
||||||
.oldTag(f -> separator)
|
.oldTag(f -> separator)
|
||||||
.newTag(f -> separator)
|
.newTag(f -> separator)
|
||||||
.build();
|
.build();
|
||||||
@@ -270,9 +274,9 @@ public abstract class ComparisonForm<T> {
|
|||||||
t2.addAll(slave.visible_lines);
|
t2.addAll(slave.visible_lines);
|
||||||
//просто выясняем кто из них длиннее, и короткий дополняем пустыми строками.]
|
//просто выясняем кто из них длиннее, и короткий дополняем пустыми строками.]
|
||||||
int delta = Math.abs(t1.size() - t2.size());
|
int delta = Math.abs(t1.size() - t2.size());
|
||||||
if (visible_lines.size() > slave.visible_lines.size()) {
|
if (lines.size() > slave.lines.size()) {
|
||||||
Utils.addEmptyLines(t2, delta);
|
Utils.addEmptyLines(t2, delta);
|
||||||
} else if (visible_lines.size() < slave.visible_lines.size()) {
|
} else if (lines.size() < slave.lines.size()) {
|
||||||
Utils.addEmptyLines(t1, delta);
|
Utils.addEmptyLines(t1, delta);
|
||||||
}
|
}
|
||||||
///----------------
|
///----------------
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 502 B |
Reference in New Issue
Block a user