Reviewers: Jakob,
Message:
linux-tick-processor will show:
32 0.2% 0.0% [vdso]
instead of:
32 0.2% 0.0% f76ec000-f76ed000
Description:
Record vdso and vsyscall as shared libraries in
OS::LogSharedLibraryAddresses on
Linux
Please review this at https://codereview.chromium.org/11879036/
SVN Base: http://v8.googlecode.com/svn/branches/bleeding_edge/
Affected files:
M src/platform-linux.cc
Index: src/platform-linux.cc
===================================================================
--- src/platform-linux.cc (revision 13375)
+++ src/platform-linux.cc (working copy)
@@ -535,19 +535,20 @@
// the beginning of the filename or the end of the line.
do {
c = getc(fp);
- } while ((c != EOF) && (c != '\n') && (c != '/'));
+ } while ((c != EOF) && (c != '\n') && (c != '/') && (c != '['));
if (c == EOF) break; // EOF: Was unexpected, just exit.
// Process the filename if found.
- if (c == '/') {
- ungetc(c, fp); // Push the '/' back into the stream to be read
below.
+ if ((c == '/') || (c == '[')) {
+ // Push the '/' or '[' back into the stream to be read below.
+ ungetc(c, fp);
// Read to the end of the line. Exit if the read fails.
if (fgets(lib_name, kLibNameLen, fp) == NULL) break;
// Drop the newline character read by fgets. We do not need to
check
// for a zero-length string because we know that we at least read
the
- // '/' character.
+ // '/' or '[' character.
lib_name[strlen(lib_name) - 1] = '\0';
} else {
// No library name found, just record the raw address range.
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev