2016-05-30 08:55:32 +00:00
|
|
|
// Copyright 2016 the V8 project authors. All rights reserved.
|
|
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
|
|
// found in the LICENSE file.
|
|
|
|
|
2020-09-28 13:50:56 +00:00
|
|
|
import {
|
2021-06-01 18:13:48 +00:00
|
|
|
CppProcessor, ArgumentsProcessor, LinuxCppEntriesProvider,
|
|
|
|
WindowsCppEntriesProvider, MacOSCppEntriesProvider
|
2020-09-28 13:50:56 +00:00
|
|
|
} from "./dumpcpp.mjs";
|
|
|
|
|
2016-05-30 08:55:32 +00:00
|
|
|
// Dump C++ symbols of shared library if possible
|
|
|
|
|
2020-11-10 11:47:40 +00:00
|
|
|
const entriesProviders = {
|
2021-06-01 18:13:48 +00:00
|
|
|
'linux': LinuxCppEntriesProvider,
|
2016-05-30 08:55:32 +00:00
|
|
|
'windows': WindowsCppEntriesProvider,
|
2021-06-01 18:13:48 +00:00
|
|
|
'macos': MacOSCppEntriesProvider
|
2016-05-30 08:55:32 +00:00
|
|
|
};
|
|
|
|
|
2021-05-31 22:17:32 +00:00
|
|
|
const params = ArgumentsProcessor.process(arguments);
|
2020-11-10 11:47:40 +00:00
|
|
|
const cppProcessor = new CppProcessor(
|
2019-05-24 11:23:39 +00:00
|
|
|
new (entriesProviders[params.platform])(params.nm, params.targetRootFS,
|
|
|
|
params.apkEmbeddedLibrary),
|
2016-05-30 08:55:32 +00:00
|
|
|
params.timedRange, params.pairwiseTimedRange);
|
|
|
|
cppProcessor.processLogFile(params.logFileName);
|
|
|
|
cppProcessor.dumpCppSymbols();
|