Ryan Dahl <coldredlemur@gmail.com>
Patrick Gansterer <paroga@paroga.com>
Subrato K De <subratokde@codeaurora.org>
+Dineel D Sule <dsule@codeaurora.org>
#include "code-stubs.h"
#include "factory.h"
#include "macro-assembler.h"
+#include "oprofile-agent.h"
namespace v8 {
namespace internal {
// Add unresolved entries in the code to the fixup list.
Bootstrapper::AddFixup(code, masm);
+#ifdef ENABLE_OPROFILE_AGENT
+ // Register the generated stub with the OPROFILE agent.
+ OProfileAgent::CreateNativeCodeRegion(GetName(),
+ code->instruction_start(),
+ code->instruction_size());
+#endif
+
LOG(CodeCreateEvent(Logger::STUB_TAG, code, GetName()));
Counters::total_stubs_code_size.Increment(code->instruction_size());