Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(372)

Side by Side Diff: src/arm/stub-cache-arm.cc

Issue 16838013: Revert "Notify CPU profiler when calling native getters" (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm/simulator-arm.cc ('k') | src/assembler.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 938 matching lines...) Expand 10 before | Expand all | Expand 10 after
949 bool returns_handle = 949 bool returns_handle =
950 !CallbackTable::ReturnsVoid(masm->isolate(), function_address); 950 !CallbackTable::ReturnsVoid(masm->isolate(), function_address);
951 ApiFunction fun(function_address); 951 ApiFunction fun(function_address);
952 ExternalReference::Type type = 952 ExternalReference::Type type =
953 returns_handle ? 953 returns_handle ?
954 ExternalReference::DIRECT_API_CALL : 954 ExternalReference::DIRECT_API_CALL :
955 ExternalReference::DIRECT_API_CALL_NEW; 955 ExternalReference::DIRECT_API_CALL_NEW;
956 ExternalReference ref = ExternalReference(&fun, 956 ExternalReference ref = ExternalReference(&fun,
957 type, 957 type,
958 masm->isolate()); 958 masm->isolate());
959 Address thunk_address = returns_handle
960 ? FUNCTION_ADDR(&InvokeInvocationCallback)
961 : FUNCTION_ADDR(&InvokeFunctionCallback);
962 ExternalReference::Type thunk_type =
963 returns_handle ?
964 ExternalReference::PROFILING_API_CALL :
965 ExternalReference::PROFILING_API_CALL_NEW;
966 ApiFunction thunk_fun(thunk_address);
967 ExternalReference thunk_ref = ExternalReference(&thunk_fun, thunk_type,
968 masm->isolate());
969
970 AllowExternalCallThatCantCauseGC scope(masm); 959 AllowExternalCallThatCantCauseGC scope(masm);
971 __ CallApiFunctionAndReturn(ref, 960 __ CallApiFunctionAndReturn(ref,
972 function_address,
973 thunk_ref,
974 r1,
975 kStackUnwindSpace, 961 kStackUnwindSpace,
976 returns_handle, 962 returns_handle,
977 kFastApiCallArguments + 1); 963 kFastApiCallArguments + 1);
978 } 964 }
979 965
980 966
981 class CallInterceptorCompiler BASE_EMBEDDED { 967 class CallInterceptorCompiler BASE_EMBEDDED {
982 public: 968 public:
983 CallInterceptorCompiler(StubCompiler* stub_compiler, 969 CallInterceptorCompiler(StubCompiler* stub_compiler,
984 const ParameterCount& arguments, 970 const ParameterCount& arguments,
(...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after
1461 1447
1462 // Create AccessorInfo instance on the stack above the exit frame with 1448 // Create AccessorInfo instance on the stack above the exit frame with
1463 // scratch2 (internal::Object** args_) as the data. 1449 // scratch2 (internal::Object** args_) as the data.
1464 __ str(scratch2(), MemOperand(sp, 1 * kPointerSize)); 1450 __ str(scratch2(), MemOperand(sp, 1 * kPointerSize));
1465 __ add(r1, sp, Operand(1 * kPointerSize)); // r1 = AccessorInfo& 1451 __ add(r1, sp, Operand(1 * kPointerSize)); // r1 = AccessorInfo&
1466 1452
1467 const int kStackUnwindSpace = kFastApiCallArguments + 1; 1453 const int kStackUnwindSpace = kFastApiCallArguments + 1;
1468 Address getter_address = v8::ToCData<Address>(callback->getter()); 1454 Address getter_address = v8::ToCData<Address>(callback->getter());
1469 bool returns_handle = 1455 bool returns_handle =
1470 !CallbackTable::ReturnsVoid(isolate(), getter_address); 1456 !CallbackTable::ReturnsVoid(isolate(), getter_address);
1471
1472 ApiFunction fun(getter_address); 1457 ApiFunction fun(getter_address);
1473 ExternalReference::Type type = 1458 ExternalReference::Type type =
1474 returns_handle ? 1459 returns_handle ?
1475 ExternalReference::DIRECT_GETTER_CALL : 1460 ExternalReference::DIRECT_GETTER_CALL :
1476 ExternalReference::DIRECT_GETTER_CALL_NEW; 1461 ExternalReference::DIRECT_GETTER_CALL_NEW;
1462
1477 ExternalReference ref = ExternalReference(&fun, type, isolate()); 1463 ExternalReference ref = ExternalReference(&fun, type, isolate());
1478
1479 Address thunk_address = returns_handle
1480 ? FUNCTION_ADDR(&InvokeAccessorGetter)
1481 : FUNCTION_ADDR(&InvokeAccessorGetterCallback);
1482 ExternalReference::Type thunk_type =
1483 returns_handle ?
1484 ExternalReference::PROFILING_GETTER_CALL :
1485 ExternalReference::PROFILING_GETTER_CALL_NEW;
1486 ApiFunction thunk_fun(thunk_address);
1487 ExternalReference thunk_ref = ExternalReference(&thunk_fun, thunk_type,
1488 isolate());
1489 __ CallApiFunctionAndReturn(ref, 1464 __ CallApiFunctionAndReturn(ref,
1490 getter_address,
1491 thunk_ref,
1492 r2,
1493 kStackUnwindSpace, 1465 kStackUnwindSpace,
1494 returns_handle, 1466 returns_handle,
1495 5); 1467 5);
1496 } 1468 }
1497 1469
1498 1470
1499 void BaseLoadStubCompiler::GenerateLoadInterceptor( 1471 void BaseLoadStubCompiler::GenerateLoadInterceptor(
1500 Register holder_reg, 1472 Register holder_reg,
1501 Handle<JSObject> object, 1473 Handle<JSObject> object,
1502 Handle<JSObject> interceptor_holder, 1474 Handle<JSObject> interceptor_holder,
(...skipping 2162 matching lines...) Expand 10 before | Expand all | Expand 10 after
3665 TailCallBuiltin(masm, Builtins::kKeyedStoreIC_Slow); 3637 TailCallBuiltin(masm, Builtins::kKeyedStoreIC_Slow);
3666 } 3638 }
3667 } 3639 }
3668 3640
3669 3641
3670 #undef __ 3642 #undef __
3671 3643
3672 } } // namespace v8::internal 3644 } } // namespace v8::internal
3673 3645
3674 #endif // V8_TARGET_ARCH_ARM 3646 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/simulator-arm.cc ('k') | src/assembler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698