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

Unified Diff: src/cpu-profiler.cc

Issue 2745002: Move token-related constants from CodeEntry to TokenEnumerator. (Closed)
Patch Set: Created 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/profile-generator.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/cpu-profiler.cc
diff --git a/src/cpu-profiler.cc b/src/cpu-profiler.cc
index 296808142c18b0fbd2c4260396faee7189a0b6e2..c8d29f8cf5747907e924fe3dd3643e324438024c 100644
--- a/src/cpu-profiler.cc
+++ b/src/cpu-profiler.cc
@@ -294,7 +294,8 @@ CpuProfile* CpuProfiler::StopProfiling(Object* security_token, String* title) {
int CpuProfiler::GetProfilesCount() {
ASSERT(singleton_ != NULL);
// The count of profiles doesn't depend on a security token.
- return singleton_->profiles_->Profiles(CodeEntry::kNoSecurityToken)->length();
+ return singleton_->profiles_->Profiles(
+ TokenEnumerator::kNoSecurityToken)->length();
}
@@ -380,7 +381,7 @@ void CpuProfiler::CodeDeleteEvent(Address from) {
void CpuProfiler::FunctionCreateEvent(JSFunction* function) {
- int security_token_id = CodeEntry::kNoSecurityToken;
+ int security_token_id = TokenEnumerator::kNoSecurityToken;
if (function->unchecked_context()->IsContext()) {
security_token_id = singleton_->token_enumerator_->GetTokenId(
function->context()->global_context()->security_token());
@@ -476,9 +477,10 @@ void CpuProfiler::StartProcessorIfNotStarted() {
CpuProfile* CpuProfiler::StopCollectingProfile(const char* title) {
const double actual_sampling_rate = generator_->actual_sampling_rate();
StopProcessorIfLastProfile();
- CpuProfile* result = profiles_->StopProfiling(CodeEntry::kNoSecurityToken,
- title,
- actual_sampling_rate);
+ CpuProfile* result =
+ profiles_->StopProfiling(TokenEnumerator::kNoSecurityToken,
+ title,
+ actual_sampling_rate);
if (result != NULL) {
result->Print();
}
« no previous file with comments | « no previous file | src/profile-generator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698