Skip to content

Instantly share code, notes, and snippets.

View sunimalr's full-sized avatar

Sunimal Rathnayake sunimalr

  • University of Moratuwa
  • Sri Lanka
View GitHub Profile
@sunimalr
sunimalr / csvreader_bash
Last active August 29, 2015 13:57
csvreader_bash
#!/usr/bin/env bash
FILE=parameters.csv
K=1
while read line
do
IFS=, read -a arr <<<"$line"
if [ "$K" != "1" ]
then
@sunimalr
sunimalr / readfromcsv
Created March 30, 2014 07:09
readfromcsv
private BufferedReader fileReader;
int/float var1, var2, .........
public ........main()...{
while ((line = fileReader.readLine()) != null) {
String[] vals=line.split(' ');
@sunimalr
sunimalr / nehalem_timeslice_events
Created November 27, 2013 21:48
nehalem_timeslice_events
r0149, r0151, r20f0, r04b8
@sunimalr
sunimalr / power7_timeslice_events
Last active December 22, 2015 19:28
Power7_timeslice_events
r3c046, r26880, r2c048, rd0a0, r2f080
@sunimalr
sunimalr / Power7 Performance Counts : Reduced List
Created September 8, 2013 08:09
Power7 Performance Counts : Reduced List
r3c046,r2c048,r2f080,r26080,r30881,r26182,r26880,rd0a2,rd0a0,r2
Note: r2 is the instruction count
public static void main(String[] args) {
String fileName = args[0];
}
//Run as java progname <filename>
@sunimalr
sunimalr / ioException.net_server_side
Created June 4, 2012 11:09
ISPN_.NET client_ Server side log
2012-06-04 16:32:47,541 ERROR [HotRodDecoder] (HotRodServerWorker-1-1) ISPN00500
9: Unexpected error before any request parameters read
java.io.IOException: An existing connection was forcibly closed by the remote ho
st
at sun.nio.ch.SocketDispatcher.read0(Native Method)
at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:25)
at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:233)
at sun.nio.ch.IOUtil.read(IOUtil.java:200)
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:236)
at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:323)