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

Unified Diff: src/dateparser.cc

Issue 8098: - Added conditional write barrier to object accessors.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 12 years, 2 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 | « src/builtins.cc ('k') | src/heap.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/dateparser.cc
===================================================================
--- src/dateparser.cc (revision 564)
+++ src/dateparser.cc (working copy)
@@ -149,9 +149,15 @@
if (!Smi::IsValid(year) || !IsMonth(month) || !IsDay(day)) return false;
- output->set(YEAR, Smi::FromInt(year));
- output->set(MONTH, Smi::FromInt(month - 1)); // 0-based
- output->set(DAY, Smi::FromInt(day));
+ output->set(YEAR,
+ Smi::FromInt(year),
+ SKIP_WRITE_BARRIER);
+ output->set(MONTH,
+ Smi::FromInt(month - 1),
+ SKIP_WRITE_BARRIER); // 0-based
+ output->set(DAY,
+ Smi::FromInt(day),
+ SKIP_WRITE_BARRIER);
return true;
}
@@ -174,9 +180,15 @@
if (!IsHour(hour) || !IsMinute(minute) || !IsSecond(second)) return false;
- output->set(HOUR, Smi::FromInt(hour));
- output->set(MINUTE, Smi::FromInt(minute));
- output->set(SECOND, Smi::FromInt(second));
+ output->set(HOUR,
+ Smi::FromInt(hour),
+ SKIP_WRITE_BARRIER);
+ output->set(MINUTE,
+ Smi::FromInt(minute),
+ SKIP_WRITE_BARRIER);
+ output->set(SECOND,
+ Smi::FromInt(second),
+ SKIP_WRITE_BARRIER);
return true;
}
@@ -187,9 +199,13 @@
if (minute_ == kNone) minute_ = 0;
int total_seconds = sign_ * (hour_ * 3600 + minute_ * 60);
if (!Smi::IsValid(total_seconds)) return false;
- output->set(UTC_OFFSET, Smi::FromInt(total_seconds));
+ output->set(UTC_OFFSET,
+ Smi::FromInt(total_seconds),
+ SKIP_WRITE_BARRIER);
} else {
- output->set(UTC_OFFSET, Heap::null_value());
+ output->set(UTC_OFFSET,
+ Heap::null_value(),
+ SKIP_WRITE_BARRIER);
}
return true;
}
« no previous file with comments | « src/builtins.cc ('k') | src/heap.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698