Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 112226

Summary: [Performance] performance degradation of IAC vs full AC
Product: z_Archived Reporter: Marius Slavescu <slavescu>
Component: TPTPAssignee: Samson Wai <samwai>
Status: CLOSED DUPLICATE QA Contact:
Severity: major    
Priority: P3 CC: sluiman, suwanda
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard: closed460

Description Marius Slavescu CLA 2005-10-11 11:17:10 EDT
Try to profile Eclipse in "Execution History - Statistical" mode with org*
removed from the default filters with both IAC and AC, watch the event rate
processing on the status bar, it is around 50 times slower (300 vs 15k
events/second). The maximum processing rate on my machine is around 40k
events/second when I import the raw trace in Execution Statistic mode.

I'm not sure what is wrong, but it would help if you could use the
org.eclipse.hyades.internal.execution.local.common.ExtendedDataServerListener
 in stream mode (see incommingStream usages) where applicable, this mode is
already implemented in the
org.eclipse.hyades.internal.execution.local.common.TCPDataServer.TCPDataProcessorNew
Comment 1 Marius Slavescu CLA 2005-10-11 16:11:31 EDT
The stream mode that is available through
ExtendedDataServerListener.incommingStream should be faster when used from IAC
than when comming from AC, because the message decoding process is not required
in IAC.
The stream mode avoids also the need of parserThread in XMLFragmentHandler.
Comment 2 Hendra Suwanda CLA 2005-10-28 10:43:28 EDT
Can't be contained in 4.1.
Transfering to 4.2
Comment 3 Marius Slavescu CLA 2005-11-24 00:47:20 EST
I haven't open a new bug, but I just noticed that the following default values may not be appropiate:

	private int bufferSize = 8192;
	private int dataChannelSize = 4096 * 1024 * 1024; // 4MB (this is 4Gb, was intended or is a typo ?)

in: /org.eclipse.hyades.execution/src-iac-hyades/org/eclipse/tptp/platform/agentcontroller/internal/hyades/impl/SharedMemoryTransportReaderImpl.java
Comment 4 Marius Slavescu CLA 2005-11-24 00:57:46 EST
If I use:

	private int bufferSize = 64 * 1024 ; // 64k
	private int dataChannelSize = 4 * 1024 * 1024; // 4MB


and also the following patch (to confirm that the problem is somewhere in the  native code) to output the data at the source (activate the patch code by passing -CommunicationDebug.debugMessageValue=true in the VM args) and I don't do any processing it stops collectiong arround 13Mb (in less then 15s, about 1Mb/s including message headers):

Index: HyadesProcessingModuleImpl.java
===================================================================
RCS file: /home/tptp/platform/org.eclipse.hyades.execution/src-iac-hyades/org/eclipse/tptp/platform/agentcontroller/internal/hyades/impl/HyadesProcessingModuleImpl.java,v
retrieving revision 1.1.2.1
diff -u -r1.1.2.1 HyadesProcessingModuleImpl.java
--- HyadesProcessingModuleImpl.java	10 Nov 2005 16:24:40 -0000	1.1.2.1
+++ HyadesProcessingModuleImpl.java	24 Nov 2005 05:51:27 -0000
@@ -17,6 +17,7 @@
 import java.util.Enumeration;
 import java.util.Vector;
 
+import org.eclipse.hyades.execution.local.CommunicationDebug;
 import org.eclipse.hyades.internal.execution.local.common.Message;
 import org.eclipse.tptp.platform.agentcontroller.internal.ProcessingModule;
 import org.eclipse.tptp.platform.agentcontroller.internal.TrafficController;
@@ -45,6 +46,7 @@
 
 	// Used for handling IAC stop request
 	private boolean _isRunning = false;
+	private boolean toFile;
 
 	public HyadesProcessingModuleImpl() {
 	}
@@ -65,7 +67,23 @@
 	 * Bytes received from the traffic controller
 	 */
 	public void incommingBytes(ConnectionInfo cxInfo, byte[] bytes) {
+		if(CommunicationDebug.INSTANCE.debugMessageValue )
+		{
+			if(toFile)
+			{
+				CommunicationDebug.INSTANCE.writeBinaryLog("directConnection"+this.hashCode(),bytes,0,bytes.length);
+				return;
+			}
+			else if(!Thread.currentThread().getName().endsWith("ster"))
+			{
+				toFile=true;
+				CommunicationDebug.INSTANCE.writeBinaryLog("directConnection"+this.hashCode(),bytes,0,bytes.length);
+				return;
+			}
+		}
+
 		_byteProcessor.incommingBytes(cxInfo, bytes);
+		
 	}
 
 	/**



Comment 5 Samson Wai CLA 2006-03-13 09:53:02 EST
Same as the bug opened by Valentina.

*** This bug has been marked as a duplicate of 116692 ***
Comment 6 Paul Slauenwhite CLA 2009-06-30 09:36:03 EDT
As of TPTP 4.6.0, TPTP is in maintenance mode and focusing on improving quality by resolving relevant enhancements/defects and increasing test coverage through test creation, automation, Build Verification Tests (BVTs), and expanded run-time execution. As part of the TPTP Bugzilla housecleaning process (see http://wiki.eclipse.org/Bugzilla_Housecleaning_Processes), this enhancement/defect is verified/closed by the Project Lead since this originator of this enhancement/defect has an inactive Bugzilla account and considered to be fixed. If this enhancement/defect is still unresolved and reproducible in the latest TPTP release (http://www.eclipse.org/tptp/home/downloads/), please re-open.