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

Side by Side Diff: runtime/vm/object.cc

Issue 968183003: Emit stackmaps even in unoptimized code if slow path pushes untagged values. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 9 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/object.h" 5 #include "vm/object.h"
6 6
7 #include "include/dart_api.h" 7 #include "include/dart_api.h"
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "vm/assembler.h" 9 #include "vm/assembler.h"
10 #include "vm/cpu.h" 10 #include "vm/cpu.h"
(...skipping 12644 matching lines...) Expand 10 before | Expand all | Expand 10 after
12655 // frame slots which are marked as having objects. 12655 // frame slots which are marked as having objects.
12656 *maps = stackmaps(); 12656 *maps = stackmaps();
12657 *map = Stackmap::null(); 12657 *map = Stackmap::null();
12658 for (intptr_t i = 0; i < maps->Length(); i++) { 12658 for (intptr_t i = 0; i < maps->Length(); i++) {
12659 *map ^= maps->At(i); 12659 *map ^= maps->At(i);
12660 ASSERT(!map->IsNull()); 12660 ASSERT(!map->IsNull());
12661 if (map->PcOffset() == pc_offset) { 12661 if (map->PcOffset() == pc_offset) {
12662 return map->raw(); // We found a stack map for this frame. 12662 return map->raw(); // We found a stack map for this frame.
12663 } 12663 }
12664 } 12664 }
12665 // If the code has stackmaps, it must have them for all safepoints. 12665 ASSERT(!is_optimized());
12666 UNREACHABLE();
12667 return Stackmap::null(); 12666 return Stackmap::null();
12668 } 12667 }
12669 12668
12670 12669
12671 intptr_t Code::GetCallerId(intptr_t inlined_id) const { 12670 intptr_t Code::GetCallerId(intptr_t inlined_id) const {
12672 if (inlined_id < 0) return -1; 12671 if (inlined_id < 0) return -1;
12673 const Array& intervals = Array::Handle(inlined_intervals()); 12672 const Array& intervals = Array::Handle(inlined_intervals());
12674 Smi& temp_smi = Smi::Handle(); 12673 Smi& temp_smi = Smi::Handle();
12675 for (intptr_t i = 0; i < intervals.Length() - Code::kInlIntNumEntries; 12674 for (intptr_t i = 0; i < intervals.Length() - Code::kInlIntNumEntries;
12676 i += Code::kInlIntNumEntries) { 12675 i += Code::kInlIntNumEntries) {
(...skipping 8017 matching lines...) Expand 10 before | Expand all | Expand 10 after
20694 return tag_label.ToCString(); 20693 return tag_label.ToCString();
20695 } 20694 }
20696 20695
20697 20696
20698 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const { 20697 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const {
20699 Instance::PrintJSONImpl(stream, ref); 20698 Instance::PrintJSONImpl(stream, ref);
20700 } 20699 }
20701 20700
20702 20701
20703 } // namespace dart 20702 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698