Search in sources :

Example 41 with ILineRule

use of com.ibm.dtfj.javacore.parser.framework.tag.ILineRule in project openj9 by eclipse.

the class TitleTagParser method addDateTime.

/**
 * Add rule for the dump date (1TIDATETIME line)
 */
private void addDateTime() {
    ILineRule lineRule = new LineRule() {

        public void processLine(String source, int startingOffset) {
            // 1TIDATETIME    Date:    2009/02/09 at 15:48:30
            // or (Java 8 SR2 or later, with millisecs added):
            // 1TIDATETIME    Date:    2015/07/17 at 09:46:27:261
            consumeUntilFirstMatch(CommonPatternMatchers.colon);
            consumeUntilFirstMatch(CommonPatternMatchers.whitespace);
            addToken(TI_DATE, CommonPatternMatchers.allButLineFeed);
        }
    };
    addTag(T_1TIDATETIME, lineRule);
}
Also used : LineRule(com.ibm.dtfj.javacore.parser.framework.tag.LineRule) ILineRule(com.ibm.dtfj.javacore.parser.framework.tag.ILineRule) ILineRule(com.ibm.dtfj.javacore.parser.framework.tag.ILineRule)

Example 42 with ILineRule

use of com.ibm.dtfj.javacore.parser.framework.tag.ILineRule in project openj9 by eclipse.

the class TitleTagParser method addNanoTime.

/**
 * Add rule for the dump nanotime (1TINANOTIME line)
 */
private void addNanoTime() {
    ILineRule lineRule = new LineRule() {

        public void processLine(String source, int startingOffset) {
            // 1TINANOTIME    System nanotime: 3534320355422
            consumeUntilFirstMatch(CommonPatternMatchers.colon);
            consumeUntilFirstMatch(CommonPatternMatchers.whitespace);
            addToken(TI_NANO, CommonPatternMatchers.allButLineFeed);
        }
    };
    addTag(T_1TINANOTIME, lineRule);
}
Also used : LineRule(com.ibm.dtfj.javacore.parser.framework.tag.LineRule) ILineRule(com.ibm.dtfj.javacore.parser.framework.tag.ILineRule) ILineRule(com.ibm.dtfj.javacore.parser.framework.tag.ILineRule)

Example 43 with ILineRule

use of com.ibm.dtfj.javacore.parser.framework.tag.ILineRule in project openj9 by eclipse.

the class ThreadTagParser method initThreadInfo2Tag.

/**
 * Parse the native stack address range information
 */
private void initThreadInfo2Tag() {
    // 3XMTHREADINFO2            (native stack address range from:0x915CA000, to:0x91589000, size:0x41000)
    ILineRule lineRule = new LineRule() {

        public void processLine(String source, int startingOffset) {
            /*
				 * NATIVE_STACK_FROM
				 */
            consumeUntilFirstMatch(CommonPatternMatchers.colon);
            addPrefixedHexToken(IThreadTypes.NATIVE_STACK_FROM);
            /*
				 * NATIVE_STACK_TO
				 */
            consumeUntilFirstMatch(CommonPatternMatchers.colon);
            addPrefixedHexToken(IThreadTypes.NATIVE_STACK_TO);
            /*
				 * NATIVE_STACK_SIZE
				 */
            consumeUntilFirstMatch(CommonPatternMatchers.colon);
            addPrefixedHexToken(IThreadTypes.NATIVE_STACK_SIZE);
        }
    };
    addTag(IThreadTypes.T_3XMTHREADINFO2, lineRule);
}
Also used : LineRule(com.ibm.dtfj.javacore.parser.framework.tag.LineRule) PointerSizeLineRule(com.ibm.dtfj.javacore.parser.j9.section.common.PointerSizeLineRule) ILineRule(com.ibm.dtfj.javacore.parser.framework.tag.ILineRule) ILineRule(com.ibm.dtfj.javacore.parser.framework.tag.ILineRule)

Example 44 with ILineRule

use of com.ibm.dtfj.javacore.parser.framework.tag.ILineRule in project openj9 by eclipse.

the class ThreadTagParser method initThreadInfoTag.

/**
 * Both J9 and SOV 1.4.2 , and J9 5.0 (2.3 - 2.4)
 */
private void initThreadInfoTag() {
    ILineRule lineRule = new ThreadInfoLineRule();
    addTag(IThreadTypes.T_3XMTHREADINFO, lineRule);
}
Also used : ILineRule(com.ibm.dtfj.javacore.parser.framework.tag.ILineRule)

Example 45 with ILineRule

use of com.ibm.dtfj.javacore.parser.framework.tag.ILineRule in project openj9 by eclipse.

the class ThreadTagParser method initThreadBlockTag.

/**
 * J9 R2.6+ only
 */
private void initThreadBlockTag() {
    // 3XMTHREADBLOCK     Blocked on: java/lang/String@0x4D8C90F8 Owned by: "main" (J9VMThread:0x00129100, java/lang/Thread:0x00DD4798)
    ILineRule lineRule = new LineRule() {

        public void processLine(String source, int startingOffset) {
            consumeUntilFirstMatch(CommonPatternMatchers.colon);
            consumeUntilFirstMatch(CommonPatternMatchers.whitespace);
            /*
				 * BLOCKER_OBJECT_FULL_JAVA_NAME
				 */
            addAllCharactersAsTokenAndConsumeFirstMatch(IThreadTypes.BLOCKER_OBJECT_FULL_JAVA_NAME, CommonPatternMatchers.at_symbol);
            /*
				 * BLOCKER_OBJECT_ADDRESS
				 */
            addPrefixedHexToken(IThreadTypes.BLOCKER_OBJECT_ADDRESS);
        }
    };
    addTag(IThreadTypes.T_3XMTHREADBLOCK, lineRule);
}
Also used : LineRule(com.ibm.dtfj.javacore.parser.framework.tag.LineRule) PointerSizeLineRule(com.ibm.dtfj.javacore.parser.j9.section.common.PointerSizeLineRule) ILineRule(com.ibm.dtfj.javacore.parser.framework.tag.ILineRule) ILineRule(com.ibm.dtfj.javacore.parser.framework.tag.ILineRule)

Aggregations

ILineRule (com.ibm.dtfj.javacore.parser.framework.tag.ILineRule)46 LineRule (com.ibm.dtfj.javacore.parser.framework.tag.LineRule)31 PointerSizeLineRule (com.ibm.dtfj.javacore.parser.j9.section.common.PointerSizeLineRule)6 IParserToken (com.ibm.dtfj.javacore.parser.framework.scanner.IParserToken)1 Matcher (java.util.regex.Matcher)1