Commit 0adf11f7 authored by Clemens Hammacher's avatar Clemens Hammacher Committed by Commit Bot

Fix compile errors on tsan and no-i18n

This fixes compile errors after https://crrev.com/c/1624788.

TBR=jkummerow@chromium.org

No-Try: true
Bug: v8:9183, v8:3770
Change-Id: I982e77e86389163f1549bbb02621b17972bbc158
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1627336Reviewed-by: 's avatarClemens Hammacher <clemensh@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#61774}
parent 626b9525
......@@ -261,23 +261,23 @@ V8_WARN_UNUSED_RESULT static Object ConvertCaseHelper(
unibrow::uchar chars[Converter::kMaxWidth];
// We can assume that the string is not empty
uc32 current = stream.GetNext();
bool ignore_overflow = Converter::kIsToLower || result->IsSeqTwoByteString();
bool ignore_overflow = Converter::kIsToLower || result.IsSeqTwoByteString();
for (int i = 0; i < result_length;) {
bool has_next = stream.HasMore();
uc32 next = has_next ? stream.GetNext() : 0;
int char_length = mapping->get(current, next, chars);
if (char_length == 0) {
// The case conversion of this character is the character itself.
result->Set(i, current);
result.Set(i, current);
i++;
} else if (char_length == 1 &&
(ignore_overflow || !ToUpperOverflows(current))) {
// Common case: converting the letter resulted in one character.
DCHECK(static_cast<uc32>(chars[0]) != current);
result->Set(i, chars[0]);
result.Set(i, chars[0]);
has_changed_character = true;
i++;
} else if (result_length == string->length()) {
} else if (result_length == string.length()) {
bool overflows = ToUpperOverflows(current);
// We've assumed that the result would be as long as the
// input but here is a character that converts to several
......@@ -318,7 +318,7 @@ V8_WARN_UNUSED_RESULT static Object ConvertCaseHelper(
: Smi::FromInt(current_length);
} else {
for (int j = 0; j < char_length; j++) {
result->Set(i, chars[j]);
result.Set(i, chars[j]);
i++;
}
has_changed_character = true;
......@@ -376,9 +376,9 @@ V8_WARN_UNUSED_RESULT static Object ConvertCase(
}
Object answer = ConvertCaseHelper(isolate, *s, *result, length, mapping);
if (answer->IsException(isolate) || answer->IsString()) return answer;
if (answer.IsException(isolate) || answer.IsString()) return answer;
DCHECK(answer->IsSmi());
DCHECK(answer.IsSmi());
length = Smi::ToInt(answer);
if (s->IsOneByteRepresentation() && length > 0) {
ASSIGN_RETURN_FAILURE_ON_EXCEPTION(
......
......@@ -124,7 +124,7 @@ class ConcurrentMarkingVisitor final
// Perform a dummy acquire load to tell TSAN that there is no data race
// in mark-bit initialization. See MemoryChunk::Initialize for the
// corresponding release store.
MemoryChunk* chunk = MemoryChunk::FromAddress(heap_object->address());
MemoryChunk* chunk = MemoryChunk::FromAddress(heap_object.address());
CHECK_NOT_NULL(chunk->synchronized_heap());
#endif
if (marking_state_.IsBlackOrGrey(heap_object)) {
......@@ -531,7 +531,7 @@ class ConcurrentMarkingVisitor final
// Perform a dummy acquire load to tell TSAN that there is no data race
// in mark-bit initialization. See MemoryChunk::Initialize for the
// corresponding release store.
MemoryChunk* chunk = MemoryChunk::FromAddress(object->address());
MemoryChunk* chunk = MemoryChunk::FromAddress(object.address());
CHECK_NOT_NULL(chunk->synchronized_heap());
#endif
if (marking_state_.WhiteToGrey(object)) {
......
......@@ -97,7 +97,7 @@ void Scavenger::PageMemoryFence(MaybeObject object) {
// with page initialization.
HeapObject heap_object;
if (object->GetHeapObject(&heap_object)) {
MemoryChunk* chunk = MemoryChunk::FromAddress(heap_object->address());
MemoryChunk* chunk = MemoryChunk::FromAddress(heap_object.address());
CHECK_NOT_NULL(chunk->synchronized_heap());
}
#endif
......
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