Commit eca64a2a authored by jkummerow's avatar jkummerow Committed by Commit bot

[ic] Drop TimerEventScopes from *IC_Miss runtime functions

This is mostly a performance experiment. If it provides no speedup,
it can be reverted to keep IC miss events in timeline plots.
Otherwise, the RuntimeCallStats system is the replacement tool for
investigating performance issues related to IC misses.

This effectively reverts 1f8adc15 / r21736.

Review-Url: https://codereview.chromium.org/2480343002
Cr-Commit-Position: refs/heads/master@{#40893}
parent d5f22440
......@@ -2541,7 +2541,6 @@ void CallIC::HandleMiss(Handle<Object> function) {
// Used from ic-<arch>.cc.
RUNTIME_FUNCTION(Runtime_CallIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
DCHECK_EQ(3, args.length());
// Runtime functions don't follow the IC's calling convention.
......@@ -2558,7 +2557,6 @@ RUNTIME_FUNCTION(Runtime_CallIC_Miss) {
// Used from ic-<arch>.cc.
RUNTIME_FUNCTION(Runtime_LoadIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
DCHECK_EQ(4, args.length());
// Runtime functions don't follow the IC's calling convention.
......@@ -2598,7 +2596,6 @@ RUNTIME_FUNCTION(Runtime_LoadIC_Miss) {
// Used from ic-<arch>.cc.
RUNTIME_FUNCTION(Runtime_LoadGlobalIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
DCHECK_EQ(2, args.length());
// Runtime functions don't follow the IC's calling convention.
......@@ -2670,7 +2667,6 @@ RUNTIME_FUNCTION(Runtime_LoadGlobalIC_Slow) {
// Used from ic-<arch>.cc
RUNTIME_FUNCTION(Runtime_KeyedLoadIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
DCHECK_EQ(4, args.length());
// Runtime functions don't follow the IC's calling convention.
......@@ -2687,7 +2683,6 @@ RUNTIME_FUNCTION(Runtime_KeyedLoadIC_Miss) {
RUNTIME_FUNCTION(Runtime_KeyedLoadIC_MissFromStubFailure) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
typedef LoadWithVectorDescriptor Descriptor;
DCHECK_EQ(Descriptor::kParameterCount, args.length());
......@@ -2706,7 +2701,6 @@ RUNTIME_FUNCTION(Runtime_KeyedLoadIC_MissFromStubFailure) {
// Used from ic-<arch>.cc.
RUNTIME_FUNCTION(Runtime_StoreIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
DCHECK_EQ(5, args.length());
// Runtime functions don't follow the IC's calling convention.
......@@ -2734,7 +2728,6 @@ RUNTIME_FUNCTION(Runtime_StoreIC_Miss) {
// Used from ic-<arch>.cc.
RUNTIME_FUNCTION(Runtime_KeyedStoreIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
DCHECK_EQ(5, args.length());
// Runtime functions don't follow the IC's calling convention.
......@@ -2770,7 +2763,6 @@ RUNTIME_FUNCTION(Runtime_KeyedStoreIC_Slow) {
RUNTIME_FUNCTION(Runtime_ElementsTransitionAndStoreIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
// Runtime functions don't follow the IC's calling convention.
Handle<Object> object = args.at<Object>(0);
......@@ -2909,7 +2901,6 @@ MaybeHandle<Object> BinaryOpIC::Transition(
RUNTIME_FUNCTION(Runtime_BinaryOpIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
DCHECK_EQ(2, args.length());
typedef BinaryOpDescriptor Descriptor;
......@@ -2922,7 +2913,6 @@ RUNTIME_FUNCTION(Runtime_BinaryOpIC_Miss) {
RUNTIME_FUNCTION(Runtime_BinaryOpIC_MissWithAllocationSite) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
DCHECK_EQ(3, args.length());
typedef BinaryOpWithAllocationSiteDescriptor Descriptor;
......@@ -2986,7 +2976,6 @@ Code* CompareIC::UpdateCaches(Handle<Object> x, Handle<Object> y) {
// Used from CompareICStub::GenerateMiss in code-stubs-<arch>.cc.
RUNTIME_FUNCTION(Runtime_CompareIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
HandleScope scope(isolate);
DCHECK(args.length() == 3);
CompareIC ic(isolate, static_cast<Token::Value>(args.smi_at(2)));
......@@ -3011,7 +3000,6 @@ Handle<Object> ToBooleanIC::ToBoolean(Handle<Object> object) {
RUNTIME_FUNCTION(Runtime_ToBooleanIC_Miss) {
TimerEventScope<TimerEventIcMiss> timer(isolate);
DCHECK(args.length() == 1);
HandleScope scope(isolate);
Handle<Object> object = args.at<Object>(0);
......
......@@ -341,8 +341,7 @@ class Logger : public CodeEventListener {
V(CompileCode, true) \
V(DeoptimizeCode, true) \
V(Execute, true) \
V(External, true) \
V(IcMiss, false)
V(External, true)
#define V(TimerName, expose) \
class TimerEvent##TimerName : public AllStatic { \
......
......@@ -216,8 +216,12 @@ var assertMatches;
message += " (" + name_opt + ")";
}
message += ": expected <" + expectedText +
"> found <" + PrettyPrint(found) + ">";
var foundText = PrettyPrint(found);
if (expectedText.length <= 40 && foundText.length <= 40) {
message += ": expected <" + expectedText + "> found <" + foundText + ">";
} else {
message += ":\nexpected:\n" + expectedText + "\nfound:\n" + foundText;
}
throw new MjsUnitAssertionError(message);
}
......
This diff is collapsed.
......@@ -78,6 +78,5 @@ var create_baseline = false;
if (create_baseline) {
print(JSON.stringify(output_lines, null, 2));
} else {
assertArrayEquals(output_lines,
JSON.parse(read(reference_file)));
assertArrayEquals(JSON.parse(read(reference_file)), output_lines);
}
......@@ -106,8 +106,6 @@ function PlotScriptComposer(kResX, kResY, error_output) {
new TimerEvent("recompile async", "#CC4499", false, 1),
'V8.CompileEvalMicroSeconds':
new TimerEvent("compile eval", "#CC4400", true, 0),
'V8.IcMiss':
new TimerEvent("ic miss", "#CC9900", false, 0),
'V8.ParseMicroSeconds':
new TimerEvent("parse", "#00CC00", true, 0),
'V8.PreParseMicroSeconds':
......
......@@ -30,10 +30,10 @@ var distortion_per_entry = 0;
var range_start_override = undefined;
var range_end_override = undefined;
if (!processor.parse()) processor.printUsageAndExit();;
if (!processor.parse()) processor.printUsageAndExit();
var result = processor.result();
var distortion = parseInt(result.distortion);
if (isNaN(distortion)) processor.printUsageAndExit();;
if (isNaN(distortion)) processor.printUsageAndExit();
// Convert picoseconds to milliseconds.
distortion_per_entry = distortion / 1000000;
var rangelimits = result.range.split(",");
......@@ -43,7 +43,7 @@ if (!isNaN(range_start)) range_start_override = range_start;
if (!isNaN(range_end)) range_end_override = range_end;
var kResX = 1600;
var kResY = 700;
var kResY = 600;
function log_error(text) {
print(text);
quit(1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment