DESCRIPTION

ctf: make streaminputpacketreaderindex a List

to be tested, but it gets rid of vector!
improves performance!
throws unsupported operation exceptions a lot!

Change-Id: I1ea72e61a04c2a8f264446c05d7dbaae5e6337e2
Signed-off-by: Ivy Mitchell xxx@xxx.xxx


COMMENTS

author: Ivy Mitchell
date: 2014-08-04 02:42:32.000000000

Uploaded patch set 3.

-------------------------------------
author: Brenden Conley
date: 2014-08-04 02:48:34.000000000

Patch Set 3:

Build Started https://hudson.eclipse.org/linuxtools/job/linuxtools-gerrit/8058/

-------------------------------------
author: Ivy Mitchell
date: 2014-08-04 02:57:40.000000000

Patch Set 3:

This appears to lower seek times on my 5400 rpm hdd from by 15% for the benchmark

-------------------------------------
author: Ivy Mitchell
date: 2014-08-04 03:10:32.000000000

Topic changed from CTF Performance to CTF performance

-------------------------------------
author: Brenden Conley
date: 2014-08-04 03:23:27.000000000

Patch Set 3: Verified+1

Build Successful 

https://hudson.eclipse.org/linuxtools/job/linuxtools-gerrit/8058/ : SUCCESS

-------------------------------------
author: Ivy Mitchell
date: 2014-08-04 12:02:53.000000000

Patch Set 3:

(2 comments)

Line:295, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/trace/StreamInputPacketIndex.java -> move up

Line:305, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/trace/StreamInputPacketIndex.java -> move up

-------------------------------------
author: Braxton Mccarthy
date: 2014-08-13 20:56:23.000000000

Patch Set 3: Code-Review-1

(4 comments)

Line:263, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/trace/StreamInputPacketIndexEntry.java -> You could do return Long.compare(o1, o2);

Line:31, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/trace/StreamInputPacketIndex.java -> Don't think it's worth implementing List here, especially if 3/4 of the methods just throw UnsupportOperationException. You're not really defining a stand-alone data strucutre here. This class can be a wrapper around a List.

Line:42, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/trace/StreamInputPacketIndex.java -> It can be quite easy to forget to update this field...

How about a getLastElement() method instead, that does .get(size-1) ? That way it's always up-to-date.

... oh have a lastElement() method already, how about just using that.

Line:110, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/trace/StreamInputPacketIndex.java -> you can merge the 2 if's with &&

-------------------------------------
author: Ivy Mitchell
date: 2014-08-16 01:39:16.000000000

Patch Set 3:

(1 comment)

Line:263, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/trace/StreamInputPacketIndexEntry.java -> not quite, int  ret = Long.compare(); if ret == 0 return Long.compare(o3,o4); return ret;, but it's harder to read IMO

-------------------------------------
author: Ivy Mitchell
date: 2014-08-16 01:41:49.000000000

Patch Set 3:

(2 comments)

Line:42, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/trace/StreamInputPacketIndex.java -> lastElement is what separates vectors from lists, get(size()-1) can be a fair tradeoff though... testing is needed

Line:110, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/trace/StreamInputPacketIndex.java -> Done

-------------------------------------
