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

Unified Diff: src/compiler/typed-optimization.cc

Issue 2390823011: [turbofan] HeapConstant types should compare by handle address (Closed)
Patch Set: HeapConstantType holds a HeapObject. Created 4 years, 2 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/simplified-lowering.cc ('k') | src/compiler/typer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/typed-optimization.cc
diff --git a/src/compiler/typed-optimization.cc b/src/compiler/typed-optimization.cc
index 34661ee9618d99b2888cc495e0975b51e9cab5bc..1f943927b5ec234dd73435c763ef2a7123b355e6 100644
--- a/src/compiler/typed-optimization.cc
+++ b/src/compiler/typed-optimization.cc
@@ -98,11 +98,8 @@ Reduction TypedOptimization::Reduce(Node* node) {
namespace {
MaybeHandle<Map> GetStableMapFromObjectType(Type* object_type) {
- if (object_type->IsHeapConstant() &&
- object_type->AsHeapConstant()->Value()->IsHeapObject()) {
- Handle<Map> object_map(
- Handle<HeapObject>::cast(object_type->AsHeapConstant()->Value())
- ->map());
+ if (object_type->IsHeapConstant()) {
+ Handle<Map> object_map(object_type->AsHeapConstant()->Value()->map());
if (object_map->is_stable()) return object_map;
}
return MaybeHandle<Map>();
« no previous file with comments | « src/compiler/simplified-lowering.cc ('k') | src/compiler/typer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698