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

Side by Side Diff: src/objects-inl.h

Issue 2591903002: [wasm] sundry trap handler fixes (Closed)
Patch Set: Merge VisitLoad and VisitProtectedLoad Created 4 years 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
« no previous file with comments | « src/objects-body-descriptors-inl.h ('k') | src/wasm/wasm-module.cc » ('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 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 // 4 //
5 // Review notes: 5 // Review notes:
6 // 6 //
7 // - The use of macros in these inline functions may seem superfluous 7 // - The use of macros in these inline functions may seem superfluous
8 // but it is absolutely needed to make sure gcc generates optimal 8 // but it is absolutely needed to make sure gcc generates optimal
9 // code. gcc is not happy when attempting to inline too deep. 9 // code. gcc is not happy when attempting to inline too deep.
10 // 10 //
(...skipping 6809 matching lines...) Expand 10 before | Expand all | Expand 10 after
6820 WRITE_FIELD(this, kRelocationInfoOffset, NULL); 6820 WRITE_FIELD(this, kRelocationInfoOffset, NULL);
6821 WRITE_FIELD(this, kHandlerTableOffset, NULL); 6821 WRITE_FIELD(this, kHandlerTableOffset, NULL);
6822 WRITE_FIELD(this, kDeoptimizationDataOffset, NULL); 6822 WRITE_FIELD(this, kDeoptimizationDataOffset, NULL);
6823 WRITE_FIELD(this, kSourcePositionTableOffset, NULL); 6823 WRITE_FIELD(this, kSourcePositionTableOffset, NULL);
6824 // Do not wipe out major/minor keys on a code stub or IC 6824 // Do not wipe out major/minor keys on a code stub or IC
6825 if (!READ_FIELD(this, kTypeFeedbackInfoOffset)->IsSmi()) { 6825 if (!READ_FIELD(this, kTypeFeedbackInfoOffset)->IsSmi()) {
6826 WRITE_FIELD(this, kTypeFeedbackInfoOffset, NULL); 6826 WRITE_FIELD(this, kTypeFeedbackInfoOffset, NULL);
6827 } 6827 }
6828 WRITE_FIELD(this, kNextCodeLinkOffset, NULL); 6828 WRITE_FIELD(this, kNextCodeLinkOffset, NULL);
6829 WRITE_FIELD(this, kGCMetadataOffset, NULL); 6829 WRITE_FIELD(this, kGCMetadataOffset, NULL);
6830 WRITE_FIELD(this, kProtectedInstructionOffset, NULL);
6830 } 6831 }
6831 6832
6832 6833
6833 Object* Code::type_feedback_info() { 6834 Object* Code::type_feedback_info() {
6834 DCHECK(kind() == FUNCTION); 6835 DCHECK(kind() == FUNCTION);
6835 return raw_type_feedback_info(); 6836 return raw_type_feedback_info();
6836 } 6837 }
6837 6838
6838 6839
6839 void Code::set_type_feedback_info(Object* value, WriteBarrierMode mode) { 6840 void Code::set_type_feedback_info(Object* value, WriteBarrierMode mode) {
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
6903 : instruction_size(); 6904 : instruction_size();
6904 return RoundUp(unpadded_body_size, kObjectAlignment); 6905 return RoundUp(unpadded_body_size, kObjectAlignment);
6905 } 6906 }
6906 6907
6907 int Code::SizeIncludingMetadata() { 6908 int Code::SizeIncludingMetadata() {
6908 int size = CodeSize(); 6909 int size = CodeSize();
6909 size += relocation_info()->Size(); 6910 size += relocation_info()->Size();
6910 size += deoptimization_data()->Size(); 6911 size += deoptimization_data()->Size();
6911 size += handler_table()->Size(); 6912 size += handler_table()->Size();
6912 if (kind() == FUNCTION) size += source_position_table()->Size(); 6913 if (kind() == FUNCTION) size += source_position_table()->Size();
6914 size += protected_instructions()->Size();
6913 return size; 6915 return size;
6914 } 6916 }
6915 6917
6916 ByteArray* Code::unchecked_relocation_info() { 6918 ByteArray* Code::unchecked_relocation_info() {
6917 return reinterpret_cast<ByteArray*>(READ_FIELD(this, kRelocationInfoOffset)); 6919 return reinterpret_cast<ByteArray*>(READ_FIELD(this, kRelocationInfoOffset));
6918 } 6920 }
6919 6921
6920 6922
6921 byte* Code::relocation_start() { 6923 byte* Code::relocation_start() {
6922 return unchecked_relocation_info()->GetDataStartAddress(); 6924 return unchecked_relocation_info()->GetDataStartAddress();
(...skipping 1513 matching lines...) Expand 10 before | Expand all | Expand 10 after
8436 #undef WRITE_INT64_FIELD 8438 #undef WRITE_INT64_FIELD
8437 #undef READ_BYTE_FIELD 8439 #undef READ_BYTE_FIELD
8438 #undef WRITE_BYTE_FIELD 8440 #undef WRITE_BYTE_FIELD
8439 #undef NOBARRIER_READ_BYTE_FIELD 8441 #undef NOBARRIER_READ_BYTE_FIELD
8440 #undef NOBARRIER_WRITE_BYTE_FIELD 8442 #undef NOBARRIER_WRITE_BYTE_FIELD
8441 8443
8442 } // namespace internal 8444 } // namespace internal
8443 } // namespace v8 8445 } // namespace v8
8444 8446
8445 #endif // V8_OBJECTS_INL_H_ 8447 #endif // V8_OBJECTS_INL_H_
OLDNEW
« no previous file with comments | « src/objects-body-descriptors-inl.h ('k') | src/wasm/wasm-module.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698