DateField cache should check the ExternalOperand instead of ExternalReference on X64

Review URL: https://chromiumcodereview.appspot.com/12637025
Patch from Weiliang Lin <weiliang.lin2@gmail.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13919 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
yangguo@chromium.org 2013-03-13 09:28:08 +00:00
parent 004452bff9
commit f8d0013f78
2 changed files with 4 additions and 2 deletions

View File

@ -3058,7 +3058,8 @@ void FullCodeGenerator::EmitDateField(CallRuntime* expr) {
} else {
if (index->value() < JSDate::kFirstUncachedField) {
ExternalReference stamp = ExternalReference::date_cache_stamp(isolate());
__ movq(scratch, stamp);
Operand stamp_operand = __ ExternalOperand(stamp);
__ movq(scratch, stamp_operand);
__ cmpq(scratch, FieldOperand(object, JSDate::kCacheStampOffset));
__ j(not_equal, &runtime, Label::kNear);
__ movq(result, FieldOperand(object, JSDate::kValueOffset +

View File

@ -1643,7 +1643,8 @@ void LCodeGen::DoDateField(LDateField* instr) {
} else {
if (index->value() < JSDate::kFirstUncachedField) {
ExternalReference stamp = ExternalReference::date_cache_stamp(isolate());
__ movq(kScratchRegister, stamp);
Operand stamp_operand = __ ExternalOperand(stamp);
__ movq(kScratchRegister, stamp_operand);
__ cmpq(kScratchRegister, FieldOperand(object,
JSDate::kCacheStampOffset));
__ j(not_equal, &runtime, Label::kNear);