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

Unified Diff: src/code-stub-assembler.cc

Issue 1905813003: [turbofan] Introduce dedicated BitcastWordToTagged machine operator. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: REBASE. Small fix. Created 4 years, 8 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 | « no previous file | src/compiler/code-assembler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-stub-assembler.cc
diff --git a/src/code-stub-assembler.cc b/src/code-stub-assembler.cc
index f30edf221deb5057eb75f2cc5de42309cb733e4a..e0f2202e73354dfe491d9e107a241fdf463eaa17 100644
--- a/src/code-stub-assembler.cc
+++ b/src/code-stub-assembler.cc
@@ -343,8 +343,8 @@ Node* CodeStubAssembler::AllocateRawUnaligned(Node* size_in_bytes,
Node* no_runtime_result = top;
StoreNoWriteBarrier(MachineType::PointerRepresentation(), top_address,
IntPtrAdd(top, size_in_bytes));
- no_runtime_result =
- IntPtrAdd(no_runtime_result, IntPtrConstant(kHeapObjectTag));
+ no_runtime_result = BitcastWordToTagged(
+ IntPtrAdd(no_runtime_result, IntPtrConstant(kHeapObjectTag)));
result.Bind(no_runtime_result);
Goto(&merge_runtime);
@@ -392,7 +392,8 @@ Node* CodeStubAssembler::AllocateRawAligned(Node* size_in_bytes,
// it when Simd128 alignment is supported.
StoreNoWriteBarrier(MachineType::PointerRepresentation(), top,
LoadRoot(Heap::kOnePointerFillerMapRootIndex));
- address.Bind(IntPtrAdd(address.value(), IntPtrConstant(kPointerSize)));
+ address.Bind(BitcastWordToTagged(
+ IntPtrAdd(address.value(), IntPtrConstant(kPointerSize))));
Goto(&merge_address);
Bind(&doesnt_need_filler);
@@ -428,7 +429,7 @@ Node* CodeStubAssembler::Allocate(int size_in_bytes, AllocationFlags flags) {
}
Node* CodeStubAssembler::InnerAllocate(Node* previous, int offset) {
- return IntPtrAdd(previous, IntPtrConstant(offset));
+ return BitcastWordToTagged(IntPtrAdd(previous, IntPtrConstant(offset)));
}
Node* CodeStubAssembler::LoadBufferObject(Node* buffer, int offset,
« no previous file with comments | « no previous file | src/compiler/code-assembler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698