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

Unified Diff: src/compiler/code-generator.h

Issue 1088913002: [turbofan] Load immortal heap objects from the heap roots. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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 | « src/compiler/arm64/code-generator-arm64.cc ('k') | src/compiler/code-generator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/code-generator.h
diff --git a/src/compiler/code-generator.h b/src/compiler/code-generator.h
index 641bbed1a1d6498af477f9eddb5a8c1bd1b25b37..9b3c51f97cb89b4d8ac7d48dfc65f1e9450456b2 100644
--- a/src/compiler/code-generator.h
+++ b/src/compiler/code-generator.h
@@ -58,6 +58,15 @@ class CodeGenerator FINAL : public GapResolver::Assembler {
void RecordSafepoint(ReferenceMap* references, Safepoint::Kind kind,
int arguments, Safepoint::DeoptMode deopt_mode);
+ // Check if a heap object can be materialized by loading from the frame, which
+ // is usually way cheaper than materializing the actual heap object constant.
+ bool IsMaterializableFromFrame(Handle<HeapObject> object, int* offset_return);
+ // Check if a heap object can be materialized by loading from a heap root,
+ // which is cheaper on some platforms than materializing the actual heap
+ // object constant.
+ bool IsMaterializableFromRoot(Handle<HeapObject> object,
+ Heap::RootListIndex* index_return);
+
// Assemble code for the specified instruction.
void AssembleInstruction(Instruction* instr);
void AssembleSourcePosition(Instruction* instr);
« no previous file with comments | « src/compiler/arm64/code-generator-arm64.cc ('k') | src/compiler/code-generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698