Commit 5ce700be authored by paul.lind's avatar paul.lind Committed by Commit bot

Fix big-endian after '[osr] Increase Code::profiler_ticks to 28 bits.'

Several users of kKindSpecificFlags1Offset (aliased as kFullCodeFlags) were
reading/writing bytes -- not endian agnostic.

TEST=mjsunit/debug-setexceptionbreak, mjsunit/debug-mirror-cache, mjsunit/regress/regress-94873, others...
BUG=

Review URL: https://codereview.chromium.org/1236143002

Cr-Commit-Position: refs/heads/master@{#29634}
parent 47bcd1a1
...@@ -4507,61 +4507,61 @@ inline void Code::set_can_have_weak_objects(bool value) { ...@@ -4507,61 +4507,61 @@ inline void Code::set_can_have_weak_objects(bool value) {
bool Code::has_deoptimization_support() { bool Code::has_deoptimization_support() {
DCHECK_EQ(FUNCTION, kind()); DCHECK_EQ(FUNCTION, kind());
byte flags = READ_BYTE_FIELD(this, kFullCodeFlags); unsigned flags = READ_UINT32_FIELD(this, kFullCodeFlags);
return FullCodeFlagsHasDeoptimizationSupportField::decode(flags); return FullCodeFlagsHasDeoptimizationSupportField::decode(flags);
} }
void Code::set_has_deoptimization_support(bool value) { void Code::set_has_deoptimization_support(bool value) {
DCHECK_EQ(FUNCTION, kind()); DCHECK_EQ(FUNCTION, kind());
byte flags = READ_BYTE_FIELD(this, kFullCodeFlags); unsigned flags = READ_UINT32_FIELD(this, kFullCodeFlags);
flags = FullCodeFlagsHasDeoptimizationSupportField::update(flags, value); flags = FullCodeFlagsHasDeoptimizationSupportField::update(flags, value);
WRITE_BYTE_FIELD(this, kFullCodeFlags, flags); WRITE_UINT32_FIELD(this, kFullCodeFlags, flags);
} }
bool Code::has_debug_break_slots() { bool Code::has_debug_break_slots() {
DCHECK_EQ(FUNCTION, kind()); DCHECK_EQ(FUNCTION, kind());
byte flags = READ_BYTE_FIELD(this, kFullCodeFlags); unsigned flags = READ_UINT32_FIELD(this, kFullCodeFlags);
return FullCodeFlagsHasDebugBreakSlotsField::decode(flags); return FullCodeFlagsHasDebugBreakSlotsField::decode(flags);
} }
void Code::set_has_debug_break_slots(bool value) { void Code::set_has_debug_break_slots(bool value) {
DCHECK_EQ(FUNCTION, kind()); DCHECK_EQ(FUNCTION, kind());
byte flags = READ_BYTE_FIELD(this, kFullCodeFlags); unsigned flags = READ_UINT32_FIELD(this, kFullCodeFlags);
flags = FullCodeFlagsHasDebugBreakSlotsField::update(flags, value); flags = FullCodeFlagsHasDebugBreakSlotsField::update(flags, value);
WRITE_BYTE_FIELD(this, kFullCodeFlags, flags); WRITE_UINT32_FIELD(this, kFullCodeFlags, flags);
} }
bool Code::is_compiled_optimizable() { bool Code::is_compiled_optimizable() {
DCHECK_EQ(FUNCTION, kind()); DCHECK_EQ(FUNCTION, kind());
byte flags = READ_BYTE_FIELD(this, kFullCodeFlags); unsigned flags = READ_UINT32_FIELD(this, kFullCodeFlags);
return FullCodeFlagsIsCompiledOptimizable::decode(flags); return FullCodeFlagsIsCompiledOptimizable::decode(flags);
} }
void Code::set_compiled_optimizable(bool value) { void Code::set_compiled_optimizable(bool value) {
DCHECK_EQ(FUNCTION, kind()); DCHECK_EQ(FUNCTION, kind());
byte flags = READ_BYTE_FIELD(this, kFullCodeFlags); unsigned flags = READ_UINT32_FIELD(this, kFullCodeFlags);
flags = FullCodeFlagsIsCompiledOptimizable::update(flags, value); flags = FullCodeFlagsIsCompiledOptimizable::update(flags, value);
WRITE_BYTE_FIELD(this, kFullCodeFlags, flags); WRITE_UINT32_FIELD(this, kFullCodeFlags, flags);
} }
bool Code::has_reloc_info_for_serialization() { bool Code::has_reloc_info_for_serialization() {
DCHECK_EQ(FUNCTION, kind()); DCHECK_EQ(FUNCTION, kind());
byte flags = READ_BYTE_FIELD(this, kFullCodeFlags); unsigned flags = READ_UINT32_FIELD(this, kFullCodeFlags);
return FullCodeFlagsHasRelocInfoForSerialization::decode(flags); return FullCodeFlagsHasRelocInfoForSerialization::decode(flags);
} }
void Code::set_has_reloc_info_for_serialization(bool value) { void Code::set_has_reloc_info_for_serialization(bool value) {
DCHECK_EQ(FUNCTION, kind()); DCHECK_EQ(FUNCTION, kind());
byte flags = READ_BYTE_FIELD(this, kFullCodeFlags); unsigned flags = READ_UINT32_FIELD(this, kFullCodeFlags);
flags = FullCodeFlagsHasRelocInfoForSerialization::update(flags, value); flags = FullCodeFlagsHasRelocInfoForSerialization::update(flags, value);
WRITE_BYTE_FIELD(this, kFullCodeFlags, flags); WRITE_UINT32_FIELD(this, kFullCodeFlags, flags);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment