changeset 869:112555c47d41

profilers: perfasm, handle overflowed kernel events.
author shade
date Fri, 27 Jun 2014 19:20:00 +0400
parents d41cd280c2bb
children 5fc2244b5815
files jmh-core/src/main/java/org/openjdk/jmh/profile/LinuxPerfAsmProfiler.java
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/jmh-core/src/main/java/org/openjdk/jmh/profile/LinuxPerfAsmProfiler.java	Fri Jun 27 19:16:38 2014 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/profile/LinuxPerfAsmProfiler.java	Fri Jun 27 19:20:00 2014 +0400
@@ -598,11 +598,15 @@
                         evs.add(element);
                         methods.put(element, dedup.dedup(elements[5]));
                     } catch (NumberFormatException e) {
-                        // TODO: Kernel addresses like "ffffffff810c1b00" overflow signed long
+                        // kernel addresses like "ffffffff810c1b00" overflow signed long,
+                        // record them as dummy address
+                        evs.add(0L);
                     }
                 }
             }
 
+            methods.put(0L, "<kernel>");
+
             return new PerfEvents(events, methods);
         } catch (IOException e) {
             return new PerfEvents();